Skip navigation links

Oracle® Coherence Java API Reference
Release 12.1.2.0.3

E26043-02


com.tangosol.util
Class ExternalizableHelper.Stats

java.lang.Object
  extended by com.tangosol.util.ExternalizableHelper.Stats

All Implemented Interfaces:
com.tangosol.io.MultiBufferWriteBuffer.WriteBufferPool
Enclosing class:
ExternalizableHelper

protected static class ExternalizableHelper.Stats
extends java.lang.Object
implements com.tangosol.io.MultiBufferWriteBuffer.WriteBufferPool

Serialization statistics for a given user type. Do not document.


Constructor Summary
protected ExternalizableHelper.Stats()
           

 

Method Summary
 com.tangosol.io.WriteBuffer allocate(int cbPreviousTotal)
          Allocate a WriteBuffer for use by the MultiBufferWriteBuffer.
 int getMaximumCapacity()
          Determine the largest amount of aggregate WriteBuffer capacity that this factory can provide.
 void release(com.tangosol.io.WriteBuffer buffer)
          Returns a WriteBuffer to the pool.

 

Constructor Detail

ExternalizableHelper.Stats

protected ExternalizableHelper.Stats()

Method Detail

getMaximumCapacity

public int getMaximumCapacity()
Determine the largest amount of aggregate WriteBuffer capacity that this factory can provide.
Specified by:
getMaximumCapacity in interface com.tangosol.io.MultiBufferWriteBuffer.WriteBufferPool
Returns:
the number of bytes that can be stored in the WriteBuffer objects that may be returned from this factory

allocate

public com.tangosol.io.WriteBuffer allocate(int cbPreviousTotal)
Allocate a WriteBuffer for use by the MultiBufferWriteBuffer. The MultiBufferWriteBuffer calls this factory method when it exhausts the storage capacity of previously allocated WriteBuffer objects.

Note that the returned WriteBuffer is expected to be empty, and its capacity is expected to be identical to its maximum capacity, i.e. it is not expected to resize itself, since the purpose of the MultiBufferWriteBuffer is to act as a dynamically-sized WriteBuffer.

Specified by:
allocate in interface com.tangosol.io.MultiBufferWriteBuffer.WriteBufferPool
Parameters:
cbPreviousTotal - the total number of bytes of capacity of the WriteBuffer objects that the MultiBufferWriteBuffer has thus far consumed
Returns:
an empty WriteBuffer suitable for writing to

release

public void release(com.tangosol.io.WriteBuffer buffer)
Returns a WriteBuffer to the pool.
Specified by:
release in interface com.tangosol.io.MultiBufferWriteBuffer.WriteBufferPool
Parameters:
buffer - the WriteBuffer that is no longer being used

Skip navigation links

Oracle® Coherence Java API Reference
Release 12.1.2.0.3

E26043-02


Copyright © 2000, 2014, Oracle and/or its affiliates. All rights reserved.