Search in sources :

Example 6 with Timer

use of org.apache.jena.atlas.lib.Timer in project jena by apache.

the class TDBLoader method loadModel.

/** Load the contents of a list of URLs into a model - may not be as efficient as bulk loading into a TDB graph  */
public static void loadModel(Model model, List<String> urls, boolean showProgress) {
    Timer timer = new Timer();
    timer.startTimer();
    for (String s : urls) {
        if (showProgress)
            System.out.printf("Load: %s\n", s);
        loadModel(model, s, showProgress);
    }
    long time = timer.endTimer();
    if (showProgress)
        System.out.printf("Time for load: %.2fs\n", time / 1000.0);
    model.close();
}
Also used : Timer(org.apache.jena.atlas.lib.Timer)

Example 7 with Timer

use of org.apache.jena.atlas.lib.Timer in project jena by apache.

the class GraphLoadMonitor method resetTimer.

public void resetTimer() {
    if (timer != null)
        timer.endTimer();
    timer = new Timer();
    timer.startTimer();
}
Also used : Timer(org.apache.jena.atlas.lib.Timer)

Example 8 with Timer

use of org.apache.jena.atlas.lib.Timer in project jena by apache.

the class QueryIteratorTiming method start.

private void start() {
    if (timer == null) {
        timer = new Timer();
        timer.startTimer();
        milliseconds = NotFinished;
    }
}
Also used : Timer(org.apache.jena.atlas.lib.Timer)

Aggregations

Timer (org.apache.jena.atlas.lib.Timer)8 TupleIndex (org.apache.jena.tdb.store.tupletable.TupleIndex)2 InputStream (java.io.InputStream)1 Semaphore (java.util.concurrent.Semaphore)1 Token (org.apache.jena.riot.tokens.Token)1 Tokenizer (org.apache.jena.riot.tokens.Tokenizer)1