Jinx JSON plug-in
Home: http://github.com/jinx/json
Git: http://github.com/jinx/json
Author: OHSU Knight Cancer Institute
Copyright: 2012
License: MIT License
Synopsis
Jinx JSON enables JSON serialization for Jinx resources.
Installing
Jinx JSON is installed as a JRuby gem:
[sudo] jgem install jinx-json
Usage
Enable Jinx for a Java package, as described in the Jinx Usage.
require 'jinx/json'
jsoned = jinxed.to_json #=> the JSON representation of a jinxed resource
JSON[jsoned] #=> the deserialized jinxed resource
JSON
The JSON payload consists of the following:
-
The standard primitive Java properties, e.g. caTissue SpecimenCollectionGroup.surgicalPathologyNumber. If there is a Java id property, then designate that property with identifier, since id is a reserved Ruby method.
-
An object identifier property object_id which uniquely identifies the object in the scope of the JSON object graph.
-
The standard Jinx Resource reference properties, e.g. caTissue TissueSpecimen.specimenCollectionGroup. If the referenced object content contains the object_id property, then the reference resolves to the object defined in the JSON object graph with that object_id value.
Copyright
Jinx © 2012 by Oregon Health & Science University. Jinx is licensed under the MIT license. Please see the LICENSE and LEGAL files for more information.