- All Superinterfaces:
org.refcodes.mixin.LengthAccessor,org.refcodes.mixin.Resetable,org.refcodes.schema.Schemable,Serializable,Transmission
- All Known Subinterfaces:
ArraySection<ARRAY>,ArraySegment<SEGMENT>,Section.SectionMixin,Segment.SegmentMixin
- All Known Implementing Classes:
AbstractCipherTransmissionDecorator,AbstractCrcTransmissionDecorator,AbstractErrorCorrectionTransmissionDecorator,AbstractInvertibleTransmissionDecorator,AbstractLengthDecoratorSegment,AbstractMagicBytesTransmission,AbstractMagicBytesTransmissionDecorator,AbstractPayloadSection,AbstractPayloadSegment,AbstractReadyToReceiveTransmissionDecorator,AbstractReadyToSendTransmissionDecorator,AbstractReferenceeLengthSegment,AbstractSectionDecorator,AbstractSegmentDecorator,AbstractStopAndWaitPacketStreamTransmissionDecorator,AbstractStopAndWaitTransmissionDecorator,AbstractTransmissionDecorator,AllocSectionDecoratorSegment,AllocSegmentBody,AllocSegmentHead,AsciizArraySegment,AsciizSegment,AssertMagicBytesSectionDecorator,AssertMagicBytesSegment,AssertMagicBytesSegmentDecorator,BooleanArraySection,BooleanSegment,BreakerSectionDecorator,BreakerSegmentDecorator,ByteArraySection,ByteSegment,CharArraySection,CharSection,CipherSectionDecorator,CipherSegmentDecorator,ComplexTypeSegment,CrcSectionDecorator,CrcSegmentDecorator,DoubleArraySection,DoubleSegment,DynamicTypeSection,EnumSegment,FileSection,FixedLengthSequenceSegment,FixedSegmentArraySection,FloatArraySection,FloatSegment,IntArraySection,IntSegment,InvertibleSectionDecorator,InvertibleSegmentDecorator,LengthSegment,LengthSegmentDecoratorSegment,LongArraySection,LongSegment,MagicBytesSectionDecorator,MagicBytesSegment,MagicBytesSegmentDecorator,NumberSegment,PropertiesSection,ReadyToReceiveSectionDecorator,ReadyToReceiveSegmentDecorator,ReadyToSendSectionDecorator,ReadyToSendSegmentDecorator,SectionComposite,SegmentArraySection,SegmentComposite,SequenceNumberSegment,SequenceSection,ShortArraySection,ShortSegment,StopAndWaitPacketStreamSectionDecorator,StopAndWaitPacketStreamSegmentDecorator,StopAndWaitSectionDecorator,StopAndWaitSegmentDecorator,StringArraySection,StringSection
- Enclosing interface:
- Transmission
Default implementation of the
Transmission interface providing an
implementation of the transmitTo(OutputStream, InputStream)
method using the Transmission.toSequence() method.-
Nested Class Summary
Nested 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.Transmission
Transmission.TransmissionMixin -
Method Summary
Modifier and TypeMethodDescriptiondefault voidtransmitTo(OutputStream aOutputStream, InputStream aReturnStream) Default implementation harnessing theTransmission.toSequence()method.Methods inherited from interface org.refcodes.serial.Transmission
getLength, reset, toSchema, toSequence, toSimpleTypeMap, transmitTo, transmitTo
-
Method Details
-
transmitTo
Default implementation harnessing theTransmission.toSequence()method. 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- 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.
-