Class FlexBuffers.Blob

  • Enclosing class:
    FlexBuffers

    public static class FlexBuffers.Blob
    extends Object
    Represents a array of bytes element in the buffer

    It can be converted to `com.google.flatbuffers.ReadBuf` using {link data()}, copied into a byte[] using {link getBytes()} or have individual bytes accessed individually using {link get(int)}

    • Method Detail

      • data

        public ByteBuffer data()
        Return FlexBuffers.Blob as `com.google.flatbuffers.ReadBuf`
        Returns:
        blob as `com.google.flatbuffers.ReadBuf`
      • getBytes

        public byte[] getBytes()
        Copy blob into a byte[]
        Returns:
        blob as a byte[]
      • get

        public byte get​(int pos)
        Return individual byte at a given position
        Parameters:
        pos - position of the byte to be read
      • toString

        public String toString()
        Returns a text(JSON) representation of the FlexBuffers.Blob
        Returns:
        a string representation of the object.