Class NetStreamDecoder

java.lang.Object
org.graphstream.stream.SourceBase
org.graphstream.stream.netstream.NetStreamDecoder
All Implemented Interfaces:
ByteDecoder, Source

public class NetStreamDecoder
extends SourceBase
implements ByteDecoder
Since:
22/01/16.
  • Constructor Details

  • Method Details

    • validate

      public boolean validate​(ByteBuffer buffer)
      Description copied from interface: ByteDecoder
      Tells if the buffer contains an event that is ready to be dispatched. The bytes considered should be from 0 to the buffer's position. The position of the buffer SHOULD NOT be changed.
      Specified by:
      validate in interface ByteDecoder
      Returns:
      true if the buffer contains an event
    • decode

      public void decode​(ByteBuffer bb)
      Description copied from interface: ByteDecoder
      Decode the buffer, and dispatch the corresponding event.
      Specified by:
      decode in interface ByteDecoder
      Parameters:
      bb - event as a binary buffer