edu.stanford.smi.protegex.owl.swrl.model
Class SWRLFactory

java.lang.Object
  extended byedu.stanford.smi.protegex.owl.swrl.model.SWRLFactory

public class SWRLFactory
extends Object

A utility class that can (and should) be used to create and access SWRL related objects in the ontology.

Author:
Martin O'Connor , Holger Knublauch

Field Summary
private  OWLNamedClass atomListCls
           
private  OWLNamedClass builtinAtomCls
           
private  OWLNamedClass classAtomCls
           
private  OWLNamedClass dataRangeAtomCls
           
private  OWLNamedClass dataValuedPropertyAtomCls
           
private  OWLNamedClass differentIndividualsAtomCls
           
private  OWLNamedClass impCls
           
private  OWLNamedClass individualPropertyAtom
           
private  OWLModel owlModel
           
private  OWLNamedClass sameIndividualAtomCls
           
 
Constructor Summary
SWRLFactory(OWLModel owlModel)
           
 
Method Summary
 SWRLAtomList createAtomList()
           
 SWRLAtomList createAtomList(Collection atoms)
           
 SWRLBuiltin createBuiltin(String name)
           
 SWRLBuiltinAtom createBuiltinAtom(SWRLBuiltin swrlBuiltin, Iterator arguments)
           
 SWRLBuiltinAtom createBuiltinAtom(SWRLBuiltin swrlBuiltin, RDFList arguments)
           
 SWRLClassAtom createClassAtom(RDFSNamedClass aClass, RDFResource iObject)
           
 SWRLDataRangeAtom createDataRangeAtom(RDFResource dataRange, RDFObject dObject)
           
 SWRLDatavaluedPropertyAtom createDatavaluedPropertyAtom(OWLDatatypeProperty datatypeSlot, RDFResource iObject, RDFObject dObject)
           
 SWRLDifferentIndividualsAtom createDifferentIndividualsAtom(RDFResource argument1, RDFResource argument2)
           
 SWRLImp createImp()
           
 SWRLImp createImp(String expression)
           
 SWRLImp createImp(SWRLAtom headAtom, Collection bodyAtoms)
           
 SWRLImp createImp(SWRLAtomList head, SWRLAtomList body)
           
 SWRLIndividualPropertyAtom createIndividualPropertyAtom(OWLObjectProperty objectSlot, RDFResource iObject1, RDFResource iObject2)
           
 SWRLSameIndividualAtom createSameIndividualAtom(RDFResource argument1, RDFResource argument2)
           
 SWRLVariable createVariable(String name)
           
 SWRLBuiltin getBuiltin(String name)
           
 Collection getBuiltins()
           
 Collection getImps()
           
 String getNewImpName()
           
 SWRLVariable getVariable(String name)
           
 Collection getVariables()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

atomListCls

private OWLNamedClass atomListCls

builtinAtomCls

private OWLNamedClass builtinAtomCls

classAtomCls

private OWLNamedClass classAtomCls

dataRangeAtomCls

private OWLNamedClass dataRangeAtomCls

dataValuedPropertyAtomCls

private OWLNamedClass dataValuedPropertyAtomCls

differentIndividualsAtomCls

private OWLNamedClass differentIndividualsAtomCls

impCls

private OWLNamedClass impCls

individualPropertyAtom

private OWLNamedClass individualPropertyAtom

owlModel

private OWLModel owlModel

sameIndividualAtomCls

private OWLNamedClass sameIndividualAtomCls
Constructor Detail

SWRLFactory

public SWRLFactory(OWLModel owlModel)
Method Detail

createImp

public SWRLImp createImp()

createImp

public SWRLImp createImp(String expression)
                  throws SWRLParseException
Throws:
SWRLParseException

createImp

public SWRLImp createImp(SWRLAtom headAtom,
                         Collection bodyAtoms)

createImp

public SWRLImp createImp(SWRLAtomList head,
                         SWRLAtomList body)

createAtomList

public SWRLAtomList createAtomList()

createAtomList

public SWRLAtomList createAtomList(Collection atoms)

createBuiltinAtom

public SWRLBuiltinAtom createBuiltinAtom(SWRLBuiltin swrlBuiltin,
                                         Iterator arguments)

createBuiltinAtom

public SWRLBuiltinAtom createBuiltinAtom(SWRLBuiltin swrlBuiltin,
                                         RDFList arguments)

createClassAtom

public SWRLClassAtom createClassAtom(RDFSNamedClass aClass,
                                     RDFResource iObject)

createDataRangeAtom

public SWRLDataRangeAtom createDataRangeAtom(RDFResource dataRange,
                                             RDFObject dObject)

createDatavaluedPropertyAtom

public SWRLDatavaluedPropertyAtom createDatavaluedPropertyAtom(OWLDatatypeProperty datatypeSlot,
                                                               RDFResource iObject,
                                                               RDFObject dObject)

createIndividualPropertyAtom

public SWRLIndividualPropertyAtom createIndividualPropertyAtom(OWLObjectProperty objectSlot,
                                                               RDFResource iObject1,
                                                               RDFResource iObject2)

createDifferentIndividualsAtom

public SWRLDifferentIndividualsAtom createDifferentIndividualsAtom(RDFResource argument1,
                                                                   RDFResource argument2)

createSameIndividualAtom

public SWRLSameIndividualAtom createSameIndividualAtom(RDFResource argument1,
                                                       RDFResource argument2)

createVariable

public SWRLVariable createVariable(String name)

createBuiltin

public SWRLBuiltin createBuiltin(String name)

getBuiltin

public SWRLBuiltin getBuiltin(String name)

getBuiltins

public Collection getBuiltins()

getImps

public Collection getImps()

getNewImpName

public String getNewImpName()

getVariable

public SWRLVariable getVariable(String name)

getVariables

public Collection getVariables()