JAVA/CORBA CLASSES


Collecting all documents and all unprocessed documents
Example

Use getAllDocuments of Database to get a DocumentCollection object that contains all the data documents in a database. Use getUnprocessedDocuments in AgentContext to get documents that depend on the specifications of the current agent, for example, those documents that are selected or those documents modified since the agent last ran. Use getModifiedDocuments in Database to get documents modified since a specified time.

The DocumentCollection class has the following properties and methods for accessing documents:


In loops, use the getNextDocument and getPrevDocument methods that do not take a parameter. These methods provide better performance than the methods that take a Document parameter; in particular, the methods that take a parameter invalidate the cache for remote (IIOP) operations. Do not use getCount and getNthDocument for loops for performance reasons.

The documents in a document collection are ordered only if the collection is the result of a search. Otherwise, you cannot depend on the documents to be a particular sequence.

Use addDocument and deleteDocument to adjust a DocumentCollection object after you create it.

When you use an agent to work on unprocessed documents, you must mark those documents as updated so that they are recognized as old documents in subsequent runs. Use either updateAll of NotesDocumentCollection or updateProcessedDoc of AgentContext.

The DocumentCollection class contains the following properties:


Example
See Also