Class PowerOfTwoBufferPool

  • All Implemented Interfaces:
    BufferProvider

    @Deprecated(since="2021-05-27")
    public class PowerOfTwoBufferPool
    extends java.lang.Object
    implements BufferProvider
    Deprecated.
    Usage of this API is not supported in AEM as a Cloud Service.
    Power-of-two buffer pool implementation.

    This class should not be considered a part of the public API.

    • Constructor Summary

      Constructors 
      Constructor Description
      PowerOfTwoBufferPool()
      Deprecated.
      Construct an instance with a highest power of two of 24.
      PowerOfTwoBufferPool​(int highestPowerOfTwo)
      Deprecated.
      Construct an instance.
    • Constructor Detail

      • PowerOfTwoBufferPool

        public PowerOfTwoBufferPool()
        Deprecated.
        Construct an instance with a highest power of two of 24.
      • PowerOfTwoBufferPool

        public PowerOfTwoBufferPool​(int highestPowerOfTwo)
        Deprecated.
        Construct an instance.
        Parameters:
        highestPowerOfTwo - the highest power of two buffer size that will be pooled
    • Method Detail

      • getBuffer

        public ByteBuf getBuffer​(int size)
        Deprecated.
        Description copied from interface: BufferProvider
        Gets a buffer with the givens capacity.
        Specified by:
        getBuffer in interface BufferProvider
        Parameters:
        size - the size required for the buffer
        Returns:
        a ByteBuf with the given size, which is now owned by the caller and must be released.