Check if an Error event has been associated to this SelectionKey.
Check if a Hangup event has been associated to this SelectionKey.
Check if an InvalidHandle event has been associated to this SelectionKey.
Check if a Read event has been associated to this SelectionKey.
Check if an UrgentRead event has been associated to this SelectionKey.
Check if a Write event has been associated to this SelectionKey.
The attached Object referred to by the SelectionKey.
The conduit referred to by the SelectionKey.
The registered (or selected) events as a bit mask of different Event values.
The SelectionKey struct holds the information concerning the conduits and their association to a selector. Each key keeps a reference to a registered conduit and the events that are to be tracked for it. The 'events' member of the key can take two meanings, depending on where it's used. If used with the register() method of the selector it represents the events we want to track; if used within a foreach cycle on an ISelectionSet it represents the events that have been detected for a conduit.
The SelectionKey can also hold an optional object via the 'attachment' member. This member is very convenient to keep application-specific data that will be needed when the tracked events are triggered.