| Modifier and Type | Field and Description |
|---|---|
| protected String | |
| protected String | |
| pack-priv String | |
| protected String | |
| private static final String | |
| protected StorageFile | |
| protected String | |
| protected String |
| Access | Constructor and Description |
|---|---|
| pack-priv |
| Modifier and Type | Method and Description |
|---|---|
| pack-priv void | |
| public StorageFile | Returns: StorageFileString to prefix the random name generator. prefix, String String to suffix the random name generator. suffix)Implements org. Create and returns a temporary file in temporary file system of database. |
| pack-priv abstract void | |
| public String | Returns: the canonical nameImplements org. Get the canonical name of the database. |
| public char | Returns: the pathname separator character. (Normally '/' or '\').Implements org. Get the pathname separator character used by the StorageFile implementation. |
| public int | |
| public StorageFile | Returns: a directory nameImplements org. Get the abstract name of the directory that holds temporary files. |
| public void | init(String
The name of the directory containing the database. It comes from the system.home system property.
It may be null. A storage factory may decide to ignore this parameter. (For instance the classpath
storage factory ignores it. home, String The name of the database (directory). All relative pathnames are relative to this directory.
If null then the storage factory will only be used to deal with the directory containing
the databases. databaseName, String The name of the temporary file directory set in properties. If null then a default
directory should be used. Each database should get a separate temporary file
directory within this one to avoid collisions. tempDirName, String A unique name that can be used to create the temporary file directory for this database. uniqueName)Implements org. Classes implementing the StorageFactory interface must have a null constructor. |
| public boolean | Returns: true if the storage is fast, false if it is slow.Implements org. This method is used to determine whether the storage is fast (RAM based) or slow (disk based). |
| public boolean | isReadOnlyDatabase()
Implements org. Determine whether the database is read only. |
| pack-priv abstract StorageFile | Returns: A corresponding StorageFile objectThe path name of the file. Guaranteed not to be in the temporary file directory. If null
then the database directory should be returned. path)Construct a persistent StorageFile from a path name. |
| pack-priv abstract StorageFile | Returns: A corresponding StorageFile objectThe path name of the directory. Guaranteed not to be in the temporary file directory.
Guaranteed not to be null directoryName, String The name of the file within the directory. Guaranteed not to be null. fileName)Construct a persistent StorageFile from a directory and path name. |
| pack-priv abstract StorageFile | Returns: A corresponding StorageFile objectThe path name of the directory. Guaranteed not to be to be null. Guaranteed to be
created by a call to one of the newPersistentFile methods. directoryName, String The name of the file within the directory. Guaranteed not to be null. fileName)Construct a persistent StorageFile from a directory and path name. |
| public StorageFile | Returns: A corresponding StorageFile objectThe path name of the file path)Implements org. Construct a StorageFile from a path name. |
| public StorageFile | Returns: A corresponding StorageFile objectThe directory part of the path name. directoryName, String The name of the file within the directory. fileName)Implements org. Construct a StorageFile from a directory and file name. |
| public StorageFile | Returns: A corresponding StorageFile objectThe directory part of the path name. directoryName, String The name of the file within the directory. fileName)Implements org. Construct a StorageFile from a directory and file name. |
| private String | |
| public void | setCanonicalName(String
uniquely identifiable name for this database name)Implements org. Set the canonicalName. |
| public void | shutdown()
Implements org. The shutdown method is called during the normal shutdown of the database. |
| public boolean | Returns: true if the storage supports random access, false if it is writable.Implements org. Determine whether the storage supports random access. |
| canonicalName | back to summary |
|---|---|
| protected String canonicalName | |
| dataDirectory | back to summary |
|---|---|
| protected String dataDirectory | |
| home | back to summary |
|---|---|
| pack-priv String home | |
| separatedDataDirectory | back to summary |
|---|---|
| protected String separatedDataDirectory | |
| TEMP_DIR_PREFIX | back to summary |
|---|---|
| private static final String TEMP_DIR_PREFIX | |
| tempDir | back to summary |
|---|---|
| protected StorageFile tempDir | |
| tempDirPath | back to summary |
|---|---|
| protected String tempDirPath | |
| uniqueName | back to summary |
|---|---|
| protected String uniqueName | |
| BaseStorageFactory | back to summary |
|---|---|
| pack-priv BaseStorageFactory() Most of the initialization is done in the init method. | |
| createTempDir | back to summary |
|---|---|
| pack-priv void createTempDir() throws IOException | |
| createTemporaryFile | back to summary |
|---|---|
| public StorageFile createTemporaryFile(String prefix, String suffix) throws IOException Implements org. Create and returns a temporary file in temporary file system of database.
| |
| doInit | back to summary |
|---|---|
| pack-priv abstract void doInit() throws IOException | |
| getCanonicalName | back to summary |
|---|---|
| public String getCanonicalName() throws IOException Implements org. Get the canonical name of the database. This is a name that uniquely identifies it. It is system dependent. The normal, disk based implementation uses method java.io.File.getCanonicalPath on the directory holding the database to construct the canonical name.
| |
| getSeparator | back to summary |
|---|---|
| public char getSeparator() Implements org. Get the pathname separator character used by the StorageFile implementation.
| |
| getStorageFactoryVersion | back to summary |
|---|---|
| public int getStorageFactoryVersion() Implements org.
| |
| getTempDir | back to summary |
|---|---|
| public StorageFile getTempDir() Implements org. Get the abstract name of the directory that holds temporary files.
| |
| init | back to summary |
|---|---|
| public void init(String home, String databaseName, String tempDirName, String uniqueName) throws IOException Implements org. Classes implementing the StorageFactory interface must have a null constructor. This method is called when the database is booted up to initialize the class. It should perform all actions necessary to start the basic storage, such as creating a temporary file directory. The init method will be called once, before any other method is called, and will not be called again.
| |
| isFast | back to summary |
|---|---|
| public boolean isFast() Implements org. This method is used to determine whether the storage is fast (RAM based) or slow (disk based). It may be used by the database engine to determine the default size of the page cache.
| |
| isReadOnlyDatabase | back to summary |
|---|---|
| public boolean isReadOnlyDatabase() Implements org. Doc from org. Determine whether the database is read only. The database engine supports read-only databases, even in file systems that are writable.
| |
| newPersistentFile | back to summary |
|---|---|
| pack-priv abstract StorageFile newPersistentFile(String path) Construct a persistent StorageFile from a path name.
| |
| newPersistentFile | back to summary |
|---|---|
| pack-priv abstract StorageFile newPersistentFile(String directoryName, String fileName) Construct a persistent StorageFile from a directory and path name.
| |
| newPersistentFile | back to summary |
|---|---|
| pack-priv abstract StorageFile newPersistentFile(StorageFile directoryName, String fileName) Construct a persistent StorageFile from a directory and path name.
| |
| newStorageFile | back to summary |
|---|---|
| public StorageFile newStorageFile(String path) Implements org. Construct a StorageFile from a path name.
| |
| newStorageFile | back to summary |
|---|---|
| public StorageFile newStorageFile(String directoryName, String fileName) Implements org. Construct a StorageFile from a directory and file name.
| |
| newStorageFile | back to summary |
|---|---|
| public StorageFile newStorageFile(StorageFile directoryName, String fileName) Implements org. Construct a StorageFile from a directory and file name.
| |
| readOnlyTempRoot | back to summary |
|---|---|
| private String readOnlyTempRoot() throws IOException | |
| setCanonicalName | back to summary |
|---|---|
| public void setCanonicalName(String name) Implements org. Set the canonicalName. May need adjustment due to DERBY-5096
| |
| shutdown | back to summary |
|---|---|
| public void shutdown() Implements org. Doc from org. The shutdown method is called during the normal shutdown of the database. However, the database engine cannot guarantee that shutdown will be called. If the JVM terminates abnormally then it will not be called. | |
| supportsRandomAccess | back to summary |
|---|---|
| public boolean supportsRandomAccess() Implements org. Determine whether the storage supports random access. If random access is not supported then it will only be accessed using InputStreams and OutputStreams (if the database is writable).
| |