Class MBOut

java.lang.Object
org.nustaq.serialization.minbin.MBOut

public class MBOut
extends java.lang.Object
Date: 12.04.2014 Time: 22:11 To change this template use File | Settings | File Templates.
  • Constructor Summary

    Constructors 
    Constructor Description
    MBOut()  
    MBOut​(MinBin mb)  
  • Method Summary

    Modifier and Type Method Description
    byte[] getBytez()  
    int getWritten()  
    void reset()
    completely reset state
    void reset​(byte[] bytez)
    completely reset and use given bytearray as buffer
    void resetPosition()
    only reset position
    void writeArray​(java.lang.Object primitiveArray, int start, int len)
    write primitive array + header. no floating point or object array allowed.
    void writeInt​(byte type, long data)
    write an int type with header
    void writeIntPacked​(long data)
    encode int using only as much bytes as needed to represent it
    void writeObject​(java.lang.Object o)  
    void writeRaw​(byte[] bufferedName, int i, int length)
    allow write through to underlying byte for performance reasons
    protected void writeRawInt​(byte type, long data)
    encode int without header tag
    void writeTag​(java.lang.Object obj)  
    void writeTagHeader​(byte tagId)  

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Constructor Details

  • Method Details

    • writeInt

      public void writeInt​(byte type, long data)
      write an int type with header
      Parameters:
      type -
      data -
    • writeRawInt

      protected void writeRawInt​(byte type, long data)
      encode int without header tag
      Parameters:
      data -
    • writeIntPacked

      public void writeIntPacked​(long data)
      encode int using only as much bytes as needed to represent it
      Parameters:
      data -
    • writeArray

      public void writeArray​(java.lang.Object primitiveArray, int start, int len)
      write primitive array + header. no floating point or object array allowed. Just int based types
      Parameters:
      primitiveArray -
      start -
      len -
    • writeTagHeader

      public void writeTagHeader​(byte tagId)
    • writeTag

      public void writeTag​(java.lang.Object obj)
    • getWritten

      public int getWritten()
    • getBytez

      public byte[] getBytez()
    • reset

      public void reset()
      completely reset state
    • reset

      public void reset​(byte[] bytez)
      completely reset and use given bytearray as buffer
      Parameters:
      bytez -
    • resetPosition

      public void resetPosition()
      only reset position
    • writeObject

      public void writeObject​(java.lang.Object o)
    • writeRaw

      public void writeRaw​(byte[] bufferedName, int i, int length)
      allow write through to underlying byte for performance reasons
      Parameters:
      bufferedName -
      i -
      length -