Package net.dona.doip

Class InDoipMessageFromJson

  • All Implemented Interfaces:
    java.lang.AutoCloseable, java.lang.Iterable<InDoipSegment>, InDoipMessage

    public class InDoipMessageFromJson
    extends java.lang.Object
    implements InDoipMessage
    An implementation of InDoipMessage constructed by supplying a single JsonElement, which will lead to a single JSON segment in the message.
    • Constructor Detail

      • InDoipMessageFromJson

        public InDoipMessageFromJson​(com.google.gson.JsonElement json)
        Constructs an InDoipMessage with a single JSON segment containing the supplied JSON.
        Parameters:
        json - the JSON of the single segment of the message
    • Method Detail

      • iterator

        public java.util.Iterator<InDoipSegment> iterator()
        Specified by:
        iterator in interface java.lang.Iterable<InDoipSegment>
      • spliterator

        public java.util.Spliterator<InDoipSegment> spliterator()
        Specified by:
        spliterator in interface java.lang.Iterable<InDoipSegment>
      • close

        public void close()
        A no-op for this implementation.
        Specified by:
        close in interface java.lang.AutoCloseable
        Specified by:
        close in interface InDoipMessage