Package nzilbb.labbcat.server.api
Class Categories
- java.lang.Object
-
- nzilbb.labbcat.server.api.APIRequestHandler
-
- nzilbb.labbcat.server.api.TableServletBase
-
- nzilbb.labbcat.server.api.Categories
-
public class Categories extends TableServletBase
/api/categories/class_id[/category] : Listing of category records.Allows listing of layer/attribute category records, returning JSON-encoded objects with the following attributes:
- class_id
- The scope of the category - either "transcript" or "speaker".
- category
- The name of the category.
- description
- The description of t/he category.
- display_order
- The order in which the category appears amongst others.
- _cantDelete
- This is not a database field, but rather is present in records returned from the server that can not currently be deleted; a string representing the reason the record can't be deleted.
The following operation, specified by the HTTP method, is supported:
- GET
- Read the records.
- Parameters
- pageNumber (integer) : The (zero-based) page to return.
- pageLength (integer) : How many rows per page (default is 20).
- Accept (string) : Equivalent of the "Accept" request header (see below).
- "Accept" request header/parameter "text/csv" to return records as Comma Separated Values. If not specified, records are returned as a JSON-encoded array of objects.
- Response Body - the standard JSON envelope, with the model as a corresponding list of records.
- Response Status
- 200 : The records could be listed.
- Author:
- Robert Fromont robert@fromont.net.nz
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class nzilbb.labbcat.server.api.TableServletBase
TableServletBase.DeleteCheck
-
-
Field Summary
-
Fields inherited from class nzilbb.labbcat.server.api.APIRequestHandler
SC_BAD_REQUEST, SC_CONFLICT, SC_FORBIDDEN, SC_INTERNAL_SERVER_ERROR, SC_METHOD_NOT_ALLOWED, SC_NOT_FOUND, SC_OK, SC_UNPROCESSABLE_CONTENT, SC_UNSUPPORTED_MEDIA_TYPE
-
-
Constructor Summary
Constructors Constructor Description Categories()
-
Method Summary
-
Methods inherited from class nzilbb.labbcat.server.api.TableServletBase
delete, get, post, put
-
Methods inherited from class nzilbb.labbcat.server.api.APIRequestHandler
GetSystemAttribute, init, writeResponse
-
-