Changes between Version 17 and Version 18 of VirtualCollectionRegistry


Ignore:
Timestamp:
08/26/14 08:56:07 (10 years ago)
Author:
Twan Goosen
Comment:

CMDI output

Legend:

Unmodified
Added
Removed
Modified
  • VirtualCollectionRegistry

    v17 v18  
    2121=== REST service ===
    2222
    23 The VCR REST service provides CRUD operations on a 'virtualcollection' resource. Its internal XML format for input and output is defined by an [source:/VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/resources/META-INF/VirtualCollection.xsd XML schema]. In addition, it supports JSON for input and output and CMDI and HTML output for individual collections (via content negotiation).
     23The VCR REST service provides CRUD operations on a 'virtualcollection' resource. Its internal XML format for input and output is defined by an [source:/VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/src/main/resources/META-INF/VirtualCollection.xsd XML schema]. In addition, it supports JSON for input and output and CMDI and HTML output for individual collections (via content negotiation). The CMDI is based on the new VirtualCollection profile ([http://catalog.clarin.eu/ds/ComponentRegistry/rest/registry/profiles/clarin.eu:cr1:p_1404130561238/xml xml], [http://catalog.clarin.eu/ds/ComponentRegistry/rest/registry/profiles/clarin.eu:cr1:p_1404130561238/xsd xsd]).
    2424
    2525A full description of the service can be found in [source:/VirtualCollectionRegistry/trunk/VirtualCollectionRegistry/doc/Protocol.txt Protocol.txt].
     
    8888Two ''!BodyWriter'' classes are implemented and registered, taking care of the '''rendering''' of !VirtualCollection object as CMDI or XML/JSON respectively, by means of different methods of the (injected) ''!VirtualCollectionMarshaller'' service. This way, a single method in ''!VirtualCollectionResource'' can handle these various serialisation options (depending on the HTTP Accept header in the client request). An additional method handles requests accepting HTML by returning a redirect ('see other') response pointing to the collection details page of the Wicket UI.
    8989
     90The CMDI output is generated by marshalling instances of the classes generated by the JAX-B Maven plugin at build time (XJC), based on the [http://catalog.clarin.eu/ds/ComponentRegistry/rest/registry/profiles/clarin.eu:cr1:p_1404130561238/xsd VirtualCollection profile schema], a copy of which is included in the sources.
     91
    9092More info:
    9193* [https://jersey.java.net/documentation/latest/jaxrs-resources.html JAX-RS resources documentation from Jersey]
    9294* [https://jersey.java.net/documentation/latest/message-body-workers.html information on custom body providers from Jersey]
     95* [http://mojo.codehaus.org/jaxb2-maven-plugin/ jaxb2-maven-plugin]
    9396
    9497==== Wicket application (UI) ====