java.lang.Object
org.refcodes.io.AbstractBytesDestination
org.refcodes.io.AbstractBytesReceiver
org.refcodes.codec.ModemDecoderImpl
- All Implemented Interfaces:
Decoder,DemodulatorStatusAccessor,ModemDecoder,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,org.refcodes.io.Availability,org.refcodes.io.ByteDestination,org.refcodes.io.ByteReceiver,org.refcodes.io.BytesDestination,org.refcodes.io.BytesReceiver,org.refcodes.io.Receivable,org.refcodes.io.Skippable,org.refcodes.io.TimeoutInputStreamAccessor,org.refcodes.mixin.InputStreamAccessor,org.refcodes.mixin.Loggable
- Direct Known Subclasses:
ModemDecoderImpl.ModemByteDecoderProviderImpl,ModemDecoderImpl.ModemShortDecoderProviderImpl
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classVanilla plain implementation of theModemDecoder.ModemByteDecoderProviderinterface to be used withBytesDestination(BytesReceiver) instances.static classVanilla plain implementation of theModemDecoder.ModemByteDecoderProviderinterface to be used withBytesDestination(BytesReceiver) instances.Nested classes/interfaces inherited from class org.refcodes.io.AbstractBytesReceiver
org.refcodes.io.AbstractBytesReceiver.ConnectableAutomatonNested classes/interfaces inherited from interface org.refcodes.io.BytesReceiver
org.refcodes.io.BytesReceiver.ReceiverInputStreamNested 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.ClosedPropertyNested classes/interfaces inherited from interface org.refcodes.component.ConnectableComponent
org.refcodes.component.ConnectableComponent.ConnectableAutomatonNested classes/interfaces inherited from interface org.refcodes.component.ConnectionStatusAccessor
org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusMutator, org.refcodes.component.ConnectionStatusAccessor.ConnectionStatusPropertyNested classes/interfaces inherited from interface org.refcodes.codec.DemodulatorStatusAccessor
DemodulatorStatusAccessor.DemodulatorStatusBuilder<B extends DemodulatorStatusAccessor.DemodulatorStatusBuilder<B>>, DemodulatorStatusAccessor.DemodulatorStatusMutator, DemodulatorStatusAccessor.DemodulatorStatusPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.InputStreamAccessor
org.refcodes.mixin.InputStreamAccessor.InputStreamBuilder<B extends org.refcodes.mixin.InputStreamAccessor.InputStreamBuilder<?>>, org.refcodes.mixin.InputStreamAccessor.InputStreamMutator, org.refcodes.mixin.InputStreamAccessor.InputStreamPropertyNested classes/interfaces inherited from interface org.refcodes.codec.ModemDecoder
ModemDecoder.ModemByteDecoderProvider, ModemDecoder.ModemShortDecoderProviderNested classes/interfaces inherited from interface org.refcodes.component.OpenedAccessor
org.refcodes.component.OpenedAccessor.OpenedMutator, org.refcodes.component.OpenedAccessor.OpenedPropertyNested classes/interfaces inherited from interface org.refcodes.io.TimeoutInputStreamAccessor
org.refcodes.io.TimeoutInputStreamAccessor.TimeoutInputStreamBuilder<B extends org.refcodes.io.TimeoutInputStreamAccessor.TimeoutInputStreamBuilder<?>>, org.refcodes.io.TimeoutInputStreamAccessor.TimeoutInputStreamMutator, org.refcodes.io.TimeoutInputStreamAccessor.TimeoutInputStreamProperty -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected org.refcodes.io.BytesReceiverprotected LinkedBlockingQueue<Byte>protected ModemMetricsprotected org.refcodes.io.ShortsReceiverFields inherited from class org.refcodes.io.AbstractBytesReceiver
_automatonFields inherited from class org.refcodes.io.AbstractBytesDestination
DATAGRAM_QUEUE_SIZEFields inherited from interface org.refcodes.mixin.Loggable
RUNTIME_LOGGER_CLASS, RUNTIME_LOGGER_FACTORY_CLASS, RUNTIME_LOGGER_FACTORY_METHOD -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedModemDecoderImpl(ModemMetrics aModemMetrics) ModemDecoderImpl(ModemMetrics aModemMetrics, org.refcodes.io.BytesDestination aByteProvider) Instantiates a new modem decoder impl.ModemDecoderImpl(ModemMetrics aModemMetrics, org.refcodes.io.BytesReceiver aByteReceiver) Instantiates a new modem decoder impl.ModemDecoderImpl(ModemMetrics aModemMetrics, org.refcodes.io.ShortsDestination aShortProvider) Instantiates a new modem decoder impl.ModemDecoderImpl(ModemMetrics aModemMetrics, org.refcodes.io.ShortsReceiver aShortReceiver) Instantiates a new modem decoder impl. -
Method Summary
Modifier and TypeMethodDescriptionintRetrieves the Demodulator-Status from the Demodulator-Status property.byte[]bytebyte[]receiveBytes(int aMaxLength) Methods inherited from class org.refcodes.io.AbstractBytesReceiver
close, getConnectionStatus, isClosable, isClosed, isOpenable, isOpened, open, setConnectionStatusMethods inherited from class org.refcodes.io.AbstractBytesDestination
pushDatagram, pushDatagrams, pushDatagramsMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.refcodes.io.Availability
hasAvailableMethods inherited from interface org.refcodes.io.BytesDestination
receiveBytesMethods inherited from interface org.refcodes.io.BytesReceiver
getInputStream, getInputStream, receiveBytesWithin, receiveBytesWithin, receiveByteWithin, skipMethods inherited from interface org.refcodes.component.Closable
close, closeIn, closeQuietly, closeUncheckedMethods inherited from interface org.refcodes.component.Closable.CloseAutomaton
isClosableMethods inherited from interface org.refcodes.component.ClosedAccessor
isClosedMethods inherited from interface org.refcodes.component.ConnectionStatusAccessor
getConnectionStatus, isOpenedMethods inherited from interface org.refcodes.mixin.Loggable
alert, alert, critical, critical, debug, error, info, notice, panic, trace, warn, warnMethods inherited from interface org.refcodes.io.Skippable
skipAvailable, skipAvailableExcept, skipAvailableTill, skipAvailableTillSilenceFor, skipAvailableTillSilenceFor, skipAvailableWithin, skipAvailableWithin, skipAvailableWithin
-
Field Details
-
_modemMetrics
-
_datagramQueue
-
_byteReceiver
protected org.refcodes.io.BytesReceiver _byteReceiver -
_shortReceiver
protected org.refcodes.io.ShortsReceiver _shortReceiver
-
-
Constructor Details
-
ModemDecoderImpl
Instantiates a new modem decoder impl.- Parameters:
aModemMetrics- the modem metricsaByteProvider- the byte provider
-
ModemDecoderImpl
public ModemDecoderImpl(ModemMetrics aModemMetrics, org.refcodes.io.ShortsDestination aShortProvider) Instantiates a new modem decoder impl.- Parameters:
aModemMetrics- the modem metricsaShortProvider- the short provider
-
ModemDecoderImpl
Instantiates a new modem decoder impl.- Parameters:
aModemMetrics- the modem metricsaShortReceiver- the short receiver
-
ModemDecoderImpl
Instantiates a new modem decoder impl.- Parameters:
aModemMetrics- the modem metricsaByteReceiver- the byte receiver
-
ModemDecoderImpl
-
-
Method Details
-
receiveAllBytes
public byte[] receiveAllBytes()- Specified by:
receiveAllBytesin interfaceorg.refcodes.io.BytesDestination- Specified by:
receiveAllBytesin interfaceorg.refcodes.io.BytesReceiver- Overrides:
receiveAllBytesin classorg.refcodes.io.AbstractBytesReceiver
-
available
public int available()- Specified by:
availablein interfaceorg.refcodes.io.Availability- Specified by:
availablein interfaceorg.refcodes.io.Skippable- Overrides:
availablein classorg.refcodes.io.AbstractBytesReceiver
-
receiveBytes
public byte[] receiveBytes(int aMaxLength) - Specified by:
receiveBytesin interfaceorg.refcodes.io.BytesDestination- Specified by:
receiveBytesin interfaceorg.refcodes.io.BytesReceiver- Overrides:
receiveBytesin classorg.refcodes.io.AbstractBytesReceiver
-
receiveByte
- Specified by:
receiveBytein interfaceorg.refcodes.io.ByteDestination- Specified by:
receiveBytein interfaceorg.refcodes.io.BytesDestination- Overrides:
receiveBytein classorg.refcodes.io.AbstractBytesReceiver- Throws:
IOException
-
getDemodulatorStatus
Retrieves the Demodulator-Status from the Demodulator-Status property.- Specified by:
getDemodulatorStatusin interfaceDemodulatorStatusAccessor- Returns:
- The Demodulator-Status stored by the Demodulator-Status property.
-