Os.Poll(StructPollfd[], Int32) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
See poll(2).
[Android.Runtime.Register("poll", "([Landroid/system/StructPollfd;I)I", "")]
public static int Poll(Android.Systems.StructPollfd[]? fds, int timeoutMs);
[<Android.Runtime.Register("poll", "([Landroid/system/StructPollfd;I)I", "")>]
static member Poll : Android.Systems.StructPollfd[] * int -> int
Parameters
- fds
- StructPollfd[]
The descriptors and requested event masks. Their returned event masks are populated by the operation.
- timeoutMs
- Int32
The timeout in milliseconds: 0 checks immediately, and a negative value waits without a timeout.
Returns
The number of descriptors with reported events, or 0 if the timeout expires.
- Attributes
Exceptions
Remarks
See poll(2).
Note that in Lollipop this could throw an ErrnoException with EINTR. In later releases, the implementation will automatically just restart the system call with an appropriately reduced timeout.
Java documentation for android.system.Os.poll(android.system.StructPollfd[], int).
Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.