It's all about the answers!

Ask a question

How to implement an OSLC Query Capability in java?


Aurelien Bobey (633) | asked May 15 '14, 11:23 a.m.
I am running an oslc server, providing resources, using org.eclipse.lyo.oslc4j libraries.

I have a Resource class containing the method:
@OslcQueryCapability(
title="Resource Query Capability",
label="Resource Catalog Query",
resourceShape=OslcConstants.PATH_RESOURCE_SHAPES + "/" + Constants.PATH_RESOURCE,
resourceTypes={Constants.TYPE_RESOURCE},
usages={OslcConstants.OSLC_USAGE_DEFAULT})
@GET
@Produces({OslcMediaType.APPLICATION_RDF_XML,
OslcMediaType.APPLICATION_XML,
OslcMediaType.APPLICATION_JSON})
public Resource[] getResources(@QueryParam "oslc.where") final String where)
{
return Persistence.getResources();
}
I would like my server to be able to handle oslc queries (decribed here: http://open-services.net/bin/view/Main/OslcSimpleQuerySyntaxV1)

How should I do that?
Is there any library that I can use (org.eclipse.lyo.core.query?)

2 answers



permanent link
Donald Nong (14.5k414) | answered May 16 '14, 1:58 a.m.
You are asking a general OSLC question which is not specific to the Jazz platform. I think you'd better redirect the question to the OSLC forum http://open-services.net/forums/

permanent link
Aurelien Bobey (633) | answered May 16 '14, 4:22 a.m.
edited May 16 '14, 4:23 a.m.
Thanks for the advice. I asked my question on the OSLC forum.
If someone else is interested by this question, here is the link to my question on the OSLC forum: http://open-services.net/forums/viewthread/138/

Your answer


Register or to post your answer.


Dashboards and work items are no longer publicly available, so some links may be invalid. We now provide similar information through other means. Learn more here.