org.apache.derby.impl.io
Class DirStorageFactory4

java.lang.Object
  extended byorg.apache.derby.impl.io.BaseStorageFactory
      extended byorg.apache.derby.impl.io.DirStorageFactory
          extended byorg.apache.derby.impl.io.DirStorageFactory4
All Implemented Interfaces:
StorageFactory, WritableStorageFactory

public class DirStorageFactory4
extends DirStorageFactory

This class implements the WritableStorageFactory interface using features found in Java 1.4 but not in earlier versions of Java.


Field Summary
private static boolean rwsOK
           
 
Fields inherited from class org.apache.derby.impl.io.DirStorageFactory
canonicalName, dataDirectory, home, separatedDataDirectory, tempDir, tempDirPath, uniqueName
 
Fields inherited from interface org.apache.derby.io.StorageFactory
VERSION_NUMBER
 
Constructor Summary
DirStorageFactory4()
          Most of the initialization is done in the init method.
 
Method Summary
(package private)  StorageFile newPersistentFile(StorageFile directoryName, java.lang.String fileName)
          Construct a persistent StorageFile from a directory and path name.
(package private)  StorageFile newPersistentFile(java.lang.String path)
          Construct a persistent StorageFile from a path name.
(package private)  StorageFile newPersistentFile(java.lang.String directoryName, java.lang.String fileName)
          Construct a persistent StorageFile from a directory and path name.
 boolean supportsRws()
          This method tests whether the "rws" and "rwd" modes are implemented.
 
Methods inherited from class org.apache.derby.impl.io.DirStorageFactory
createTempDir, doInit, getCanonicalName, getSeparator, getStorageFactoryVersion, getTempDir, init, isFast, isReadOnlyDatabase, newStorageFile, newStorageFile, newStorageFile, shutdown, supportsRandomAccess, sync
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.apache.derby.io.StorageFactory
getCanonicalName, getSeparator, getStorageFactoryVersion, getTempDir, init, isFast, shutdown
 

Field Detail

rwsOK

private static final boolean rwsOK
Constructor Detail

DirStorageFactory4

public DirStorageFactory4()
Most of the initialization is done in the init method.

Method Detail

newPersistentFile

StorageFile newPersistentFile(java.lang.String path)
Construct a persistent StorageFile from a path name.

Overrides:
newPersistentFile in class DirStorageFactory
Parameters:
path - The path name of the file. Guaranteed not to be in the temporary file directory. If null then the database directory should be returned.
Returns:
A corresponding StorageFile object

newPersistentFile

StorageFile newPersistentFile(java.lang.String directoryName,
                              java.lang.String fileName)
Construct a persistent StorageFile from a directory and path name.

Overrides:
newPersistentFile in class DirStorageFactory
Parameters:
fileName - The name of the file within the directory. Guaranteed not to be null.
Returns:
A corresponding StorageFile object

newPersistentFile

StorageFile newPersistentFile(StorageFile directoryName,
                              java.lang.String fileName)
Construct a persistent StorageFile from a directory and path name.

Overrides:
newPersistentFile in class DirStorageFactory
Parameters:
fileName - The name of the file within the directory. Guaranteed not to be null.
Returns:
A corresponding StorageFile object

supportsRws

public boolean supportsRws()
This method tests whether the "rws" and "rwd" modes are implemented. If the "rws" method is supported then the database engine will conclude that the write methods of "rws" mode StorageRandomAccessFiles are slow but the sync method is fast and optimize accordingly.

Specified by:
supportsRws in interface WritableStorageFactory
Overrides:
supportsRws in class DirStorageFactory
Returns:
true if an StIRandomAccess file opened with "rws" or "rwd" modes immediately writes data to the underlying storage, false if not.

Built on Mon 2007-06-04 09:58:47+0400, from revision ???

Apache Derby V10.1 Engine Documentation - Copyright © 1997,2005 The Apache Software Foundation or its licensors, as applicable.