Module org.refcodes.component
Package org.refcodes.component
Interface ConnectionOpenable.ConnectionOpenBuilder<CON,B extends ConnectionOpenable.ConnectionOpenBuilder<CON,B>>
- Type Parameters:
CON
- the generic typeB
- The instance to be returned on which to apply succeeding builder operations.
- All Known Subinterfaces:
ConnectionComponent.ConnectionComponentBuilder<CON,
B>
- Enclosing interface:
- ConnectionOpenable<CON>
public static interface ConnectionOpenable.ConnectionOpenBuilder<CON,B extends ConnectionOpenable.ConnectionOpenBuilder<CON,B>>
To enable the
Startable
functionality to be invoked in a builder
chain.-
Method Summary
Modifier and TypeMethodDescriptionBuilder method for theConnectionOpenable.open(Object)
method.default B
withOpenUnchecked
(CON aConnection) Opens the component by callingwithOpen(Object)
without you to require catching anIOException
.
-
Method Details
-
withOpen
Builder method for theConnectionOpenable.open(Object)
method.- Parameters:
aConnection
- The connection used for opening the connection.- Returns:
- The instance to be returned on which to apply succeeding builder operations.
- Throws:
IOException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.
-
withOpenUnchecked
Opens the component by callingwithOpen(Object)
without you to require catching anIOException
.- Parameters:
aConnection
- The connection used for opening the connection.- Returns:
- The instance to be returned on which to apply succeeding builder operations.
- Throws:
org.refcodes.exception.IORuntimeException
- encapsulates the cause and is thrown upon encountering aIOException
exception
-