DbStorage.driver
Class DictionaryContentExtensionDriver

java.lang.Object
  extended byDbStorage.driver.DictionaryContentExtensionDriver

public class DictionaryContentExtensionDriver
extends java.lang.Object

This class drives a dictionary content extension, this is stored in the DICTIONARY segment. Dictionary content extensions are used to storage dictionary names that can't be storage in one unit.


Field Summary
static int CONTENT_OFFSET
           
static int DICTIONARY_CONTENT_EXTENSION_OFFSET
           
 
Constructor Summary
DictionaryContentExtensionDriver()
           
 
Method Summary
static void createDictionaryContentExtension(DbStorageManager dbsm, long transactionNumber, DbUnitAddress newUnitAddress)
          Creates a dictionary content extension.
static int getContent(DbStorageManager dbsm, long transactionNumber, DbUnitAddress unitAddress, int maxLength, byte[] b, int off)
          Gets the dictionary's content stored in the specified dictionary content extension.
static void getDictionaryContentExtension(DbStorageManager dbsm, long transactionNumber, DbUnitAddress unitAddress, DbUnitAddress destiny)
          Gets the dictionary content extension's address of the specified dictionary entry.
static int setContent(DbStorageManager dbsm, long transactionNumber, DbUnitAddress unitAddress, int maxLength, byte[] b, int off)
          Sets the dictionary's content in the specified dictionary content extension.
static void setDictionaryContentExtension(DbStorageManager dbsm, long transactionNumber, DbUnitAddress unitAddress, DbUnitAddress source)
          Sets the dictionary content extension's address of the specified dictionary entry.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

DICTIONARY_CONTENT_EXTENSION_OFFSET

public static final int DICTIONARY_CONTENT_EXTENSION_OFFSET
See Also:
Constant Field Values

CONTENT_OFFSET

public static final int CONTENT_OFFSET
See Also:
Constant Field Values
Constructor Detail

DictionaryContentExtensionDriver

public DictionaryContentExtensionDriver()
Method Detail

createDictionaryContentExtension

public static void createDictionaryContentExtension(DbStorageManager dbsm,
                                                    long transactionNumber,
                                                    DbUnitAddress newUnitAddress)
                                             throws storage.StorageException,
                                                    java.io.IOException
Creates a dictionary content extension.

Parameters:
dbsm - The data base storage manager where the operation will be performed.
transactionNumber - The number of transaction.
newUnitAddress - The address of the created structure in the DICTIONARY segment.
Throws:
storage.StorageException
java.io.IOException

getDictionaryContentExtension

public static void getDictionaryContentExtension(DbStorageManager dbsm,
                                                 long transactionNumber,
                                                 DbUnitAddress unitAddress,
                                                 DbUnitAddress destiny)
                                          throws storage.StorageException,
                                                 java.io.IOException
Gets the dictionary content extension's address of the specified dictionary entry.

Parameters:
dbsm - The data base storage manager where the operation will be performed.
transactionNumber - The number of transaction.
unitAddress - The address of the dictionary content extension.
destiny - Where the retrieved unit address will be stored.
Throws:
storage.StorageException
java.io.IOException

setDictionaryContentExtension

public static void setDictionaryContentExtension(DbStorageManager dbsm,
                                                 long transactionNumber,
                                                 DbUnitAddress unitAddress,
                                                 DbUnitAddress source)
                                          throws storage.StorageException,
                                                 java.io.IOException
Sets the dictionary content extension's address of the specified dictionary entry.

Parameters:
dbsm - The data base storage manager where the operation will be performed.
transactionNumber - The number of transaction.
unitAddress - The address of the dictionary content extension.
source - Where the unit address is stored.
Throws:
storage.StorageException
java.io.IOException

getContent

public static int getContent(DbStorageManager dbsm,
                             long transactionNumber,
                             DbUnitAddress unitAddress,
                             int maxLength,
                             byte[] b,
                             int off)
                      throws storage.StorageException,
                             java.io.IOException
Gets the dictionary's content stored in the specified dictionary content extension.

Parameters:
dbsm - The data base storage manager where the operation will be performed.
transactionNumber - The number of transaction.
unitAddress - The address of the dictionary content extension.
maxLength - The maximun number of bytes to be got.
b - Where the content will be stored.
off - The begining position of b where the content will be stored.
Throws:
storage.StorageException
java.io.IOException

setContent

public static int setContent(DbStorageManager dbsm,
                             long transactionNumber,
                             DbUnitAddress unitAddress,
                             int maxLength,
                             byte[] b,
                             int off)
                      throws storage.StorageException,
                             java.io.IOException
Sets the dictionary's content in the specified dictionary content extension.

Parameters:
dbsm - The data base storage manager where the operation will be performed.
transactionNumber - The number of transaction.
unitAddress - The address of the dictionary content extension.
maxLength - The maximun number of bytes to be setted.
b - Where the content is stored.
off - The begining position of b where the content is stored.
Throws:
storage.StorageException
java.io.IOException