Skip to content

Commit fda1563

Browse files
committed
fix #366 - Clean up code to pass linter and remove -Xdoclint:none from pom.xml
(cherry picked from commit 3601df7)
1 parent 52e2c17 commit fda1563

15 files changed

+153
-39
lines changed

pom.xml

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -188,20 +188,6 @@
188188
</plugin>
189189
</plugins>
190190
</build>
191-
<profiles>
192-
<profile>
193-
<id>Java 8</id>
194-
<activation>
195-
<jdk>1.8</jdk>
196-
</activation>
197-
<properties>
198-
<!-- Disable Java 8 overly strict javadoc linter when building with Java 8
199-
http://blog.joda.org/2014/02/turning-off-doclint-in-jdk-8-javadoc.html
200-
-->
201-
<additionalparam>-Xdoclint:none</additionalparam>
202-
</properties>
203-
</profile>
204-
</profiles>
205191
<dependencies>
206192
<!-- direct build / run dependencies -->
207193
<!--

src/main/java/com/marklogic/client/admin/QueryOptionsManager.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public <T> T optionsListAs(Format format, Class<T> as)
5151
* By default, standard Java IO classes for document content are registered.
5252
*
5353
* @param listHandle a handle for reading the list of name options
54-
* @param the type of QueryOptionsListReadHandle to return
54+
* @param <T> the type of QueryOptionsListReadHandle to return
5555
* @return the handle populated with the names
5656
*/
5757
public <T extends QueryOptionsListReadHandle> T optionsList(T listHandle)
@@ -75,7 +75,7 @@ public <T> T readOptionsAs(String name, Format format, Class<T> as)
7575
*
7676
* @param name the name of options configuration stored on MarkLogic REST instance.
7777
* @param queryOptionsHandle an object into which to fetch the query options.
78-
* @param the type of QueryOptionsListReadHandle to return
78+
* @param <T> the type of QueryOptionsListReadHandle to return
7979
* @return an object holding the query configurations
8080
*/
8181
public <T extends QueryOptionsReadHandle> T readOptions(String name, T queryOptionsHandle)

src/main/java/com/marklogic/client/admin/TransformExtensionsManager.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -69,6 +69,7 @@ public interface TransformExtensionsManager {
6969
/**
7070
* Lists the installed transform extensions.
7171
* @param listHandle a handle on a JSON or XML representation of the list
72+
* @param <T> the type of StructureReadHandle to return
7273
* @return the list handle
7374
*/
7475
public <T extends StructureReadHandle> T listTransforms(T listHandle)

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

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -388,6 +388,7 @@ public <T extends R> T read(DocumentDescriptor desc, DocumentMetadataReadHandle
388388
* @param contentHandle a handle for reading the content of the document
389389
* @param transform a server transform to modify the document content
390390
* @param transaction a open transaction under which the document may have been created or deleted
391+
* @param <T> the type of content handle to return
391392
* @return the content handle populated with the content of the document in the database
392393
*/
393394
public <T extends R> T read(DocumentDescriptor desc, DocumentMetadataReadHandle metadataHandle, T contentHandle, ServerTransform transform, Transaction transaction)
@@ -1112,6 +1113,7 @@ public void patchAs(String docId, Object patch)
11121113
*
11131114
* @param docId the URI identifier for the document
11141115
* @param metadataHandle a handle for reading the metadata of the document
1116+
* @param <T> the type of DocumentMetadataReadHandle to return
11151117
* @return the metadata handle populated with the metadata for the document in the database
11161118
*/
11171119
public <T extends DocumentMetadataReadHandle> T readMetadata(String docId, T metadataHandle)
@@ -1124,6 +1126,7 @@ public <T extends DocumentMetadataReadHandle> T readMetadata(String docId, T met
11241126
* @param docId the URI identifier for the document
11251127
* @param metadataHandle a handle for reading the metadata of the document
11261128
* @param transaction a open transaction under which the document may have been created or deleted
1129+
* @param <T> the type of DocumentMetadataReadHandle to return
11271130
* @return the metadata handle populated with the metadata for the document in the database
11281131
*/
11291132
public <T extends DocumentMetadataReadHandle> T readMetadata(String docId, T metadataHandle, Transaction transaction)

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

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,11 @@
3737
* you must call close() to free the underlying resources.
3838
*/
3939
public interface DocumentPage extends Page<DocumentRecord>, Closeable {
40-
/** Convenience method combines the functionality of Page.next() and DocumentRecord.getContent(). */
40+
/** Convenience method combines the functionality of Page.next() and DocumentRecord.getContent().
41+
* @param contentHandle the handle top populate with the contents from the next document
42+
* @param <T> the type of AbstractReadHandle to return
43+
* @return the contents of the next document
44+
*/
4145
public <T extends AbstractReadHandle> T nextContent(T contentHandle);
4246
/** Frees the underlying resources, including the http connection. */
4347
public void close();

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

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -84,6 +84,8 @@ public String toString() {
8484

8585
/**
8686
* Specifies the language for this patch to use
87+
* @param pathLang the language (XPath or JSONPath)
88+
* @return the patch builder (for convenient chaining)
8789
*/
8890
public DocumentPatchBuilder pathLanguage(PathLanguage pathLang);
8991

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

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929
*/
3030
public interface DocumentWriteSet extends Set<DocumentWriteOperation> {
3131
/** Sets the default metadata for this write set for all documents added after this call
32+
* @param metadataHandle the handle containing the metatdata to use as defaults
3233
* @return this instance (for method chaining)
3334
*/
3435
public DocumentWriteSet addDefault(DocumentMetadataWriteHandle metadataHandle);

src/main/java/com/marklogic/client/pojo/PojoRepository.java

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -189,7 +189,7 @@ public long count(String[] collections, Transaction transaction)
189189
*/
190190
public long count(PojoQueryDefinition query)
191191
throws ForbiddenUserException, FailedRequestException;
192-
192+
193193
/** In the context of transaction, the number of documents of the type managed by
194194
* this PojoRepository persisted in the database which match the query
195195
* @param query the query which results much match (queries are run unfiltered by default)
@@ -201,8 +201,10 @@ public long count(PojoQueryDefinition query)
201201
*/
202202
public long count(PojoQueryDefinition query, Transaction transaction)
203203
throws ForbiddenUserException, FailedRequestException;
204-
205-
/** Deletes from the database the documents with the corresponding ids */
204+
205+
/** Deletes from the database the persisted pojo instances with the corresponding ids
206+
* @param ids the ids for the pojo instances to delete from the server
207+
*/
206208
public void delete(ID... ids)
207209
throws ResourceNotFoundException, ForbiddenUserException, FailedRequestException;
208210

src/main/java/com/marklogic/client/query/MatchDocumentSummary.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,7 @@ public interface MatchDocumentSummary {
156156

157157
/**
158158
* Returns the format associated with this document
159+
* @return the format
159160
*/
160161
public Format getFormat();
161162

@@ -169,6 +170,7 @@ public interface MatchDocumentSummary {
169170
/**
170171
* Returns the relevance information for the result.
171172
* @param handle An XML handle for reading the relevance information.
173+
* @param <T> the type of XMLReadHandle to return
172174
* @return The handle on the relevance information.
173175
*/
174176
public <T extends XMLReadHandle> T getRelevanceInfo(T handle);

src/main/java/com/marklogic/client/query/QueryManager.java

Lines changed: 14 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -361,6 +361,7 @@ public enum QueryView {
361361
* @param valueHandle a handle for reading the values for the matched documents
362362
* @param start the offset of the first returned result (where 1 is the first value)
363363
* @param transaction a open transaction for matching documents
364+
* @param <T> the type of ValuesReadHandle to return
364365
* @return the handle populated with the values from the index
365366
*/
366367
public <T extends ValuesReadHandle> T values(ValuesDefinition valdef, T valueHandle, long start, Transaction transaction);
@@ -370,6 +371,7 @@ public enum QueryView {
370371
* based on query criteria and, potentially, previously saved query options.
371372
* @param valdef the definition of query criteria and query options
372373
* @param tupleHandle a handle for reading the tuples for the matched documents
374+
* @param <T> the type of TuplesReadHandle to return
373375
* @return the handle populated with the tuples from the index
374376
*/
375377
public <T extends TuplesReadHandle> T tuples(ValuesDefinition valdef, T tupleHandle);
@@ -380,6 +382,7 @@ public enum QueryView {
380382
* @param valdef the definition of query criteria and query options
381383
* @param tupleHandle a handle for reading the tuples for the matched documents
382384
* @param start the offset of the first returned result (where 1 is the first tuple)
385+
* @param <T> the type of TuplesReadHandle to return
383386
* @return the handle populated with the tuples from the index
384387
*/
385388
public <T extends TuplesReadHandle> T tuples(ValuesDefinition valdef, T tupleHandle, long start);
@@ -392,6 +395,7 @@ public enum QueryView {
392395
* @param valdef the definition of query criteria and query options
393396
* @param tupleHandle a handle for reading the tuples for the matched documents
394397
* @param transaction a open transaction for matching documents
398+
* @param <T> the type of TuplesReadHandle to return
395399
* @return the handle populated with the tuples from the index
396400
*/
397401
public <T extends TuplesReadHandle> T tuples(ValuesDefinition valdef, T tupleHandle, Transaction transaction);
@@ -405,6 +409,7 @@ public enum QueryView {
405409
* @param tupleHandle a handle for reading the tuples for the matched documents
406410
* @param start the offset of the first returned result (where 1 is the first tuple)
407411
* @param transaction a open transaction for matching documents
412+
* @param <T> the type of TuplesReadHandle to return
408413
* @return the handle populated with the tuples from the index
409414
*/
410415
public <T extends TuplesReadHandle> T tuples(ValuesDefinition valdef, T tupleHandle, long start, Transaction transaction);
@@ -414,6 +419,7 @@ public enum QueryView {
414419
* values list definition and, potentially, previously saved query options.
415420
* @param valdef the definition of the query criteria and options
416421
* @param valueHandle a handle for reading the list of names lexicon configurations
422+
* @param <T> the type of ValuesListReadHandle to return
417423
* @return the handle populated with the names
418424
*/
419425
public <T extends ValuesListReadHandle> T valuesList(ValuesListDefinition valdef, T valueHandle);
@@ -426,13 +432,15 @@ public enum QueryView {
426432
* @param valdef the definition of the query criteria and options
427433
* @param valueHandle a handle for reading the list of names lexicon configurations
428434
* @param transaction a open transaction for matching documents
435+
* @param <T> the type of ValuesListReadHandle to return
429436
* @return the handle populated with the names
430437
*/
431438
public <T extends ValuesListReadHandle> T valuesList(ValuesListDefinition valdef, T valueHandle, Transaction transaction);
432439

433440
/**
434441
* Retrieves the list of available named query options.
435442
* @param listHandle a handle for reading the list of name options
443+
* @param <T> the type of QueryOptionsListReadHandle to return
436444
* @return the handle populated with the names
437445
*/
438446
public <T extends QueryOptionsListReadHandle> T optionsList(T listHandle);
@@ -443,6 +451,7 @@ public enum QueryView {
443451
* options deleted by the transaction.
444452
* @param valueHandle a handle for reading the list of name options
445453
* @param transaction a open transaction for matching documents
454+
* @param <T> the type of QueryOptionsListReadHandle to return
446455
* @return the handle populated with the names
447456
*/
448457
public <T extends QueryOptionsListReadHandle> T optionsList(T valueHandle, Transaction transaction);
@@ -471,17 +480,19 @@ public enum QueryView {
471480
public MatchDocumentSummary findOne(QueryDefinition querydef, Transaction transaction);
472481

473482
/**
474-
* Converts a query by example into a combined query that expresses the criteria
475-
* as a structured search.
483+
* Sends a query by example to the server to convert into a combined query
484+
* that expresses the criteria as a structured search.
476485
* @param query the query by example
477-
* @param convertedHandle
486+
* @param convertedHandle the container to use for the new converted query
487+
* @param <T> the type of StructureReadHandle to return
478488
* @return the handle populated with the combined query
479489
*/
480490
public <T extends StructureReadHandle> T convert(RawQueryByExampleDefinition query, T convertedHandle);
481491
/**
482492
* Checks a query by example for mistakes in expressing the criteria.
483493
* @param query the query by example
484494
* @param reportHandle a handle for reading the validation report
495+
* @param <T> the type of StructureReadHandle to return
485496
* @return the handle populated with the validation report
486497
*/
487498
public <T extends StructureReadHandle> T validate(RawQueryByExampleDefinition query, T reportHandle);

0 commit comments

Comments
 (0)