Skip to content

Commit f9ce9cb

Browse files
committed
added some javadocs
1 parent 865552a commit f9ce9cb

File tree

2 files changed

+46
-1
lines changed

2 files changed

+46
-1
lines changed

src/main/java/com/marklogic/client/DatabaseClient.java

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,15 @@ public interface DatabaseClient {
113113
public ServerConfigurationManager newServerConfigManager();
114114

115115
/**
116-
* Creates a PojoRepository specific to the specified class and id types.
116+
* Creates a PojoRepository specific to the specified class and its id type.
117117
* The PojoRepository provides a facade for persisting, retrieving, and
118118
* querying data contained in Java objects. Annotations are required to
119119
* identify the id field and any fields for which you wish to create indexes.
120+
*
121+
* @param clazz the class type for this PojoRepository to handle
122+
* @param idClass the class type of the id field for this clazz, must obviously
123+
* be Serializable or we'll struggle to marshall it
124+
* @return the initialized PojoRepository
120125
**/
121126
public <T, ID extends Serializable> PojoRepository<T, ID> newPojoRepository(Class<T> clazz, Class<ID> idClass);
122127

src/main/java/com/marklogic/client/document/DocumentManager.java

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -368,12 +368,52 @@ public <T extends R> T read(DocumentDescriptor desc, DocumentMetadataReadHandle
368368
public <T extends R> T read(DocumentDescriptor desc, DocumentMetadataReadHandle metadataHandle, T contentHandle, ServerTransform transform, Transaction transaction)
369369
throws ResourceNotFoundException, ForbiddenUserException, FailedRequestException;
370370

371+
/**
372+
* Reads from the database a list of documents matching the provided uris. Allows
373+
* iteration across matching documents and metadata (only if setMetadataCategories
374+
* has been called to request metadata). To find out how many of your uris matched,
375+
* call the {@link DocumentPage#size() DocumentPage.size()} method.
376+
*
377+
* @param uris the database uris identifying documents to retrieve
378+
* @return the DocumentPage of matching documents and metadata
379+
*/
371380
public DocumentPage read(String... uris);
372381

382+
/**
383+
* Reads from the database a list of documents matching the provided uris. Allows
384+
* iteration across matching documents and metadata (only if setMetadataCategories
385+
* has been called to request metadata). To find out how many of your uris matched,
386+
* call the {@link DocumentPage#size() DocumentPage.size()} method.
387+
*
388+
* @param transform the transform to be run on the server on each document (must already be installed)
389+
* @param uris the database uris identifying documents to retrieve
390+
* @return the DocumentPage of matching documents and metadata
391+
*/
373392
public DocumentPage read(ServerTransform transform, String... uris);
374393

394+
/**
395+
* Reads from the database a list of documents matching the provided uris. Allows
396+
* iteration across matching documents and metadata (only if setMetadataCategories
397+
* has been called to request metadata). To find out how many of your uris matched,
398+
* call the {@link DocumentPage#size() DocumentPage.size()} method.
399+
*
400+
* @param transaction the transaction in which this read is participating
401+
* @param uris the database uris identifying documents to retrieve
402+
* @return the DocumentPage of matching documents and metadata
403+
*/
375404
public DocumentPage read(Transaction transaction, String... uris);
376405

406+
/**
407+
* Reads from the database a list of documents matching the provided uris. Allows
408+
* iteration across matching documents and metadata (only if setMetadataCategories
409+
* has been called to request metadata). To find out how many of your uris matched,
410+
* call the {@link DocumentPage#size() DocumentPage.size()} method.
411+
*
412+
* @param transform the transform to be run on the server on each document (must already be installed)
413+
* @param transaction the transaction in which this read is participating
414+
* @param uris the database uris identifying documents to retrieve
415+
* @return the DocumentPage of matching documents and metadata
416+
*/
377417
public DocumentPage read(ServerTransform transform, Transaction transaction, String... uris);
378418

379419
public DocumentPage search(QueryDefinition querydef, long start);

0 commit comments

Comments
 (0)