org.apache.wsrp4j.persistence.xml.driver
Class PersistentInformationImpl

java.lang.Object
  extended byorg.apache.wsrp4j.persistence.xml.driver.PersistentInformationImpl
All Implemented Interfaces:
PersistentInformation, PersistentInformationXML

public class PersistentInformationImpl
extends java.lang.Object
implements PersistentInformationXML

Contains the persistent file store information for the castor xml file support. It's filled and returned initially by the class PersistentInformationProvider and used by the PersistentHandler

Version:
$Id: PersistentInformationImpl.java,v 1.4 2005/08/10 14:59:56 cziegeler Exp $
Author:
Ralf Altrichter

Field Summary
private  java.lang.String _extension
           
private  java.lang.String _filename
           
private  java.lang.String _filenameStub
           
private  java.lang.String _groupID
           
private  java.lang.String _mappingFileName
           
private  java.lang.String _separator
           
private  java.lang.String _storeDirectory
           
 
Constructor Summary
PersistentInformationImpl()
          Constructor
 
Method Summary
 java.lang.String getExtension()
          Returns the file extension used for persistent XML files
 java.lang.String getFilename()
          Returns a fully qualified file name for a persistent XML file.
 java.lang.String getFilenameStub()
          Returns the file name stub for persistent XML files.
 java.lang.String getGroupID()
          Returns the group identifier, used in the filenames
 java.lang.String getMappingFileName()
          Returns the XML mapping file name, fully qualified
 java.lang.String getSeparator()
          Set the Separator, to be used in a fully qualified file name.
 java.lang.String getStoreDirectory()
          Returns the directory for the persistent XML files
 void setExtension(java.lang.String extension)
          Set the file extension for persistent XML files.
 void setFilename(java.lang.String filename)
          Set the fully qualified file name for a persistent XML file.
 void setFilenameStub(java.lang.String stub)
          Set the file name stub for persistent XML files.
 void setGroupID(java.lang.String groupID)
          Set the group identifier, used in the filenames.
 void setMappingFileName(java.lang.String mappingFileName)
          Set the Castor XML mapping file name, fully qualified
 void setSeparator(java.lang.String separator)
          Set the separator character.
 void setStoreDirectory(java.lang.String storeDirectory)
          Set the Store directory for the persistent XML files
 java.lang.String toString()
           
 void updateFileName(java.lang.String token)
          Updates the file name, enhanced by a string token, like a handle to idportlet a unique persistent XML file.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

_mappingFileName

private java.lang.String _mappingFileName

_storeDirectory

private java.lang.String _storeDirectory

_filenameStub

private java.lang.String _filenameStub

_filename

private java.lang.String _filename

_groupID

private java.lang.String _groupID

_extension

private java.lang.String _extension

_separator

private java.lang.String _separator
Constructor Detail

PersistentInformationImpl

public PersistentInformationImpl()
Constructor

Method Detail

setStoreDirectory

public void setStoreDirectory(java.lang.String storeDirectory)
Set the Store directory for the persistent XML files

Specified by:
setStoreDirectory in interface PersistentInformationXML
Parameters:
storeDirectory - String name of the store

getStoreDirectory

public java.lang.String getStoreDirectory()
Returns the directory for the persistent XML files

Specified by:
getStoreDirectory in interface PersistentInformationXML
Returns:
String nanme of the store

setMappingFileName

public void setMappingFileName(java.lang.String mappingFileName)
Set the Castor XML mapping file name, fully qualified

Specified by:
setMappingFileName in interface PersistentInformationXML
Parameters:
mappingFileName - String fully qualified filename

getMappingFileName

public java.lang.String getMappingFileName()
Returns the XML mapping file name, fully qualified

Specified by:
getMappingFileName in interface PersistentInformationXML
Returns:
String fully qualified filename

setFilenameStub

public void setFilenameStub(java.lang.String stub)
Set the file name stub for persistent XML files. The name contains the store directory followed by a file separator and the class name of the object to be restored.

Specified by:
setFilenameStub in interface PersistentInformationXML
Parameters:
stub - String file name stub

getFilenameStub

public java.lang.String getFilenameStub()
Returns the file name stub for persistent XML files. @see setFilenameStub

Specified by:
getFilenameStub in interface PersistentInformationXML
Returns:
String file name stub

getFilename

public java.lang.String getFilename()
Returns a fully qualified file name for a persistent XML file.

Specified by:
getFilename in interface PersistentInformationXML
Returns:
String file name

setFilename

public void setFilename(java.lang.String filename)
Set the fully qualified file name for a persistent XML file.

Specified by:
setFilename in interface PersistentInformationXML
Parameters:
filename - String file name

getGroupID

public java.lang.String getGroupID()
Returns the group identifier, used in the filenames

Specified by:
getGroupID in interface PersistentInformation
Returns:
groupID as String

setGroupID

public void setGroupID(java.lang.String groupID)
Set the group identifier, used in the filenames.

Specified by:
setGroupID in interface PersistentInformation
Parameters:
groupID - as String

updateFileName

public void updateFileName(java.lang.String token)
Updates the file name, enhanced by a string token, like a handle to idportlet a unique persistent XML file. If a groupID is set, the groupID is used instead of the token to build the filename.

Specified by:
updateFileName in interface PersistentInformationXML
Parameters:
token - String token, like a handle

getExtension

public java.lang.String getExtension()
Returns the file extension used for persistent XML files

Specified by:
getExtension in interface PersistentInformationXML
Returns:
String file extension

setExtension

public void setExtension(java.lang.String extension)
Set the file extension for persistent XML files.

Specified by:
setExtension in interface PersistentInformationXML
Parameters:
extension - String file extension

getSeparator

public java.lang.String getSeparator()
Set the Separator, to be used in a fully qualified file name.

Specified by:
getSeparator in interface PersistentInformationXML
Returns:
String Separator character

setSeparator

public void setSeparator(java.lang.String separator)
Set the separator character. (e.g. '@')

Specified by:
setSeparator in interface PersistentInformationXML
Parameters:
separator - String Separator character

toString

public java.lang.String toString()
Specified by:
toString in interface PersistentInformationXML
Returns:
object as String


--