- Type Parameters:
H- The type of the handle.
- All Known Subinterfaces:
ComponentHandleComposite<H,REF>
public interface FlushHandle<H>
The
FlushHandle interface defines those methods related to the handle
based flush operation.
The handle reference requires the Flushable interface to be
implemented.
-
Method Summary
Modifier and TypeMethodDescriptionvoidFlushes the component identified by the given handle.default voidflushUnchecked(H aHandle) Flushes the component by callingflush(Object)without you to require catching aIOException.booleanDetermines whether the handle reference provides flushting by implementing theFlushableinterface.
-
Method Details
-
hasFlush
Determines whether the handle reference provides flushting by implementing theFlushableinterface.- Parameters:
aHandle- The handle to test whether the reference provides the according functionality.- Returns:
- True in case the reference provides the according functionality.
- Throws:
UnknownHandleRuntimeException- Thrown in case the handle is unknown (there is none reference for this handle).
-
flush
Flushes the component identified by the given handle.- Parameters:
aHandle- The handle identifying the component.- Throws:
IOException- in case flushing fails.UnknownHandleRuntimeException- Thrown in case the handle is unknown (there is none reference for this handle).UnsupportedHandleOperationRuntimeException- in case the reference of the handle does not support the requested operation.IllegalHandleStateChangeRuntimeException- Thrown in case a state change is not possible due to the current state the referenced component is in.
-
flushUnchecked
Flushes the component by callingflush(Object)without you to require catching aIOException.- Parameters:
aHandle- The handle identifying the component.- Throws:
org.refcodes.exception.RuntimeIOException- encapsulates the aCause and is thrown upon encountering aIOExceptionexception
-