|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
A object which can provide documents and document information.
In the case of statefull connections to DMS, this should represent a single connection to the DMS (pooling will be handled by the infrastructure).
DocumentProvider can support transaction isolation levels very similar to java.sql.Connections. If the DocumentProvider doesn't support transaction isolation levels, it should always report TRANSACTION_NONE (i.e. it shouldn't thrown an exception).
Field Summary | |
static int |
TRANSACTION_NONE
Isolation level for no transaction support. |
static int |
TRANSACTION_READ_COMMITTED
Isolation level for dirty reads are prevented; non-repeatable reads and phantom reads can occur. |
static int |
TRANSACTION_READ_UNCOMMITTED
Isolation level for dirty reads, non-repeatable reads and phantom reads can occur. |
static int |
TRANSACTION_REPEATABLE_READ
Isolation level for dirty reads and non-repeatable reads are prevented; phantom reads can occur. |
static int |
TRANSACTION_SERIALIZABLE
Isolation level for dirty reads, non-repeatable reads and phantom reads are prevented. |
Method Summary | |
void |
close()
Close the provider down. |
DocumentIterator |
findDocumentIds(Search params)
Return the set of String document ids of documents which match the given search parameters. |
DocumentIterator |
findDocumentMetadata(Search params)
Return the set of DocumentMetadataDefs which match the given search parameters object. |
DocumentIterator |
findDocuments(Search params)
Return the set of DocumentDefs which match the given search parameters object. |
DocumentDef |
getDocument(java.lang.String id)
Return the DocumentDef with the given String document id. |
DocumentMetadataDef |
getDocumentMetadata(java.lang.String id)
Return the DocumentMetadataDef with the given String document id. |
java.sql.Timestamp |
getDocumentModifiedDate(java.lang.String id)
Get the last modified timestamp for the given document id. |
DocumentSchemaDef |
getSchema(java.lang.String schemaName)
Return the named document schema def (null if does not exist). |
DocumentIterator |
getSchemaNames()
Return the list of schema names supported in this DMS. |
java.util.Map |
getSchemas()
Return the map (name to DocumentSchemaDef) of all the schemas supported in the system. |
int |
getTransactionIsolation()
Get the document provider's current transaction isolation level. |
void |
init(java.util.Properties properties)
Initialize the DocumentProvider based upon the specified configuration properties. |
void |
reset()
Reset the connection internally to a fresh state. |
void |
setTransactionIsolation(int level)
Set the document provider's transaction isolation level. |
Field Detail |
public static final int TRANSACTION_NONE
Connection.TRANSACTION_NONE
public static final int TRANSACTION_READ_COMMITTED
Connection.TRANSACTION_READ_COMMITTED
public static final int TRANSACTION_READ_UNCOMMITTED
Connection.TRANSACTION_READ_UNCOMMITTED
public static final int TRANSACTION_REPEATABLE_READ
Connection.TRANSACTION_REPEATABLE_READ
public static final int TRANSACTION_SERIALIZABLE
Connection.TRANSACTION_SERIALIZABLE
Method Detail |
public void init(java.util.Properties properties) throws DocumentException
This will be called after the DocumentProvider has been instantiated.
properties
- the configuration propertiespublic void reset() throws DocumentException
This might include rolling back a transaction and clearing out any internal state.
public void close() throws DocumentException
This will be called before the provider is dereferenced; it should close any resources opened by init() or internally. The provider instance should not be used after this method has been invoked.
public int getTransactionIsolation() throws DocumentException
public void setTransactionIsolation(int level) throws DocumentException
public DocumentIterator findDocumentIds(Search params) throws DocumentException
params
- the search parameters.public DocumentIterator findDocuments(Search params) throws DocumentException
The implementor of DocumentProvider will need to map the parameters into the native search mechanism.
params
- the search parameters.public DocumentMetadataDef getDocumentMetadata(java.lang.String id) throws DocumentException
id
- the document id.public DocumentDef getDocument(java.lang.String id) throws DocumentException
id
- the document id.public java.sql.Timestamp getDocumentModifiedDate(java.lang.String id) throws DocumentException
id
- the document id.public DocumentIterator findDocumentMetadata(Search params) throws DocumentException
The implementor of DocumentProvider will need to map the parameters into the native search mechanism.
params
- the search parameters.public DocumentIterator getSchemaNames() throws DocumentException
public DocumentSchemaDef getSchema(java.lang.String schemaName) throws DocumentException
schemaName
- the name of the schema to find.public java.util.Map getSchemas() throws DocumentException
This operation could be time expensive.
|
BEA Systems, Inc. | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |