public class OntologyLoader extends Object
Constructor and Description |
---|
OntologyLoader() |
Modifier and Type | Method and Description |
---|---|
static void |
deleteOldCache(String cacheName) |
static File |
getDiskCachePath(String name)
Obtain the path for the ontology cache.
|
static boolean |
hasChanged(String cacheName) |
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(InputStream is,
String url) |
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(InputStream is,
String url,
boolean processImports)
Load an ontology into memory.
|
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(InputStream is,
String url,
boolean processImports,
com.hp.hpl.jena.ontology.OntModelSpec spec) |
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(String url)
Load an ontology into memory.
|
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(String url,
String cacheName) |
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(String url,
String cacheName,
boolean processImports) |
static com.hp.hpl.jena.ontology.OntModel |
loadMemoryModel(String url,
String cacheName,
boolean processImports,
com.hp.hpl.jena.ontology.OntModelSpec spec)
Load an ontology into memory.
|
static URLConnection |
openConnection(String url) |
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(InputStream is, String url) throws com.hp.hpl.jena.shared.JenaException
com.hp.hpl.jena.shared.JenaException
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(InputStream is, String url, boolean processImports) throws com.hp.hpl.jena.shared.JenaException
com.hp.hpl.jena.shared.JenaException
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(InputStream is, String url, boolean processImports, com.hp.hpl.jena.ontology.OntModelSpec spec) throws com.hp.hpl.jena.shared.JenaException
com.hp.hpl.jena.shared.JenaException
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(String url) throws IOException
IOException
loadMemoryModel(String, String, boolean)
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(String url, @Nullable String cacheName) throws com.hp.hpl.jena.shared.JenaException, IOException
com.hp.hpl.jena.shared.JenaException
IOException
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(String url, @Nullable String cacheName, boolean processImports) throws com.hp.hpl.jena.shared.JenaException, IOException
com.hp.hpl.jena.shared.JenaException
IOException
public static com.hp.hpl.jena.ontology.OntModel loadMemoryModel(String url, @Nullable String cacheName, boolean processImports, com.hp.hpl.jena.ontology.OntModelSpec spec) throws com.hp.hpl.jena.shared.JenaException, IOException
Uses OntModelSpec.OWL_MEM_TRANS_INF
.
url
- a URL where the OWL file is storedcacheName
- unique name of this ontology, will be used to load from disk in case of failed url connectionprocessImports
- process importsspec
- spec to use as a basiscom.hp.hpl.jena.shared.JenaException
IOException
public static boolean hasChanged(String cacheName)
public static void deleteOldCache(String cacheName) throws IOException
IOException
public static URLConnection openConnection(String url) throws IOException
IOException
Copyright © 2003–2023 UBC Michael Smith Laboratories. All rights reserved.