Class KQueueIoHandler.DefaultKqueueIoRegistration
java.lang.Object
io.netty.channel.kqueue.KQueueIoHandler.DefaultKqueueIoRegistration
- All Implemented Interfaces:
IoRegistration
- Enclosing class:
KQueueIoHandler
private final class KQueueIoHandler.DefaultKqueueIoRegistration
extends Object
implements IoRegistration
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final AtomicBooleanprivate booleanprivate final KQueueIoEventprivate final ThreadAwareExecutor(package private) final KQueueIoHandle(package private) final long -
Constructor Summary
ConstructorsConstructorDescriptionDefaultKqueueIoRegistration(ThreadAwareExecutor executor, KQueueIoHandle handle) -
Method Summary
Modifier and TypeMethodDescription<T> TImplementation specific attachment, which might benull.booleancancel()Cancel the registration.private voidcancel0()(package private) voidclose()private voidevSet(short filter, short flags, int fflags, long data) (package private) voidhandle(int ident, short filter, short flags, int fflags, long data, long udata) (package private) booleanbooleanisValid()Returnstrueif the registration is still valid.longSubmit theIoOpsto the registration.
-
Field Details
-
cancellationPending
private boolean cancellationPending -
canceled
-
event
-
handle
-
id
final long id -
executor
-
-
Constructor Details
-
DefaultKqueueIoRegistration
DefaultKqueueIoRegistration(ThreadAwareExecutor executor, KQueueIoHandle handle)
-
-
Method Details
-
isHandleForChannel
boolean isHandleForChannel() -
attachment
public <T> T attachment()Description copied from interface:IoRegistrationImplementation specific attachment, which might benull.- Specified by:
attachmentin interfaceIoRegistration- Returns:
- attachment.
-
submit
Description copied from interface:IoRegistrationSubmit theIoOpsto the registration.- Specified by:
submitin interfaceIoRegistration- Parameters:
ops- ops.- Returns:
- an identifier for the operation, which might be unique or not (depending on the implementation).
-
handle
void handle(int ident, short filter, short flags, int fflags, long data, long udata) -
evSet
private void evSet(short filter, short flags, int fflags, long data) -
isValid
public boolean isValid()Description copied from interface:IoRegistrationReturnstrueif the registration is still valid. OnceIoRegistration.cancel()is called this will returnfalse.- Specified by:
isValidin interfaceIoRegistration- Returns:
- valid.
-
cancel
public boolean cancel()Description copied from interface:IoRegistrationCancel the registration.- Specified by:
cancelin interfaceIoRegistration- Returns:
trueif cancellation was successful,falseotherwise.
-
cancel0
private void cancel0() -
close
void close()
-