Package org.apache.marmotta.ldclient.model

Examples of org.apache.marmotta.ldclient.model.ClientConfiguration


     * @throws Exception
     */
    @Test
    public void testDBPedia() throws Exception {

        ClientConfiguration config = new ClientConfiguration();
        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));

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

View Full Code Here


    private ClientConfiguration config;

    private List<Endpoint> endpoints;

    public LDClient() {
        this(new ClientConfiguration());
    }
View Full Code Here

      genericTestImplementation(new LdapEndpoint("Salzburg Research (LDAP)", "ldap.bu.edu", 389),
                    "cn=Sergio Fernandez,ou=USERS,ou=SRFG,dc=salzburgresearch,dc=at");
    }
   
    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);
View Full Code Here

     */
    @Ignore
    @Test
    public void testDBPedia() throws Exception {

        ClientConfiguration config = new ClientConfiguration();
        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);
View Full Code Here


    @PostConstruct
    public void initialize() {
        volatileEndpoints = new HashSet<Endpoint>();
        ldclientConfig = new ClientConfiguration();
        updateConfig();
    }
View Full Code Here

    @Before
    public void initDatabase() throws RepositoryException {
        cacheFilter = new UriPrefixFilter("http://remote/");

        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(new DummyEndpoint());


        tmpDirectory = Files.createTempDir();

        backend = new LDCachingFileBackend(tmpDirectory);
View Full Code Here

        }

        cacheFilter = new AlwaysTrueFilter<Resource>();

        try {
            ClientConfiguration config = new ClientConfiguration();

            backend = new LDCachingFileBackend(dataDirectory);
            sail = new GenericLinkedDataSail(new MemoryStore(),backend, cacheFilter, config);
            Repository repository = new SailRepository(sail);
            repository.initialize();
View Full Code Here

    @Before
    public void initDatabase() throws RepositoryException {
        cacheFilter = new UriPrefixFilter("http://remote/");

        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(new DummyEndpoint());

        store = new KiWiStore("test",jdbcUrl,jdbcUser,jdbcPass,dialect, "http://localhost/context/default", "http://localhost/context/inferred");
        lsail = new KiWiLinkedDataSail(store,cacheFilter,CACHE_CONTEXT, config);
        repository = new SailRepository(lsail);
        repository.initialize();
View Full Code Here

    private LDClientService ldclient;


    @Before
    public void setupClient() {
        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(new DummyEndpoint());

        ldclient = new LDClient(config);
    }
View Full Code Here

    @Before
    public void initDatabase() throws RepositoryException {
        cacheFilter = new UriPrefixFilter("http://localhost/");

        ClientConfiguration config = new ClientConfiguration();
        config.addEndpoint(new DummyEndpoint());

        store = new KiWiStore("test",jdbcUrl,jdbcUser,jdbcPass,dialect, "http://localhost/context/default", "http://localhost/context/inferred");
        lsail = new KiWiLinkedDataSail(store,cacheFilter,CACHE_CONTEXT, config);
        repository = new SailRepository(lsail);
        repository.initialize();
View Full Code Here

TOP

Related Classes of org.apache.marmotta.ldclient.model.ClientConfiguration

Copyright © 2018 www.massapicom. 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.