|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.toplink.sdk.SDKAccessor | +--oracle.toplink.xml.XMLFileAccessor
XMLFileAccessor
is an implementation
of the XMLAccessor
interface that uses the
native O/S file system to store XML documents:
Accessor
will dynamically load a
DefaultXMLTranslator
, either by using a
JARClassLoader
, to load the translator from specific set of JAR files,
or by using the current class loader, if no JAR files have been specified.
The static method DatabaseLogin.setXMLParserJARFileNames()
is used to set the paths to the JAR files to be used for custom class loading.
XMLCall
,
XMLFileLogin
,
JARClassLoader
,
DatabaseLogin
Field Summary |
Type | Field |
---|---|
static java.lang.String |
DEFAULT_INVALID_FILENAME_CHARACTERS
A list of the default invalid file name characters that will be morphed into escape sequences. |
Constructor Summary |
XMLFileAccessor()
Default constructor. |
Method Summary |
Type | Method |
---|---|
boolean |
cachesDocumentDirectories()
Return whether the document directories are cached. |
void |
connect(DatabaseLogin login,
Session session)
Establish a connection to the "data store". |
DatabaseRow |
convert(DatabaseRow row,
Session session)
Everything in XML must be strings. |
boolean |
createsDirectoriesAsNeeded()
Return whether the accessor will create directories as needed, if they do not exist already. |
void |
createStreamSource(java.lang.String rootElementName)
Create a source for data streams for the XML documents with the specified root element name. |
java.lang.Integer |
deleteStream(java.lang.String rootElementName,
DatabaseRow row,
java.util.Vector orderedPrimaryKeyElements)
Delete the data for the specified root element and primary key. |
void |
disconnect(Session session)
Drop the connection to the "data store". |
void |
dropStreamSource(java.lang.String rootElementName)
Drop the source for data streams for the XML documents with the specified root element name. |
java.io.Reader |
getExistenceCheckStream(java.lang.String rootElementName,
DatabaseRow row,
java.util.Vector orderedPrimaryKeyElements)
If it exists, return a read stream on the data for the specified root element and primary key. |
java.io.Writer |
getExistingWriteStream(java.lang.String rootElementName,
DatabaseRow row,
java.util.Vector orderedPrimaryKeyElements)
Return a write stream that will overwrite the data for the specified root element and primary key. |
java.lang.String |
getFileExtension()
Return the standard file extension that will be appended to the primary key element value(s) to generate the complete file name. |
java.lang.String |
getFileExtension(java.lang.String rootElementName)
Return the standard file extension that will be appended to the primary key element value(s) to generate the complete file name. |
java.lang.String |
getInvalidFileNameCharacters()
Return a list of the invalid file name characters that will be morphed into escape sequences. |
java.io.Writer |
getNewWriteStream(java.lang.String rootElementName,
DatabaseRow row,
java.util.Vector orderedPrimaryKeyElements)
Return a new write stream for the specified root element and primary key. |
java.io.Reader |
getReadStream(java.lang.String rootElementName,
DatabaseRow row,
java.util.Vector orderedPrimaryKeyElements)
Return a read stream on the data for the specified root element and primary key. |
java.util.Enumeration |
getReadStreams(java.lang.String rootElementName)
Return an enumeration on a collection of read streams, one for *every* document with the specified root element. |
java.util.Enumeration |
getReadStreams(java.lang.String rootElementName,
java.util.Vector foreignKeyRows,
java.util.Vector orderedForeignKeyElements)
Return an enumeration on a collection of streams, one for every specified foreign key. |
XMLTranslator |
getXMLTranslator()
Return the default XML translator for all data store calls. |
void |
setCachesDocumentDirectories(boolean cachesDocumentDirectories)
Set whether the document directories are cached. |
void |
setCreatesDirectoriesAsNeeded(boolean createsDirectoriesAsNeeded)
Set whether the accessor will create directories as needed, if they do not exist already. |
void |
setFileExtension(java.lang.String fileExtension)
Set the standard file extension that will be appended to the primary key element value(s) to generate the complete file name. |
void |
setInvalidFileNameCharacters(java.lang.String invalidFileNameCharacters)
Set the list of the invalid file name characters that will be morphed into escape sequences. |
void |
setXMLTranslator(XMLTranslator translator)
Set the default XML translator for all data store calls. |
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Methods inherited from interface oracle.toplink.internal.databaseaccess.Accessor |
afterJTSTransactionCommit, afterJTSTransactionRollback, beginTransaction, clone, closeConnection, commitTransaction, decrementCallCount, executeCall, getCallCount, getColumnInfo, getConnection, getLocalPreallocatedSequences, getTableInfo, incrementCallCount,
isConnected, reestablishConnection, rollbackTransaction, usesExternalTransactionController |
Field Detail |
public static java.lang.String DEFAULT_INVALID_FILENAME_CHARACTERS
\ is the filename separator in DOS/Windows and the escape character in Unix
/ is the filename separator in Unix and the command option tag in DOS
: is the filename separator in MacOS and the drive indicator in DOS
* is a DOS wildcard character
? is a DOS wildcard character
" is used by DOS to delimit file names with spaces
< is a DOS redirection character
> is a DOS redirection character
| is a DOS redirection character
& is our own escape character
Constructor Detail |
public XMLFileAccessor()
Method Detail |
public boolean cachesDocumentDirectories()
public void connect(DatabaseLogin login, Session session) throws XMLDataStoreException
connect
in interface oracle.toplink.internal.databaseaccess.Accessor
connect
in class SDKAccessor
public DatabaseRow convert(DatabaseRow row, Session session)
convert
in interface XMLAccessor
public boolean createsDirectoriesAsNeeded()
public void createStreamSource(java.lang.String rootElementName) throws XMLDataStoreException
createStreamSource
in interface XMLAccessor
public java.lang.Integer deleteStream(java.lang.String rootElementName, DatabaseRow row, java.util.Vector orderedPrimaryKeyElements) throws XMLDataStoreException
deleteStream
in interface XMLAccessor
public void disconnect(Session session) throws XMLDataStoreException
disconnect
in interface oracle.toplink.internal.databaseaccess.Accessor
disconnect
in class SDKAccessor
public void dropStreamSource(java.lang.String rootElementName) throws XMLDataStoreException
dropStreamSource
in interface XMLAccessor
public java.io.Reader getExistenceCheckStream(java.lang.String rootElementName, DatabaseRow row, java.util.Vector orderedPrimaryKeyElements) throws XMLDataStoreException
getExistenceCheckStream
in interface XMLAccessor
public java.io.Writer getExistingWriteStream(java.lang.String rootElementName, DatabaseRow row, java.util.Vector orderedPrimaryKeyElements) throws XMLDataStoreException
getExistingWriteStream
in interface XMLAccessor
public java.lang.String getFileExtension()
public java.lang.String getFileExtension(java.lang.String rootElementName)
public java.lang.String getInvalidFileNameCharacters()
public java.io.Writer getNewWriteStream(java.lang.String rootElementName, DatabaseRow row, java.util.Vector orderedPrimaryKeyElements) throws XMLDataStoreException
getNewWriteStream
in interface XMLAccessor
public java.io.Reader getReadStream(java.lang.String rootElementName, DatabaseRow row, java.util.Vector orderedPrimaryKeyElements) throws XMLDataStoreException
getReadStream
in interface XMLAccessor
public java.util.Enumeration getReadStreams(java.lang.String rootElementName) throws XMLDataStoreException
getReadStreams
in interface XMLAccessor
public java.util.Enumeration getReadStreams(java.lang.String rootElementName, java.util.Vector foreignKeyRows, java.util.Vector orderedForeignKeyElements) throws XMLDataStoreException
getReadStreams
in interface XMLAccessor
public XMLTranslator getXMLTranslator()
getXMLTranslator
in interface XMLAccessor
public void setCachesDocumentDirectories(boolean cachesDocumentDirectories)
public void setCreatesDirectoriesAsNeeded(boolean createsDirectoriesAsNeeded)
public void setFileExtension(java.lang.String fileExtension)
public void setInvalidFileNameCharacters(java.lang.String invalidFileNameCharacters)
public void setXMLTranslator(XMLTranslator translator)
setXMLTranslator
in interface XMLAccessor
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |