Class Data

    • Constructor Summary

      Constructors 
      Constructor Description
      Data()  
    • Method Summary

      All Methods Instance Methods Abstract Methods Concrete Methods 
      Modifier and Type Method Description
      boolean equals​(java.lang.Object other)  
      abstract Record.TYPE getType()
      The payload type.
      int hashCode()  
      int length()  
      protected abstract void serialize​(java.io.DataOutputStream dos)
      The internal method used to serialize Data subclasses.
      byte[] toByteArray()  
      void toOutputStream​(java.io.DataOutputStream dos)
      Write the binary representation of this payload to the given DataOutputStream.
      void toOutputStream​(java.io.OutputStream outputStream)  
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • Data

        public Data()
    • Method Detail

      • getType

        public abstract Record.TYPE getType()
        The payload type.
        Returns:
        The payload type.
      • serialize

        protected abstract void serialize​(java.io.DataOutputStream dos)
                                   throws java.io.IOException
        The internal method used to serialize Data subclasses.
        Parameters:
        dos - the output stream to serialize to.
        Throws:
        java.io.IOException - if an I/O error occurs.
      • length

        public final int length()
      • toOutputStream

        public final void toOutputStream​(java.io.OutputStream outputStream)
                                  throws java.io.IOException
        Throws:
        java.io.IOException
      • toOutputStream

        public final void toOutputStream​(java.io.DataOutputStream dos)
                                  throws java.io.IOException
        Write the binary representation of this payload to the given DataOutputStream.
        Parameters:
        dos - the DataOutputStream to write to.
        Throws:
        java.io.IOException - if an I/O error occurs.
      • hashCode

        public final int hashCode()
        Overrides:
        hashCode in class java.lang.Object
      • equals

        public final boolean equals​(java.lang.Object other)
        Overrides:
        equals in class java.lang.Object