|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectfedora.server.Parameterized
fedora.server.Pluggable
fedora.server.Module
fedora.server.storage.DefaultDOManager
Title: DefaultDOManager.java
Description: Manages the reading and writing of digital objects by instantiating an appropriate object reader or writer. Also, manages the object ingest process and the object replication process.
| Field Summary | |
static java.lang.String |
DEFAULT_STATE
|
protected java.sql.Connection |
m_connection
|
protected ConnectionPool |
m_connectionPool
|
protected ExternalContentManager |
m_contentManager
|
protected FieldSearch |
m_fieldSearch
|
protected Management |
m_management
|
protected PIDGenerator |
m_pidGenerator
|
protected DOReplicator |
m_replicator
|
protected fedora.server.resourceIndex.ResourceIndex |
m_resourceIndex
|
protected java.util.HashSet |
m_retainPIDs
|
protected java.lang.String |
m_storagePool
|
protected fedora.server.storage.translation.DOTranslator |
m_translator
|
protected DOValidator |
m_validator
|
| Constructor Summary | |
DefaultDOManager(java.util.Map moduleParameters,
Server server,
java.lang.String role)
Creates a new DefaultDOManager. |
|
| Method Summary | |
void |
doCommit(boolean cachedObjectRequired,
Context context,
DigitalObject obj,
java.lang.String logMessage,
boolean remove)
The doCommit method finalizes an ingest/update/remove of a digital object. |
FieldSearchResult |
findObjects(Context context,
java.lang.String[] resultFields,
int maxResults,
FieldSearchQuery query)
|
BDefReader |
getBDefReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
Gets a reader on an an existing behavior definition object. |
BMechReader |
getBMechReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
Gets a reader on an an existing behavior mechanism object. |
ConnectionPool |
getConnectionPool()
|
ILowlevelStorage |
getDatastreamStore()
|
java.lang.String |
getDefaultExportFormat()
|
DOValidator |
getDOValidator()
|
DOWriter |
getIngestWriter(boolean cachedObjectRequired,
Context context,
java.io.InputStream in,
java.lang.String format,
java.lang.String encoding,
boolean newPid)
Manages the INGEST process which includes validation of the ingest XML file, deserialization of the XML into a Digital Object instance, setting of properties on the object by the system (dates and states), PID validation or generation, object registry functions, getting a writer for the digital object, and ultimately writing the object to persistent storage via the writer. |
java.lang.String[] |
getNextPID(int numPIDs,
java.lang.String namespace)
Gets a list of the requested next available PIDs. the number of PIDs. |
ILowlevelStorage |
getObjectStore()
|
java.lang.String |
getOwnerId(java.lang.String pid)
|
DOReader |
getReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
Gets a reader on an an existing digital object. |
DOReplicator |
getReplicator()
|
java.lang.String[] |
getRequiredModuleRoles()
Gets the names of the roles that are required by this Pluggable.
|
java.lang.String |
getStorageCharacterEncoding()
|
java.lang.String |
getStorageFormat()
|
ILowlevelStorage |
getTempStore()
|
fedora.server.storage.translation.DOTranslator |
getTranslator()
|
DOWriter |
getWriter(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
Gets a writer on an an existing object. |
void |
initModule()
Gets initial param values. |
protected void |
initRetainPID()
|
java.lang.String[] |
listObjectPIDs(Context context)
Gets a list of PIDs (accessible in the given context) of all objects in the repository. |
boolean |
objectExists(java.lang.String pid)
Checks the object registry for the given object. |
void |
postInitModule()
Second stage of Module initialization. |
void |
releaseWriter(DOWriter writer)
Relinquishes control of a DOWriter back to the DOManager. |
FieldSearchResult |
resumeFindObjects(Context context,
java.lang.String sessionToken)
|
static java.lang.String |
toSql(java.lang.String name,
java.lang.String in)
|
| Methods inherited from class fedora.server.Module |
getRole, getServer, logConfig, logFine, logFiner, logFinest, loggingConfig, loggingFine, loggingFiner, loggingFinest, loggingInfo, loggingSevere, loggingWarning, logInfo, logSevere, logWarning, shutdownModule |
| Methods inherited from class fedora.server.Pluggable |
getHelp, getOptionalParameters, getParameterHelp, getRequiredParameters |
| Methods inherited from class fedora.server.Parameterized |
getParameter, getParameters, parameterNames, setParameter, setParameters |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
protected java.lang.String m_storagePool
protected PIDGenerator m_pidGenerator
protected fedora.server.storage.translation.DOTranslator m_translator
protected DOReplicator m_replicator
protected DOValidator m_validator
protected FieldSearch m_fieldSearch
protected ExternalContentManager m_contentManager
protected Management m_management
protected java.util.HashSet m_retainPIDs
protected fedora.server.resourceIndex.ResourceIndex m_resourceIndex
protected ConnectionPool m_connectionPool
protected java.sql.Connection m_connection
public static java.lang.String DEFAULT_STATE
| Constructor Detail |
public DefaultDOManager(java.util.Map moduleParameters,
Server server,
java.lang.String role)
throws ModuleInitializationException
| Method Detail |
public void initModule()
throws ModuleInitializationException
initModule in class ModuleModuleInitializationException - If initialization values are
invalid or initialization fails for some other reason.protected void initRetainPID()
public void postInitModule()
throws ModuleInitializationException
Module
postInitModule in class ModuleModuleInitializationException - If initialization values are
invalid or initialization fails for some other reason.public void releaseWriter(DOWriter writer)
DOManager
releaseWriter in interface DOManagerwriter - an instance of a digital object writer.public ILowlevelStorage getObjectStore()
public ILowlevelStorage getDatastreamStore()
public ILowlevelStorage getTempStore()
public ConnectionPool getConnectionPool()
public DOValidator getDOValidator()
public DOReplicator getReplicator()
public java.lang.String[] getRequiredModuleRoles()
PluggablePluggable.
By default, no roles need to be fulfilled.
getRequiredModuleRoles in class Pluggablepublic java.lang.String getStorageFormat()
public java.lang.String getDefaultExportFormat()
public java.lang.String getStorageCharacterEncoding()
public fedora.server.storage.translation.DOTranslator getTranslator()
public DOReader getReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
throws ServerException
getReader in interface RepositoryReadercontext - The context of this request.pid - The PID of the object.
ServerException - If anything went wrong.
public BMechReader getBMechReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
throws ServerException
getBMechReader in interface RepositoryReaderServerException
public BDefReader getBDefReader(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
throws ServerException
getBDefReader in interface RepositoryReaderServerException
public DOWriter getWriter(boolean cachedObjectRequired,
Context context,
java.lang.String pid)
throws ServerException,
ObjectLockedException
getWriter in interface DOManagercontext - The context of this request.pid - The PID of the object.
ServerException - If anything went wrong.
ObjectLockedException
public DOWriter getIngestWriter(boolean cachedObjectRequired,
Context context,
java.io.InputStream in,
java.lang.String format,
java.lang.String encoding,
boolean newPid)
throws ServerException
getIngestWriter in interface DOManagercontext - in - the input stream that is the XML ingest file for a digital objectformat - the format of the XML ingest file (e.g., FOXML, Fedora METS)encoding - the character encoding of the XML ingest file (e.g., UTF-8)newPid - true if the system should generate a new PID for the object
ServerException - If anything went wrong.
public void doCommit(boolean cachedObjectRequired,
Context context,
DigitalObject obj,
java.lang.String logMessage,
boolean remove)
throws ServerException
ServerException
public boolean objectExists(java.lang.String pid)
throws StorageDeviceException
StorageDeviceException
public java.lang.String getOwnerId(java.lang.String pid)
throws StorageDeviceException,
ObjectNotFoundException
StorageDeviceException
ObjectNotFoundException
public java.lang.String[] listObjectPIDs(Context context)
throws StorageDeviceException
RepositoryReader
listObjectPIDs in interface RepositoryReaderStorageDeviceException
public static java.lang.String toSql(java.lang.String name,
java.lang.String in)
public FieldSearchResult findObjects(Context context,
java.lang.String[] resultFields,
int maxResults,
FieldSearchQuery query)
throws ServerException
findObjects in interface DOManagerServerException
public FieldSearchResult resumeFindObjects(Context context,
java.lang.String sessionToken)
throws ServerException
resumeFindObjects in interface DOManagerServerException
public java.lang.String[] getNextPID(int numPIDs,
java.lang.String namespace)
throws ServerException
Gets a list of the requested next available PIDs. the number of PIDs.
getNextPID in interface DOManagernumPIDs - The number of PIDs to generate. Defaults to 1 if the number
is not a positive integer.namespace - The namespace to be used when generating the PIDs. If
null, the namespace defined by the pidNamespace
parameter in the fedora.fcfg configuration file is used.
ServerException - If an error occurs in generating the PIDs.
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||