use of org.apache.jena.fuseki.server.Endpoint in project jena by apache.
the class JsonDescription method describe.
public static void describe(JsonBuilder builder, DataAccessPoint access) {
builder.startObject();
builder.key(JsonConst.dsName).value(access.getName());
builder.key(JsonConst.dsState).value(access.getDataService().isAcceptingRequests());
builder.key(JsonConst.dsService);
builder.startArray();
for (OperationName opName : access.getDataService().getOperations()) {
List<Endpoint> endpoints = access.getDataService().getOperation(opName);
describe(builder, opName, endpoints);
}
builder.finishArray();
builder.finishObject();
}
use of org.apache.jena.fuseki.server.Endpoint in project jena by apache.
the class FusekiBuilder method addServiceEP.
private static void addServiceEP(DataService dataService, OperationName opName, Resource svc, Property property) {
String p = "<" + property.getURI() + ">";
ResultSet rs = query("SELECT * { ?svc " + p + " ?ep}", svc.getModel(), "svc", svc);
for (; rs.hasNext(); ) {
QuerySolution soln = rs.next();
String epName = soln.getLiteral("ep").getLexicalForm();
Endpoint operation = new Endpoint(opName, epName);
addServiceEP(dataService, opName, epName);
//log.info(" " + opName.name + " = " + dataAccessPoint.getName() + "/" + epName) ;
}
}
use of org.apache.jena.fuseki.server.Endpoint in project jena by apache.
the class JsonDescription method describe.
private static void describe(JsonBuilder builder, OperationName opName, List<Endpoint> endpoints) {
builder.startObject();
builder.key(JsonConst.srvType).value(opName.name());
builder.key(JsonConst.srvDescription).value(opName.getDescription());
builder.key(JsonConst.srvEndpoints);
builder.startArray();
for (Endpoint endpoint : endpoints) builder.value(endpoint.getEndpoint());
builder.finishArray();
builder.finishObject();
}
Aggregations