[OTDev] Needed some help with restlet
Nina Jeliazkova nina at acad.bgTue Jan 26 09:08:59 CET 2010
- Previous message: [OTDev] Needed some help with restlet
- Next message: [OTDev] Needed some help with restlet
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Hi Surajit, Media type should match the format of the content send by the service. If you use JenaModel to generate RDF/XML, it should be Application_RDF_XML. This is what OpenTox has agreed as default RDF media type. Optionally, you might select to support other RDF flavours, which is rather straightforward with Jena (see code in my previous email). MODEL_ALL, or "model/*" is actually not related to RDF at all. If I understand right, it is a generic mime type for representing 3D graphical objects [2], like VRML[3]. model/iges iges model/iges igs model/mesh mesh model/mesh msh model/mesh silo model/vrml vrml model/vrml wrl Best regards, Nina [1] http://www.restlet.org/documentation/2.0/jse/api/org/restlet/data/MediaType.html [2] http://www.mimetype.org/ [3] http://en.wikipedia.org/wiki/VRML || surajit ray wrote: > I have tried to implement your idea in the attached example ... > > Whats the mediatype to be used. As you can see I have used |*MODEL_ALL > <../../../org/restlet/data/MediaType.html#MODEL_ALL>*| > > Some other options I thought could also fit would be > |*APPLICATION_RDF_XML > <../../../org/restlet/data/MediaType.html#APPLICATION_RDF_XML>*| > |*APPLICATION_JAVA_OBJECT > <../../../org/restlet/data/MediaType.html#APPLICATION_JAVA_OBJECT>*| > |*TEXT_RDF_N3 <../../../org/restlet/data/MediaType.html#TEXT_RDF_N3>*|_ _ > |*TEXT_XML <../../../org/restlet/data/MediaType.html#TEXT_XML>*| > > I must add that there is very little documentation available for the > restlet API. It is very difficult to make out the options and their > implications ! > > Thanks in advance > surajit > On Tue, Jan 26, 2010 at 1:01 PM, surajit ray <mr.surajit.ray at gmail.com > <mailto:mr.surajit.ray at gmail.com>> wrote: > > Hi Nina, > Thanks for the information > > Could you please clarify if the outputstreamrepresentation is a > class from restlet 2.0 > > I could not find it in the current stable. There is however a > Outputrepresentation which is a subclass of Streamrepresentation. > Is this the one you were referring to ? > > As a test I was using this : (see attached java file) > > Would it be incorrect to use it as such ? > > > > > On Mon, Jan 25, 2010 at 6:30 PM, Nina Jeliazkova <nina at acad.bg > <mailto:nina at acad.bg>> wrote: > > surajit ray wrote: > > Hi, > > I was wondering what type of Representation to use for a > Jena model (within > > the Restlet framework ) ? > > > > > OutputStreamRepresentation and write the model into the > output stream. > > Hope this helps, > Nina > _______________________________________________ > Development mailing list > Development at opentox.org <mailto:Development at opentox.org> > http://www.opentox.org/mailman/listinfo/development > > > > > -- > Surajit Ray > Partner > www.rareindianart.com <http://www.rareindianart.com> > > > > > -- > Surajit Ray > Partner > www.rareindianart.com <http://www.rareindianart.com>
- Previous message: [OTDev] Needed some help with restlet
- Next message: [OTDev] Needed some help with restlet
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Development mailing list