Class ReasonerFactoryAssembler
- java.lang.Object
-
- org.apache.jena.assembler.assemblers.AssemblerBase
-
- org.apache.jena.assembler.assemblers.ReasonerFactoryAssembler
-
- All Implemented Interfaces:
Assembler
public class ReasonerFactoryAssembler extends AssemblerBase implements Assembler
The ReasonerFactoryAssembler constructs a ReasonerFactory from the description. The factory class may be specified by a URL (which looks the class up in the registry) or by class name; otherwise it defaults to the GenericRuleReasonerFactory.If the class is specified by class name then an instance of that class is acquired by calling its
theInstance
method if it has one. Otherwise a fresh instance is constructed by calling its zero-argument constructor (and exploding if it hasn't got one).Thanks to Adam Cimarosti for provoking this code and providing an example implementation.
-
-
Field Summary
-
Fields inherited from interface org.apache.jena.assembler.Assembler
content, defaultModel, documentManager, fileManager, general, infModel, locationMapper, memoryModel, modelSource, ontModel, ontModelSpec, prefixMapping, reasonerFactory, ruleSet, unionModel
-
-
Constructor Summary
Constructors Constructor Description ReasonerFactoryAssembler()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ReasonerFactory
getReasonerFactoryByURL(Resource root, Resource reasonerURL)
Answer a ReasonerFactory which delivers reasoners with the given URLreasonerURL
.java.lang.Object
open(Assembler a, Resource root, Mode irrelevant)
The core operation: answer a new object constructed according to the object description hanging fromroot
, using the assemblera
for any sub-objects.-
Methods inherited from class org.apache.jena.assembler.assemblers.AssemblerBase
getOptionalClassName, getRequiredResource, open, open, openModel, openModel
-
-
-
-
Method Detail
-
open
public java.lang.Object open(Assembler a, Resource root, Mode irrelevant)
Description copied from interface:Assembler
The core operation: answer a new object constructed according to the object description hanging fromroot
, using the assemblera
for any sub-objects. Usemode
to decide if persistent objects are to be re-used or created; this mode is passed down to all sub-object construction.- Specified by:
open
in interfaceAssembler
- Specified by:
open
in classAssemblerBase
-
getReasonerFactoryByURL
public static ReasonerFactory getReasonerFactoryByURL(Resource root, Resource reasonerURL)
Answer a ReasonerFactory which delivers reasoners with the given URLreasonerURL
. If there is no such reasoner, throw anUnknownreasonerException
.
-
-