Examples of retrieveResource()


Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

        LDClientService ldclient = new TestLDClient(new LDClient(config));

        Assume.assumeTrue(ldclient.ping("http://dev.iks-project.eu:8080/"));

        String uriBerlin = "http://dbpedia.org/resource/Berlin";
        ClientResponse respBerlin = ldclient.retrieveResource(uriBerlin);

        RepositoryConnection conBerlin = respBerlin.getTriples().getConnection();
        conBerlin.begin();
        Assert.assertTrue(conBerlin.size() > 0);
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

   
    private void genericTestImplementation(Endpoint endpoint, String resource) throws Exception {     
        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(endpoint);
        LDClientService ldclient = new TestLDClient(new LDClient(config));
        ClientResponse response = ldclient.retrieveResource(resource);
        RepositoryConnection connection = response.getTriples().getConnection();
        connection.begin();
        Assert.assertTrue(connection.size() > 0);
        connection.commit();
        connection.close();
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

        config.addEndpoint(new SPARQLEndpoint("DBPedia (SPARQL)","http://dbpedia.org/sparql","^http://dbpedia\\.org/resource/.*"));

        LDClientService ldclient = new TestLDClient(new LDClient(config));

        String uriBerlin = "http://dbpedia.org/resource/Berlin";
        ClientResponse respBerlin = ldclient.retrieveResource(uriBerlin);

        RepositoryConnection conBerlin = respBerlin.getTriples().getConnection();
        conBerlin.begin();
        Assert.assertTrue(conBerlin.size() > 0);

View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

   
    private void genericTestImplementation(Endpoint endpoint, String resource) throws Exception {     
        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(endpoint);
        LDClientService ldclient = new TestLDClient(new LDClient(config));
        ClientResponse response = ldclient.retrieveResource(resource);
        RepositoryConnection connection = ModelCommons.asRepository(response.getData()).getConnection();
        connection.begin();
        Assert.assertTrue(connection.size() > 0);
        connection.commit();
        connection.close();
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

        config.addEndpoint(new SPARQLEndpoint("DBPedia (SPARQL)","http://dbpedia.org/sparql","^http://dbpedia\\.org/resource/.*"));

        LDClientService ldclient = new TestLDClient(new LDClient(config));

        String uriBerlin = "http://dbpedia.org/resource/Berlin";
        ClientResponse respBerlin = ldclient.retrieveResource(uriBerlin);

        RepositoryConnection conBerlin = ModelCommons.asRepository(respBerlin.getData()).getConnection();
        conBerlin.begin();
        Assert.assertTrue(conBerlin.size() > 0);

View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

        LDClientService ldclient = new TestLDClient(new LDClient(config));

        Assume.assumeTrue(ldclient.ping("http://dev.iks-project.eu:8080/"));

        String uriBerlin = "http://dbpedia.org/resource/Berlin";
        ClientResponse respBerlin = ldclient.retrieveResource(uriBerlin);

        RepositoryConnection conBerlin = ModelCommons.asRepository(respBerlin.getData()).getConnection();
        conBerlin.begin();
        Assert.assertTrue(conBerlin.size() > 0);
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.ldclient.LDClientService.retrieveResource()

        config.addEndpoint(new StanbolEndpoint("DBPedia (Stanbol Cache)","http://dev.iks-project.eu:8080/entityhub/site/dbpedia/","^http://dbpedia\\.org/resource/.*"));

        LDClientService ldclient = new TestLDClient(new LDClient(config));

        String uriBerlin = "http://dbpedia.org/resource/Berlin";
        ClientResponse respBerlin = ldclient.retrieveResource(uriBerlin);

        RepositoryConnection conBerlin = respBerlin.getTriples().getConnection();
        conBerlin.begin();
        Assert.assertTrue(conBerlin.size() > 0);

View Full Code Here

Examples of org.apache.marmotta.ldclient.api.provider.DataProvider.retrieveResource()

                Endpoint endpoint = getEndpoint(resource);

                if(endpoint != null) {
                    DataProvider provider = getDataProvider(endpoint);
                    if(provider != null) {
                        return provider.retrieveResource(resource, this, endpoint);
                    } else {
                        log.error("no service provider for type {}",endpoint.getType());
                    }
                } else {
                    // TODO: the fallback should at least be a Linked Data handler, so maybe we should merge the ldclient-provider-rdf?
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.provider.DataProvider.retrieveResource()

                Endpoint endpoint = getEndpoint(resource);

                if(endpoint != null) {
                    DataProvider provider = getDataProvider(endpoint);
                    if(provider != null) {
                        return provider.retrieveResource(resource, this, endpoint);
                    } else {
                        log.error("no service provider for type {}",endpoint.getType());
                    }
                } else {
                    // TODO: the fallback should at least be a Linked Data handler, so maybe we should merge the ldclient-provider-rdf?
View Full Code Here

Examples of org.apache.marmotta.ldclient.api.provider.DataProvider.retrieveResource()

                Endpoint endpoint = getEndpoint(resource);

                if(endpoint != null) {
                    DataProvider provider = getDataProvider(endpoint);
                    if(provider != null) {
                        return provider.retrieveResource(resource, this, endpoint);
                    } else {
                        log.error("no service provider for type {}",endpoint.getType());
                    }
                } else {
                    // TODO: the fallback should at least be a Linked Data handler, so maybe we should merge the ldclient-provider-rdf?
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.