MCPcopy Create free account
hub / github.com/cloud-hypervisor/cloud-hypervisor / as_raw_fd

Method as_raw_fd

rate_limiter/src/lib.rs:509–512  ·  view source on GitHub ↗

Provides a FD which needs to be monitored for POLLIN events. This object's `event_handler()` method must be called on such events. Will return a negative value if rate limiting is disabled on both token types.

(&self)

Source from the content-addressed store, hash-verified

507 /// Will return a negative value if rate limiting is disabled on both
508 /// token types.
509 fn as_raw_fd(&self) -> RawFd {
510 let guard = self.inner.lock().unwrap();
511 guard.timer_fd.as_raw_fd()
512 }
513}
514
515impl Default for RateLimiter {

Callers 1

newMethod · 0.45

Calls

no outgoing calls

Tested by

no test coverage detected