Top Description Fields Constructors Methods
org.apache.derby.impl.store.access.btree.index

public Class B2I

extends BTree
Class Inheritance
Known Direct Subclasses
org.apache.derby.impl.store.access.btree.index.B2I_10_3, org.apache.derby.impl.store.access.btree.index.B2I_v10_2
Imports
java.io.ObjectOutput, .ObjectInput, .IOException, java.util.Properties, org.apache.derby.shared.common.reference.SQLState, org.apache.derby.shared.common.sanity.SanityManager, org.apache.derby.shared.common.error.StandardException, org.apache.derby.impl.store.access.conglomerate.ConglomerateUtil, org.apache.derby.iapi.store.access.conglomerate.LogicalUndo, .ScanManager, .TransactionManager, .Conglomerate, org.apache.derby.iapi.store.access.ColumnOrdering, .ConglomerateController, .DynamicCompiledOpenConglomInfo, .Qualifier, .RowLocationRetRowSource, .StaticCompiledOpenConglomInfo, .StoreCostController, .TransactionController, org.apache.derby.iapi.store.raw.ContainerHandle, .LockingPolicy, .Transaction, org.apache.derby.iapi.types.DataValueDescriptor, .RowLocation, .StringDataValue, org.apache.derby.impl.store.access.btree.BTree, .BTreeLockingPolicy, .LeafControlRow, .OpenBTree, org.apache.derby.iapi.services.cache.ClassSize, org.apache.derby.iapi.services.io.FormatableBitSet, .StoredFormatIds

Implements an instance of a B-Tree secondary index conglomerate. A B2I object has two roles.
  1. The B2I object is stored on disk, and holds the store specific information needed to access/describe the conglomerate. This includes information such as the format ids of the columns, the conglomerate id of the base table, the location of row location column.
  2. Access to all the interfaces start by making a call off the Conglomerate interface. So for instance to get a scan on the conglomerate method openScan should be called.

Field Summary

Modifier and TypeField and Description
private static final int
pack-priv long
baseConglomerateId

The id of the conglomerate which contains the base table.

pack-priv static final int
private static final String
private static final String
pack-priv int
rowLocationColumn

The column id (zero-based integer index) of the column which holds the row location to the base conglomerate.

Inherited from org.apache.derby.impl.store.access.btree.BTree:
ascDescInfocollation_idsconglom_format_idformat_idshasCollatedTypesidnKeyFieldsPROPERTY_ALLOWDUPLICATESPROPERTY_MAX_ROWS_PER_PAGE_PARAMETERPROPERTY_NKEYFIELDSPROPERTY_NUNIQUECOLUMNSPROPERTY_PARENTLINKSPROPERTY_UNIQUE_WITH_DUPLICATE_NULLSROOTPAGEID

Constructor Summary

AccessConstructor and Description
public
B2I()

Method Summary

Modifier and TypeMethod and Description
public void
public void
create(TransactionManager xact_manager, int segmentId, long input_conglomid, DataValueDescriptor[] template, ColumnOrdering[] columnOrder, int[] collationIds, Properties properties, int temporaryFlag)

Create an empty secondary index b-tree, using the generic b-tree to do the generic part of the creation process.

public ScanManager
defragmentConglomerate(TransactionManager xact_manager, Transaction rawtran, boolean
see openScan()
hold
,
int
see openScan()
open_mode
,
int
see openScan()
lock_level
,
LockingPolicy locking_policy, int
see openScan()
isolation_level
)

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

Open a b-tree compress scan.

public void
public int
estimateMemoryUsage()

Implements org.apache.derby.iapi.types.DataValueDescriptor.estimateMemoryUsage.

Estimate the memory usage in bytes of the data value and the overhead of the class.

public boolean

Returns:

boolean indicating if a row was found and retrieved or not.
fetchMaxOnBTree
(TransactionManager
The TransactionController under which this operation takes place.
xact_manager
,
Transaction
The raw store xact to associate all ops with.
rawtran
,
long
The identifier of the conglomerate to open the scan for.
conglomId
,
int
Specifiy flags to control opening of table. OPENMODE_FORUPDATE - if set open the table for update otherwise open table shared.
open_mode
,
int
One of (MODE_TABLE, MODE_RECORD, or MODE_NONE).
lock_level
,
LockingPolicy
The LockingPolicy to use to open the conglomerate.
locking_policy
,
int
The isolation level to lock the conglomerate at. One of (ISOLATION_READ_COMMITTED or ISOLATION_SERIALIZABLE).
isolation_level
,
FormatableBitSet
A description of which columns to return from every fetch in the scan. template, and scanColumnList work together to describe the row to be returned by the scan - see RowUtil for description of how these three parameters work together to describe a "row".
scanColumnList
,
DataValueDescriptor[]
The row to retrieve the maximum value into.
fetchRow
)

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.fetchMaxOnBTree.

Retrieve the maximum value row in an ordered conglomerate.

protected BTreeLockingPolicy
getBtreeLockingPolicy(Transaction rawtran, int lock_level, int mode, int isolation_level, ConglomerateController base_cc, OpenBTree open_btree)

Implements abstract org.apache.derby.impl.store.access.btree.BTree.getBtreeLockingPolicy.

Create a new btree locking policy from scratch.

public StaticCompiledOpenConglomInfo

Returns:

The static compiled information.
getStaticCompiledConglomInfo
(TransactionController
The TransactionController under which this operation takes place.
xact_manager
,
long
The identifier of the conglomerate to open.
conglomId
)

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.getStaticCompiledConglomInfo.

Return static information about the conglomerate to be included in a a compiled plan.

public int
public long
load(TransactionManager
The TransactionController under which this operation takes place.
xact_manager
,
boolean
If true, the conglomerate is being created in the same operation as the openAndLoadConglomerate. The enables further optimization as recovery does not require page allocation to be logged.
createConglom
,
RowLocationRetRowSource
Where the rows come from.
rowSource
)

Implements abstract org.apache.derby.impl.store.access.btree.BTree.load.

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

Bulk Load a B-tree secondary index.

public final ConglomerateController
lockTable(TransactionManager
Transaction to associate the lock with.
xact_manager
,
int open_mode, int lock_level, int isolation_level)

Implements abstract org.apache.derby.impl.store.access.btree.BTree.lockTable.

Lock the base table.

public ConglomerateController
open(TransactionManager
The access xact to associate all ops on cc with.
xact_manager
,
Transaction
The raw store xact to associate all ops on cc with.
rawtran
,
boolean hold, int
A bit mask of TransactionController.MODE_* bits, indicating info about the open.
open_mode
,
int
Either TransactionController.MODE_TABLE or TransactionController.MODE_RECORD, as passed into the openConglomerate() call.
lock_level
,
LockingPolicy
The LockingPolicy to use to open the conglomerate.
locking_policy
,
StaticCompiledOpenConglomInfo static_info, DynamicCompiledOpenConglomInfo dynamic_info)

Implements abstract org.apache.derby.impl.store.access.btree.BTree.open.

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

Open a b-tree controller.

public ScanManager
openScan(TransactionManager xact_manager, Transaction rawtran, boolean hold, int open_mode, int lock_level, LockingPolicy locking_policy, int isolation_level, FormatableBitSet scanColumnList, DataValueDescriptor[] startKeyValue, int startSearchOperator, Qualifier[][] qualifier, DataValueDescriptor[] stopKeyValue, int stopSearchOperator, StaticCompiledOpenConglomInfo static_info, DynamicCompiledOpenConglomInfo dynamic_info)

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.openScan.

Open a b-tree secondary index scan controller.

public StoreCostController

Returns:

The open StoreCostController.
openStoreCost
(TransactionManager
The TransactionController under which this operation takes place.
xact_manager
,
Transaction
raw transaction context in which scan is managed.
rawtran
)

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.openStoreCost.

Return an open StoreCostController for the conglomerate.

public void
public void
readExternal(ObjectInput
the stream to read data from in order to restore the object
in
)

Overrides org.apache.derby.impl.store.access.btree.BTree.readExternal.

Implements java.io.Externalizable.readExternal.

Restore the in-memory representation from the stream.

private void
traverseRight()

Private methods of B2I, arranged alphabetically.

public void
writeExternal(ObjectOutput
the stream to write the object to
out
)

Overrides org.apache.derby.impl.store.access.btree.BTree.writeExternal.

Implements java.io.Externalizable.writeExternal.

Store the stored representation of the column value in the stream.

public void
writeExternal_v10_2(ObjectOutput out)

Store the stored representation of the column value in the stream.

public void
writeExternal_v10_3(ObjectOutput out)

Store the stored representation of the column value in the stream.

Inherited from org.apache.derby.impl.store.access.btree.BTree:
addColumncreatecreateTemplategetContaineridgetDynamicCompiledConglomInfogetIdisNullisTemporaryisUniqueisUniqueWithDuplicateNullsrestoreToNullsetUniqueWithDuplicateNullstoString

Field Detail

BASE_MEMORY_USAGEback to summary
private static final int BASE_MEMORY_USAGE
baseConglomerateIdback to summary
pack-priv long baseConglomerateId

The id of the conglomerate which contains the base table. Row locations inserted into this secondary index are assumed to refer to that conglomerate. Used to obtain table/row locks on the base table rows which the index rows point at.

FORMAT_NUMBERback to summary
pack-priv static final int FORMAT_NUMBER
PROPERTY_BASECONGLOMIDback to summary
private static final String PROPERTY_BASECONGLOMID
PROPERTY_ROWLOCCOLUMNback to summary
private static final String PROPERTY_ROWLOCCOLUMN
rowLocationColumnback to summary
pack-priv int rowLocationColumn

The column id (zero-based integer index) of the column which holds the row location to the base conglomerate. The default value of RowLocationColumn is the last key column. Used to obtain table/row locks on the base table rows with the index rows point at. Currently, RowLocationColumn must be the last key column.

Constructor Detail

B2Iback to summary
public B2I()

Method Detail

compressConglomerateback to summary
public void compressConglomerate(TransactionManager xact_manager, Transaction rawtran) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.compressConglomerate.

createback to summary
public void create(TransactionManager xact_manager, int segmentId, long input_conglomid, DataValueDescriptor[] template, ColumnOrdering[] columnOrder, int[] collationIds, Properties properties, int temporaryFlag) throws StandardException

Create an empty secondary index b-tree, using the generic b-tree to do the generic part of the creation process. This routine opens the newly created container, adds a single page, and makes this page the root by inserting a LeafControlRow onto this page at slot 0 and marking in that control row that the page is a root page. The following properties are specific to the b-tree secondary index:

  • "baseConglomerateId" (integer). The conglomerate id of the base conglomerate is never actually accessed by the b-tree secondary index implementation, it only serves as a namespace for row locks. This property is required.
  • "rowLocationColumn" (integer). The zero-based index into the row which the b-tree secondary index will assume holds a @see RowLocation of the base row in the base conglomerate. This value will be used for acquiring locks. In this implementation RowLocationColumn must be the last key column. This property is required.
A secondary index i (a, b) on table t (a, b, c) would have rows which looked like (a, b, row_location). baseConglomerateId is set to the conglomerate id of t. rowLocationColumns is set to 2. allowsDuplicates would be set to false, @see BTree#create. To create a unique secondary index set uniquenessColumns to 2, this means that the btree code will compare the key values but not the row id when determing uniqueness. To create a nonunique secondary index set uniquenessColumns to 3, this would mean that the uniqueness test would include the row location and since all row locations will be unique all rows inserted into the index will be differentiated (at least) by row location.
Exceptions
StandardException:
Standard exception policy.
See Also
BTree#create
defragmentConglomerateback to summary
public ScanManager defragmentConglomerate(TransactionManager xact_manager, Transaction rawtran, boolean hold, int open_mode, int lock_level, LockingPolicy locking_policy, int isolation_level) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

Open a b-tree compress scan.

B2I does not support a compress scan.

Parameters
hold:boolean

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

see openScan()

open_mode:int

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

see openScan()

lock_level:int

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

see openScan()

isolation_level:int

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

see openScan()

Returns:ScanManager

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.defragmentConglomerate.

The GroupFetchScanController to be used to fetch the rows.

Exceptions
StandardException:
Standard exception policy.
See Also
Conglomerate#defragmentConglomerate
dropback to summary
public void drop(TransactionManager xact_manager) throws StandardException

Implements abstract org.apache.derby.impl.store.access.btree.BTree.drop.

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.drop.

Drop this b-tree secondary index.

Exceptions
StandardException:
Standard exception policy.
See Also
Conglomerate#drop, BTree#drop
estimateMemoryUsageback to summary
public int estimateMemoryUsage()

Implements org.apache.derby.iapi.types.DataValueDescriptor.estimateMemoryUsage.

Doc from org.apache.derby.iapi.types.DataValueDescriptor.estimateMemoryUsage.

Estimate the memory usage in bytes of the data value and the overhead of the class.

Returns:int

the estimated memory usage

fetchMaxOnBTreeback to summary
public boolean fetchMaxOnBTree(TransactionManager xact_manager, Transaction rawtran, long conglomId, int open_mode, int lock_level, LockingPolicy locking_policy, int isolation_level, FormatableBitSet scanColumnList, DataValueDescriptor[] fetchRow) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.fetchMaxOnBTree.

Retrieve the maximum value row in an ordered conglomerate.

Returns true and fetches the rightmost row of an ordered conglomerate into "fetchRow" if there is at least one row in the conglomerate. If there are no rows in the conglomerate it returns false.

Non-ordered conglomerates will not implement this interface, calls will generate a StandardException.

RESOLVE - this interface is temporary, long term equivalent (and more) functionality will be provided by the openBackwardScan() interface.

Parameters
xact_manager:TransactionManager

The TransactionController under which this operation takes place.

rawtran:Transaction

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.fetchMaxOnBTree.

The raw store xact to associate all ops with.

conglomId:long

The identifier of the conglomerate to open the scan for.

open_mode:int

Specifiy flags to control opening of table. OPENMODE_FORUPDATE - if set open the table for update otherwise open table shared.

lock_level:int

One of (MODE_TABLE, MODE_RECORD, or MODE_NONE).

locking_policy:LockingPolicy

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.fetchMaxOnBTree.

The LockingPolicy to use to open the conglomerate.

isolation_level:int

The isolation level to lock the conglomerate at. One of (ISOLATION_READ_COMMITTED or ISOLATION_SERIALIZABLE).

scanColumnList:FormatableBitSet

A description of which columns to return from every fetch in the scan. template, and scanColumnList work together to describe the row to be returned by the scan - see RowUtil for description of how these three parameters work together to describe a "row".

fetchRow:DataValueDescriptor[]

The row to retrieve the maximum value into.

Returns:boolean

boolean indicating if a row was found and retrieved or not.

Exceptions
StandardException:
Standard exception policy.
getBtreeLockingPolicyback to summary
protected BTreeLockingPolicy getBtreeLockingPolicy(Transaction rawtran, int lock_level, int mode, int isolation_level, ConglomerateController base_cc, OpenBTree open_btree) throws StandardException

Implements abstract org.apache.derby.impl.store.access.btree.BTree.getBtreeLockingPolicy.

Create a new btree locking policy from scratch.

Exceptions
StandardException:
Standard exception policy.
getStaticCompiledConglomInfoback to summary
public StaticCompiledOpenConglomInfo getStaticCompiledConglomInfo(TransactionController xact_manager, long conglomId) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.getStaticCompiledConglomInfo.

Return static information about the conglomerate to be included in a a compiled plan.

The static info would be valid until any ddl was executed on the conglomid, and would be up to the caller to throw away when that happened. This ties in with what language already does for other invalidation of static info. The type of info in this would be containerid and array of format id's from which templates can be created. The info in this object is read only and can be shared among as many threads as necessary.

Parameters
xact_manager:TransactionController

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.getStaticCompiledConglomInfo.

The TransactionController under which this operation takes place.

conglomId:long

The identifier of the conglomerate to open.

Returns:StaticCompiledOpenConglomInfo

The static compiled information.

Exceptions
StandardException:
Standard exception policy.
getTypeFormatIdback to summary
public int getTypeFormatId()

Implements org.apache.derby.iapi.services.io.TypedFormat.getTypeFormatId.

Return my format identifier.

Returns:int

Doc from org.apache.derby.iapi.services.io.TypedFormat.getTypeFormatId.

The identifier. (A UUID stuffed in an array of 16 bytes).

See Also
org.apache.derby.iapi.services.io.TypedFormat#getTypeFormatId
loadback to summary
public long load(TransactionManager xact_manager, boolean createConglom, RowLocationRetRowSource rowSource) throws StandardException

Implements abstract org.apache.derby.impl.store.access.btree.BTree.load.

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

Bulk Load a B-tree secondary index.

Parameters
xact_manager:TransactionManager

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

The TransactionController under which this operation takes place.

createConglom:boolean

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

If true, the conglomerate is being created in the same operation as the openAndLoadConglomerate. The enables further optimization as recovery does not require page allocation to be logged.

rowSource:RowLocationRetRowSource

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

Where the rows come from.

Returns:long

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.load.

The number of rows loaded.

Exceptions
StandardException:
Standard Derby Error policy. raise SQLState.STORE_CONGLOMERATE_DUPLICATE_KEY_EXCEPTION if a duplicate key is detected in the load.
See Also
Conglomerate#load
lockTableback to summary
public final ConglomerateController lockTable(TransactionManager xact_manager, int open_mode, int lock_level, int isolation_level) throws StandardException

Implements abstract org.apache.derby.impl.store.access.btree.BTree.lockTable.

Lock the base table.

Assumes that segment of the base container is the same as the segment of the btree segment.

RESOLVE - we really want to get the lock without opening the container. raw store will be providing this.

Parameters
xact_manager:TransactionManager

Transaction to associate the lock with.

Exceptions
StandardException:
Standard exception policy.
openback to summary
public ConglomerateController open(TransactionManager xact_manager, Transaction rawtran, boolean hold, int open_mode, int lock_level, LockingPolicy locking_policy, StaticCompiledOpenConglomInfo static_info, DynamicCompiledOpenConglomInfo dynamic_info) throws StandardException

Implements abstract org.apache.derby.impl.store.access.btree.BTree.open.

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

Open a b-tree controller.

Parameters
xact_manager:TransactionManager

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

The access xact to associate all ops on cc with.

rawtran:Transaction

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

The raw store xact to associate all ops on cc with.

open_mode:int

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

A bit mask of TransactionController.MODE_* bits, indicating info about the open.

lock_level:int

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

Either TransactionController.MODE_TABLE or TransactionController.MODE_RECORD, as passed into the openConglomerate() call.

locking_policy:LockingPolicy

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

The LockingPolicy to use to open the conglomerate.

Returns:ConglomerateController

Doc from org.apache.derby.iapi.store.access.conglomerate.Conglomerate.open.

The open ConglomerateController.

Exceptions
StandardException:
Standard exception policy.
See Also
Conglomerate#open
openScanback to summary
public ScanManager openScan(TransactionManager xact_manager, Transaction rawtran, boolean hold, int open_mode, int lock_level, LockingPolicy locking_policy, int isolation_level, FormatableBitSet scanColumnList, DataValueDescriptor[] startKeyValue, int startSearchOperator, Qualifier[][] qualifier, DataValueDescriptor[] stopKeyValue, int stopSearchOperator, StaticCompiledOpenConglomInfo static_info, DynamicCompiledOpenConglomInfo dynamic_info) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.openScan.

Open a b-tree secondary index scan controller.

Exceptions
StandardException:
Standard exception policy.
See Also
Conglomerate#openScan, BTree#openScan
openStoreCostback to summary
public StoreCostController openStoreCost(TransactionManager xact_manager, Transaction rawtran) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.openStoreCost.

Return an open StoreCostController for the conglomerate.

Return an open StoreCostController which can be used to ask about the estimated row counts and costs of ScanController and ConglomerateController operations, on the given conglomerate.

Parameters
xact_manager:TransactionManager

The TransactionController under which this operation takes place.

rawtran:Transaction

raw transaction context in which scan is managed.

Returns:StoreCostController

The open StoreCostController.

Exceptions
StandardException:
Standard exception policy.
See Also
StoreCostController
purgeConglomerateback to summary
public void purgeConglomerate(TransactionManager xact_manager, Transaction rawtran) throws StandardException

Implements org.apache.derby.iapi.store.access.conglomerate.Conglomerate.purgeConglomerate.

readExternalback to summary
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException

Overrides org.apache.derby.impl.store.access.btree.BTree.readExternal.

Implements java.io.Externalizable.readExternal.

Restore the in-memory representation from the stream.

Parameters
in:ObjectInput

Doc from java.io.Externalizable.readExternal.

the stream to read data from in order to restore the object

Exceptions
IOException:

Doc from org.apache.derby.impl.store.access.btree.BTree.readExternal.

thrown by readObject()

ClassNotFoundException:
Thrown if the stored representation is serialized and a class named in the stream could not be found.
See Also
java.io.Externalizable#readExternal
traverseRightback to summary
private void traverseRight()

Private methods of B2I, arranged alphabetically.

writeExternalback to summary
public void writeExternal(ObjectOutput out) throws IOException

Overrides org.apache.derby.impl.store.access.btree.BTree.writeExternal.

Implements java.io.Externalizable.writeExternal.

Store the stored representation of the column value in the stream.

For more detailed description of the ACCESS_B2I_V3_ID and ACCESS_B2I_V5_ID formats see documentation at top of file.

Parameters
out:ObjectOutput

Doc from java.io.Externalizable.writeExternal.

the stream to write the object to

Exceptions
IOException:

Doc from org.apache.derby.impl.store.access.btree.BTree.writeExternal.

thrown by writeObject()

See Also
java.io.Externalizable#writeExternal
writeExternal_v10_2back to summary
public void writeExternal_v10_2(ObjectOutput out) throws IOException

Store the stored representation of the column value in the stream.

For more detailed description of the ACCESS_B2I_V3_ID format see documentation at top of file.

See Also
java.io.Externalizable#writeExternal
writeExternal_v10_3back to summary
public void writeExternal_v10_3(ObjectOutput out) throws IOException

Store the stored representation of the column value in the stream.

For more detailed description of the ACCESS_B2I_V3_ID and ACCESS_B2I_V4_ID formats see documentation at top of file.

See Also
java.io.Externalizable#writeExternal