- All Superinterfaces:
Availability
,org.refcodes.component.Closable
,org.refcodes.component.Closable.CloseAutomaton
,org.refcodes.component.ClosedAccessor
,org.refcodes.component.ConnectableComponent
,org.refcodes.component.ConnectableComponent.ConnectableAutomaton
,org.refcodes.component.ConnectionStatusAccessor
,org.refcodes.component.OpenedAccessor
,Receivable
,ShortDestination
,ShortReceiver
,ShortsDestination
- All Known Subinterfaces:
ConnectionShortsReceiver<CON>
,ConnectionShortsTransceiver<CON>
,ShortsTransceiver
- All Known Implementing Classes:
AbstractShortsReceiver
,LoopbackShortsReceiver
,LoopbackShortsTransceiver
,ShortArrayReceiver
,ShortsReceiverDecorator
The Interface ShortsReceiver.
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.refcodes.component.Closable
org.refcodes.component.Closable.CloseAutomaton, org.refcodes.component.Closable.CloseBuilder<B extends org.refcodes.component.Closable.CloseBuilder<B>>
Nested classes/interfaces inherited from interface org.refcodes.component.ClosedAccessor
org.refcodes.component.ClosedAccessor.ClosedMutator, org.refcodes.component.ClosedAccessor.ClosedProperty
Nested classes/interfaces inherited from interface org.refcodes.component.ConnectableComponent
org.refcodes.component.ConnectableComponent.ConnectableAutomaton
Nested classes/interfaces inherited from interface org.refcodes.component.ConnectionStatusAccessor
org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusMutator, org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusProperty
Nested classes/interfaces inherited from interface org.refcodes.component.OpenedAccessor
org.refcodes.component.OpenedAccessor.OpenedMutator, org.refcodes.component.OpenedAccessor.OpenedProperty
-
Method Summary
Modifier and TypeMethodDescriptiondefault short[]
Reads (receives) the all currently available data.default short[]
receiveShorts
(int aMaxLength) Similar toShortsDestination.receiveAllShorts()
though at maximum the amount of data as provided returned.Methods inherited from interface org.refcodes.io.Availability
available, hasAvailable
Methods inherited from interface org.refcodes.component.Closable
close, closeIn, closeQuietly, closeUnchecked
Methods inherited from interface org.refcodes.component.Closable.CloseAutomaton
isClosable
Methods inherited from interface org.refcodes.component.ClosedAccessor
isClosed
Methods inherited from interface org.refcodes.component.ConnectionStatusAccessor
getConnectionStatus, isOpened
Methods inherited from interface org.refcodes.io.ShortsDestination
receiveShort, receiveShorts
-
Method Details
-
receiveAllShorts
Reads (receives) the all currently available data.- Specified by:
receiveAllShorts
in interfaceShortsDestination
- Returns:
- The next short block sent from the
DatagramsTransmitter
orDatagramReceiver
counterpart. - Throws:
IOException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.EOFException
- Signals that an end of file or end of stream has been reached unexpectedly during input.
-
receiveShorts
Similar toShortsDestination.receiveAllShorts()
though at maximum the amount of data as provided returned.- Specified by:
receiveShorts
in interfaceShortsDestination
- Parameters:
aMaxLength
- The block-size which is not to exceeded by the returned data. A value of -1 specifies to retrieve all available datagrams (same behavior as methodShortsDestination.receiveAllShorts()
.- Returns:
- The next short block sent from the
DatagramsTransmitter
orDatagramReceiver
counterpart. - Throws:
IOException
- Thrown in case opening or accessing an open line (connection, junction, link) caused problems.EOFException
- Signals that an end of file or end of stream has been reached unexpectedly during input.
-