Search in sources :

Example 1 with SystemInfo

use of org.apache.jena.sparql.mgt.SystemInfo in project jena by apache.

the class SDB method initlization2.

private static void initlization2() {
    SystemInfo systemInfo = new SystemInfo(SDB.sdbIRI, SDB.PATH, SDB.VERSION, SDB.BUILD_DATE);
    SystemARQ.registerSubSystem(systemInfo);
}
Also used : SystemInfo(org.apache.jena.sparql.mgt.SystemInfo)

Example 2 with SystemInfo

use of org.apache.jena.sparql.mgt.SystemInfo in project jena by apache.

the class TextQuery method init.

public static void init() {
    if (initialized)
        return;
    synchronized (lock) {
        if (initialized) {
            JenaSystem.logLifecycle("TextQuery.init - skip");
            return;
        }
        initialized = true;
        JenaSystem.logLifecycle("TextQuery.init - start");
        TextAssembler.init();
        SystemInfo sysInfo = new SystemInfo(IRI, PATH, VERSION, BUILD_DATE);
        SystemARQ.registerSubSystem(sysInfo);
        PropertyFunctionRegistry.get().put("http://jena.apache.org/text#query", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new TextQueryPF();
            }
        });
        JenaSystem.logLifecycle("TextQuery.init - finish");
    }
}
Also used : PropertyFunction(org.apache.jena.sparql.pfunction.PropertyFunction) SystemInfo(org.apache.jena.sparql.mgt.SystemInfo) PropertyFunctionFactory(org.apache.jena.sparql.pfunction.PropertyFunctionFactory)

Example 3 with SystemInfo

use of org.apache.jena.sparql.mgt.SystemInfo in project jena by apache.

the class RIOT method register.

public static void register() {
    if (registered)
        return;
    registered = true;
    VERSION = getVersion();
    BUILD_DATE = getBuildDate();
    SystemInfo sysInfo2 = new SystemInfo(RIOT.riotIRI, RIOT.PATH, VERSION, BUILD_DATE);
    SystemARQ.registerSubSystem(sysInfo2);
}
Also used : SystemInfo(org.apache.jena.sparql.mgt.SystemInfo)

Example 4 with SystemInfo

use of org.apache.jena.sparql.mgt.SystemInfo in project jena by apache.

the class Fuseki method init.

/**
     * Initialize an instance of the Fuseki server stack.
     * This is not done via Jena's initialization mechanism
     * but done explicitly to give more control.
     * Touching this class causes this to happen 
     * (see static block at the end of this class). 
     */
public static synchronized void init() {
    if (initialized)
        return;
    initialized = true;
    JenaSystem.init();
    SystemInfo sysInfo = new SystemInfo(FusekiIRI, PATH, VERSION, BUILD_DATE);
    SystemARQ.registerSubSystem(sysInfo);
    MappingRegistry.addPrefixMapping("fuseki", FusekiSymbolIRI);
    TDB.setOptimizerWarningFlag(false);
    // Don't set TDB batch commits.
    // This can be slower, but it less memory hungry and more predictable.
    TransactionManager.QueueBatchSize = 0;
}
Also used : SystemInfo(org.apache.jena.sparql.mgt.SystemInfo)

Example 5 with SystemInfo

use of org.apache.jena.sparql.mgt.SystemInfo in project jena by apache.

the class SpatialQuery method init.

public static void init() {
    if (initialized)
        return;
    synchronized (lock) {
        if (initialized) {
            JenaSystem.logLifecycle("SpatialQuery.init - skip");
            return;
        }
        initialized = true;
        JenaSystem.logLifecycle("SpatialQuery.init - start");
        SpatialAssembler.init();
        SystemInfo sysInfo = new SystemInfo(IRI, PATH, VERSION, BUILD_DATE);
        SystemARQ.registerSubSystem(sysInfo);
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#withinCircle", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new IsWithinCirclePF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#nearby", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new IsNearByPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#withinBox", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new IsWithinBoxPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#intersectBox", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new IntersectsBoxPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#north", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new NorthPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#south", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new SouthPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#east", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new EastPF();
            }
        });
        PropertyFunctionRegistry.get().put("http://jena.apache.org/spatial#west", new PropertyFunctionFactory() {

            @Override
            public PropertyFunction create(String uri) {
                return new WestPF();
            }
        });
        JenaSystem.logLifecycle("SpatialQuery.init - finish");
    }
}
Also used : SystemInfo(org.apache.jena.sparql.mgt.SystemInfo) PropertyFunctionFactory(org.apache.jena.sparql.pfunction.PropertyFunctionFactory) PropertyFunction(org.apache.jena.sparql.pfunction.PropertyFunction)

Aggregations

SystemInfo (org.apache.jena.sparql.mgt.SystemInfo)9 PropertyFunction (org.apache.jena.sparql.pfunction.PropertyFunction)2 PropertyFunctionFactory (org.apache.jena.sparql.pfunction.PropertyFunctionFactory)2 ArrayList (java.util.ArrayList)1 Node (org.apache.jena.graph.Node)1 Binding (org.apache.jena.sparql.engine.binding.Binding)1 BindingMap (org.apache.jena.sparql.engine.binding.BindingMap)1 QueryIterPlainWrapper (org.apache.jena.sparql.engine.iterator.QueryIterPlainWrapper)1