Module org.refcodes.serial
Package org.refcodes.serial
Class AbstractStopAndWaitTransmissionDecorator<DECORATEE extends Transmission>
java.lang.Object
org.refcodes.serial.AbstractErrorCorrectionTransmissionDecorator<DECORATEE>
org.refcodes.serial.AbstractStopAndWaitTransmissionDecorator<DECORATEE>
- Type Parameters:
DECORATEE- The decoratee type describing the according subclass to be enriched.
- All Implemented Interfaces:
Serializable,org.refcodes.mixin.DecorateeAccessor<DECORATEE>,org.refcodes.mixin.LengthAccessor,org.refcodes.mixin.Resetable,org.refcodes.numerical.EndianessAccessor,org.refcodes.schema.Schemable,AcknowledgeMagicBytesAccessor,AcknowledgeRetryNumberAccessor,AcknowledgeSegmentPackagerAccessor,AcknowledgeTimeoutMillisAccessor,ErrorCorrectionTransmission,SequenceNumberAccessor,StopAndWaitTransmission,Transmission,Transmission.TransmissionMixin
- Direct Known Subclasses:
StopAndWaitSectionDecorator,StopAndWaitSegmentDecorator
public abstract class AbstractStopAndWaitTransmissionDecorator<DECORATEE extends Transmission>
extends AbstractErrorCorrectionTransmissionDecorator<DECORATEE>
implements StopAndWaitTransmission, org.refcodes.numerical.EndianessAccessor, SequenceNumberAccessor
The
AbstractStopAndWaitTransmissionDecorator class implements a
decorator providing StopAndWaitTransmission functionality for a
Transmission.- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.refcodes.serial.AcknowledgeMagicBytesAccessor
AcknowledgeMagicBytesAccessor.AcknowledgeMagicBytesBuilder<B extends AcknowledgeMagicBytesAccessor.AcknowledgeMagicBytesBuilder<B>>, AcknowledgeMagicBytesAccessor.AcknowledgeMagicBytesMutator, AcknowledgeMagicBytesAccessor.AcknowledgeMagicBytesPropertyNested classes/interfaces inherited from interface org.refcodes.serial.AcknowledgeRetryNumberAccessor
AcknowledgeRetryNumberAccessor.AcknowledgeRetryNumberBuilder<B extends AcknowledgeRetryNumberAccessor.AcknowledgeRetryNumberBuilder<B>>, AcknowledgeRetryNumberAccessor.AcknowledgeRetryNumberMutator, AcknowledgeRetryNumberAccessor.AcknowledgeRetryNumberPropertyNested classes/interfaces inherited from interface org.refcodes.serial.AcknowledgeSegmentPackagerAccessor
AcknowledgeSegmentPackagerAccessor.AcknowledgeSegmentPackagerBuilder<B extends AcknowledgeSegmentPackagerAccessor.AcknowledgeSegmentPackagerBuilder<B>>, AcknowledgeSegmentPackagerAccessor.AcknowledgeSegmentPackagerMutator, AcknowledgeSegmentPackagerAccessor.AcknowledgeSegmentPackagerPropertyNested classes/interfaces inherited from interface org.refcodes.serial.AcknowledgeTimeoutMillisAccessor
AcknowledgeTimeoutMillisAccessor.AcknowledgeTimeoutMillisBuilder<B extends AcknowledgeTimeoutMillisAccessor.AcknowledgeTimeoutMillisBuilder<B>>, AcknowledgeTimeoutMillisAccessor.AcknowledgeTimeoutMillisMutator, AcknowledgeTimeoutMillisAccessor.AcknowledgeTimeoutMillisPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.DecorateeAccessor
org.refcodes.mixin.DecorateeAccessor.DecorateeBuilder<DECORATEE extends Object,B extends org.refcodes.mixin.DecorateeAccessor.DecorateeBuilder<DECORATEE, B>>, org.refcodes.mixin.DecorateeAccessor.DecorateeMutator<DECORATEE extends Object>, org.refcodes.mixin.DecorateeAccessor.DecorateeProperty<DECORATEE extends Object> Nested classes/interfaces inherited from interface org.refcodes.numerical.EndianessAccessor
org.refcodes.numerical.EndianessAccessor.EndianessBuilder<B extends org.refcodes.numerical.EndianessAccessor.EndianessBuilder<B>>, org.refcodes.numerical.EndianessAccessor.EndianessMutator, org.refcodes.numerical.EndianessAccessor.EndianessPropertyNested classes/interfaces inherited from interface org.refcodes.mixin.LengthAccessor
org.refcodes.mixin.LengthAccessor.LengthBuilder<B extends org.refcodes.mixin.LengthAccessor.LengthBuilder<B>>, org.refcodes.mixin.LengthAccessor.LengthMutator, org.refcodes.mixin.LengthAccessor.LengthPropertyNested classes/interfaces inherited from interface org.refcodes.serial.SequenceNumberAccessor
SequenceNumberAccessor.SequenceNumberBuilder<B extends SequenceNumberAccessor.SequenceNumberBuilder<B>>, SequenceNumberAccessor.SequenceNumberMutator, SequenceNumberAccessor.SequenceNumberPropertyNested classes/interfaces inherited from interface org.refcodes.serial.Transmission
Transmission.TransmissionMixin -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected byte[]protected MagicBytesSegmentprotected Segmentprotected SegmentPackagerprotected NumberSegmentprotected org.refcodes.numerical.Endianessprotected intprotected org.refcodes.mixin.ConcatenateModeprotected intprotected intstatic final StringFields inherited from class org.refcodes.serial.AbstractErrorCorrectionTransmissionDecorator
_acknowledgeRetryNumber, _acknowledgeTimeoutInMs, _decoratee, ACK_RETRY_NUMBER, ACK_TIMEOUT_IN_MS -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedInstantiates a new abstract stop and wait transmission decorator.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, SegmentPackager aAckSegmentPackager) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, TransmissionMetrics aTransmissionMetrics) Constructs an according stop-and-wait decorator instance wrapping the given decoratee. -
Method Summary
Modifier and TypeMethodDescriptionbooleanbyte[]Returns the ACK bytes to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.intRetrieves the number of retries from the acknowledge retry number.Retrieves theSegmentPackagerACK property.longThe acknowledge timeout attribute in milliseconds.org.refcodes.numerical.EndianessintDetermines the overall length of thisTransmission.intRetrieves the sequence number from the sequence number property.inthashCode()protected longreadSequenceNumber(InputStream aInputStream) Reads a sequence number from theInputStream.voidreset()Resets any dynamic data (e.g. values such as payloads or checksums) and must not(!)toSchema()Provides theSequencerepresentation of thisTransmission.org.refcodes.struct.SimpleTypeMapReturns theSimpleTypeMaprepresentation of thisTransmission.toString()voidtransmitTo(OutputStream aOutputStream, InputStream aReturnStream) Transmits theSequencerepresenting the implementing type's instance to the givenOutputStream.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.refcodes.serial.Transmission
transmitTo, transmitTo
-
Field Details
-
ACK_MAGIC_BYTES
- See Also:
-
_acknowledgeMagicBytes
protected byte[] _acknowledgeMagicBytes -
_sequenceNumber
protected int _sequenceNumber -
_sequenceNumberWidth
protected int _sequenceNumberWidth -
_sequenceNumberInitValue
protected int _sequenceNumberInitValue -
_sequenceNumberConcatenateMode
protected org.refcodes.mixin.ConcatenateMode _sequenceNumberConcatenateMode -
_endianess
protected org.refcodes.numerical.Endianess _endianess -
_acknowledgeSegmentPackager
-
_acknowledgeSegment
-
_acknowledgeSequenceNumberSegment
-
_acknowledgeMagicBytesSegment
-
-
Constructor Details
-
AbstractStopAndWaitTransmissionDecorator
protected AbstractStopAndWaitTransmissionDecorator()Instantiates a new abstract stop and wait transmission decorator. -
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, TransmissionMetrics aTransmissionMetrics) Constructs an according stop-and-wait decorator instance wrapping the given decoratee. The configuration attributes are taken from theTransmissionMetricsconfiguration object, though only those attributes are supported which are also supported by the other constructors!- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aTransmissionMetrics- TheTransmissionMetricsto be used for configuring this instance.
-
AbstractStopAndWaitTransmissionDecorator
Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, SegmentPackager aAckSegmentPackager) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAckSegmentPackager- The ACKSegmentPackagerfor packaging ACK responses.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aAckSegmentPackager- The ACKSegmentPackagerfor packaging ACK responses.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aAckSegmentPackager- The ACKSegmentPackagerfor packaging ACK responses.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aChecksumValidationMode- The mode of operation when validating provided CRC checksums against calculated ones.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aChecksumValidationMode- The mode of operation when validating provided CRC checksums against calculated ones.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aChecksumValidationMode- The mode of operation when validating provided CRC checksums against calculated ones.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, org.refcodes.numerical.CrcAlgorithm aCrcAlgorithm, org.refcodes.mixin.ConcatenateMode aCrcChecksumConcatenateMode, org.refcodes.numerical.ChecksumValidationMode aChecksumValidationMode, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aCrcAlgorithm- TheCrcAlgorithmto be used for CRC checksum calculation.aCrcChecksumConcatenateMode- The mode of concatenation to use when concatenating the CRC checksum with the transmission'sSequence.aChecksumValidationMode- The mode of operation when validating provided CRC checksums against calculated ones.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
AbstractStopAndWaitTransmissionDecorator
public AbstractStopAndWaitTransmissionDecorator(DECORATEE aDecoratee, int aSequenceNumberInitValue, int aSequenceNumberWidth, org.refcodes.mixin.ConcatenateMode aSequenceNumberConcatenateMode, byte[] aAcknowledgeMagicBytes, int aAckRetryNumber, long aAckTimeoutInMs, SegmentPackager aAckSegmentPackager, org.refcodes.numerical.Endianess aEndianess) Constructs an according stop-and-wait decorator instance wrapping the given decoratee.- Parameters:
aDecoratee- The decoratee to be wrapped by the stop-and-wait decorator.aSequenceNumberInitValue- The initial sequence number from where to start counting the blocks.aSequenceNumberWidth- The width (in bytes) to be used for sequence number values.aSequenceNumberConcatenateMode- The mode of concatenation to use when creating aSequencefrom thisTransmissionand the decoratedTransmission.aAcknowledgeMagicBytes- The ACK character(s) to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.aAckRetryNumber- The number of retries waiting for an ACK from the return channel.aAckTimeoutInMs- The timeout in milliseconds to pend till the next retry.aAckSegmentPackager- The ACKSegmentPackagerfor packaging ACK responses.aEndianess- TheEndianessto use for integer (double) numbers and the like.
-
-
Method Details
-
transmitTo
Transmits theSequencerepresenting the implementing type's instance to the givenOutputStream. Implementations providing error correction methods use the provided feedbackInputStreamto do some sort of "stop-and-wait ARQ" or apply similar methods to ensure correctness of the transmitted data.- Specified by:
transmitToin interfaceTransmission- Specified by:
transmitToin interfaceTransmission.TransmissionMixin- Parameters:
aOutputStream- TheOutputStreamwhere to write this instance'sSequenceto.aReturnStream- AnInputStreambeing the return channel to handle "stop-and-wait ARQ" or the like in case of a bidirectional connection. Can be null in case we have a unidirectional connection.- Throws:
IOException- thrown in case writing data to theOutputStreamcaused problems.
-
reset
public void reset()Resets any dynamic data (e.g. values such as payloads or checksums) and must not(!) reset any configurations or settings required to produce the dynamic data (e.g. theTransmissionMetrics).- Specified by:
resetin interfaceorg.refcodes.mixin.Resetable- Specified by:
resetin interfaceTransmission- Overrides:
resetin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
toSchema
- Specified by:
toSchemain interfaceorg.refcodes.schema.Schemable- Specified by:
toSchemain interfaceTransmission- Overrides:
toSchemain classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
getSequenceNumber
public int getSequenceNumber()Retrieves the sequence number from the sequence number property.- Specified by:
getSequenceNumberin interfaceSequenceNumberAccessor- Returns:
- The sequence number stored by the sequence number property.
-
getAcknowledgeRetryNumber
public int getAcknowledgeRetryNumber()Retrieves the number of retries from the acknowledge retry number. A acknowledge retry number is the overall number of retries to use when counting retries.- Specified by:
getAcknowledgeRetryNumberin interfaceAcknowledgeRetryNumberAccessor- Overrides:
getAcknowledgeRetryNumberin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>- Returns:
- The number of retries stored by the acknowledge retry number.
-
getAcknowledgeTimeoutMillis
public long getAcknowledgeTimeoutMillis()The acknowledge timeout attribute in milliseconds.- Specified by:
getAcknowledgeTimeoutMillisin interfaceAcknowledgeTimeoutMillisAccessor- Overrides:
getAcknowledgeTimeoutMillisin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>- Returns:
- An long integer with the timeout in milliseconds.
-
getAcknowledgeMagicBytes
public byte[] getAcknowledgeMagicBytes()Returns the ACK bytes to be used by the return channel to transmit an ACK (acknowledge) response after successful receiving a transmission.- Specified by:
getAcknowledgeMagicBytesin interfaceAcknowledgeMagicBytesAccessor- Specified by:
getAcknowledgeMagicBytesin interfaceStopAndWaitTransmission- Returns:
- The ACK character.
-
getAcknowledgeSegmentPackager
Retrieves theSegmentPackagerACK property.- Specified by:
getAcknowledgeSegmentPackagerin interfaceAcknowledgeSegmentPackagerAccessor- Returns:
- The
SegmentPackagerstored by the ACKSegmentPackagerproperty.
-
getLength
public int getLength()Determines the overall length of thisTransmission. In case of nestedTransmissioninstances, all length values from all sub-segments are accumulated to the result as well.- Specified by:
getLengthin interfaceorg.refcodes.mixin.LengthAccessor- Specified by:
getLengthin interfaceTransmission- Overrides:
getLengthin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>- Returns:
- The (overall) length of the
Transmission(including any sub-segments).
-
toSequence
Provides theSequencerepresentation of thisTransmission. In case of nestedTransmissioninstances, allSequencerepresentations from all sub-segments are accumulated to the result as well. Caution, the Transmission (or its nestedTransmissioninstances) may be backed by the returnedSequence.- Specified by:
toSequencein interfaceTransmission- Overrides:
toSequencein classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>- Returns:
- The according instance's
Sequence.
-
getDecoratee
- Specified by:
getDecorateein interfaceorg.refcodes.mixin.DecorateeAccessor<DECORATEE extends Transmission>- Overrides:
getDecorateein classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
getEndianess
public org.refcodes.numerical.Endianess getEndianess()- Specified by:
getEndianessin interfaceorg.refcodes.numerical.EndianessAccessor
-
toString
- Overrides:
toStringin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
hashCode
public int hashCode()- Overrides:
hashCodein classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
equals
- Overrides:
equalsin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>
-
toSimpleTypeMap
public org.refcodes.struct.SimpleTypeMap toSimpleTypeMap()Returns theSimpleTypeMaprepresentation of thisTransmission. In case this Transmission hasTransmissionchildren, then the children are queried as well and contained in the resultingSimpleTypeMap. The aliases of the accordingTransmissioninstances represent the resulting path to aTransmission's final simple type.- Specified by:
toSimpleTypeMapin interfaceTransmission- Overrides:
toSimpleTypeMapin classAbstractErrorCorrectionTransmissionDecorator<DECORATEE extends Transmission>- Returns:
- The
SimpleTypeMaprepresenting thisTransmissionand (if any) its children, with the according aliases forming the paths to theTransmission's values.
-
readSequenceNumber
Reads a sequence number from theInputStream.- Parameters:
aInputStream- TheInputStreamfrom which to read the sequence number.- Returns:
- The accordingly read sequence number.
- Throws:
IOException- thrown in case of I/O problems.
-