Improving documentation

This commit is contained in:
Luca Frosini 2022-09-16 12:42:58 +02:00
parent 42433c4007
commit 3455159ecc
1 changed files with 50 additions and 46 deletions

View File

@ -52,41 +52,8 @@ public class Item extends REST<CKANPackage> implements org.gcube.gcat.api.interf
* <h4>Filtering options</h4>
* <p>
* The listing method offers options to filter the results, thus enacting to search for items including spatial search (see ext_bbox below).<br/>
* It accepts the following query parameters (a subset of Solr search query parameters, see Solr Query Syntax):
* </p>
*
* <dl>
* <dt>q (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:"*:*"</em><br/>
* The solr query. see Solr Query Syntax<br/>
* E.g. <code>/items?q=title:foo</code> returns the items with word "foo" in the title.<br/>
* E.g. <code>/items?q=extras_systemtype:MyProfile</code> returns the items having the profile <em>MyProfile</em>
* </dd>
*
* <dt>fq (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:null</em>.<br/>
* Filter query. A query string that limits the query results without influencing their scores.<br/>
* E.g. <code>/items?q=title:foo&fq=notes:bar</code> returns with word "foo" in the 'title' and the word "bar" in the 'notes'.
* </dd>
*
* <dt>fq_list (list of strings)</dt>
* <dd>
* <em>Optional</em>.<em>Default:null</em>.<br/>
* Additional filter queries to apply.<br/>
* E.g. <code>/items?q=title:foo&fq_list=...</code> returns the items with word "foo" in the 'title'.
* </dd>
*
* <dt>sort (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:"relevance asc, metadata_modified desc"</em>.<br/>
* Sorting of the search results.<br/>
* As per the solr documentation, this is a comma-separated string of field names and sort-orderings.<br/>
* E.g. <code>/items?q=title:foo&sort=name+asc</code> returns the items with word "foo" in the 'title'
* sorting the results by name ascending.
* </dd>
*
* <dt>include_private (bool)</dt>
* <dd>
* <em>Optional</em>.<em>Default:false</em>.<br/>
@ -118,10 +85,9 @@ public class Item extends REST<CKANPackage> implements org.gcube.gcat.api.interf
* If True, the returned array list contains the whole item representation and not only the id (i.e. the name).
* E.g. <code>/items?limit=10&offset=0&all_fields=true</code>
* </dd>
*
* </dl>
*
* <h4>Moderated Catalogues options</h4>
* <h4>Moderated Catalog filtering options</h4>
* <dl>
* <dt>status (enum)</dt>
* <dd>
@ -131,6 +97,44 @@ public class Item extends REST<CKANPackage> implements org.gcube.gcat.api.interf
* If null return both approved items and items which have been published before the activation of the moderation.
* </dd>
* </dl>
* </p>
*
* <h4>Solr based Filtering options</h4>
* <p>
* It accepts the following query parameters (a subset of Solr search query parameters, see Solr Query Syntax):
* </p>
* <dl>
* <dt>q (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:"*:*"</em><br/>
* The solr query.<br/>
* E.g. <code>/items?q=title:foo</code> returns the items with word "foo" in the title.<br/>
* E.g. <code>/items?q=extras_systemtype:MyProfile</code> returns the items having the profile <em>MyProfile</em>
* </dd>
*
* <dt>fq (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:null</em>.<br/>
* Filter query. A query string that limits the query results without influencing their scores.<br/>
* E.g. <code>/items?q=title:foo&fq=notes:bar</code> returns with word "foo" in the 'title' and the word "bar" in the 'notes'.
* </dd>
*
* <dt>fq_list (list of strings)</dt>
* <dd>
* <em>Optional</em>.<em>Default:null</em>.<br/>
* Additional filter queries to apply.<br/>
* E.g. <code>/items?q=title:foo&fq_list=...</code> returns the items with word "foo" in the 'title'.
* </dd>
*
* <dt>sort (string)</dt>
* <dd>
* <em>Optional</em>.<em>Default:"relevance asc, metadata_modified desc"</em>.<br/>
* Sorting of the search results.<br/>
* As per the solr documentation, this is a comma-separated string of field names and sort-orderings.<br/>
* E.g. <code>/items?q=title:foo&sort=name+asc</code> returns the items with word "foo" in the 'title'
* sorting the results by name ascending.
* </dd>
* <dl>
*
*
* @param limit To get unlimited results the limit query parameters must be set to -1.