Interface ILcdBuffer

All Known Implementing Classes:
TLcdBuffer, TLcdConcurrentBuffer

public interface ILcdBuffer
An ILcdBuffer defines methods to manage a buffer of bytes. Buffer segments can be allocated and information can be retrieved. If a buffer segment is allocated and the buffer doesn't have enough consecutive bytes available, older segments are discarded to free up space.
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Allocates a given number of bytes in this ILcdBuffer.
    byte[]
    Returns the bytes in this ILcdBuffer.
    int
    Returns the number of bytes in the buffer.
  • Method Details

    • getByte

      byte[] getByte()
      Returns the bytes in this ILcdBuffer.
      Returns:
      the bytes in this ILcdBuffer.
    • getSize

      int getSize()
      Returns the number of bytes in the buffer.
      Returns:
      the number of bytes in the buffer.
    • allocateBufferSegment

      ILcdBufferSegment allocateBufferSegment(int aCount) throws IllegalArgumentException
      Allocates a given number of bytes in this ILcdBuffer. Other buffer segments may be de-allocated as required to make space.
      Parameters:
      aCount - the number of bytes to be allocated. It must not be larger than the total buffer size.
      Returns:
      an ILcdBufferSegment that specifies the allocated space in this ILcdBuffer.
      Throws:
      IllegalArgumentException - when the requested number of bytes is larger than the full buffer size.