uk.ac.bbk.dcs.automed.wrappers
Class OWLDLWrapper

java.lang.Object
  extended by uk.ac.ic.doc.automed.wrappers.AutoMedWrapper
      extended by uk.ac.bbk.dcs.automed.wrappers.OWLDLWrapper
All Implemented Interfaces:
CacheUser

public class OWLDLWrapper
extends AutoMedWrapper

Author:
Jianing, Lucas Zamboulis

Field Summary
static java.lang.String driverString
           
protected static java.util.logging.Logger logger
           
protected  edu.stanford.smi.protegex.owl.model.OWLModel myOWLModel
           
static java.lang.String protocolString
           
protected  java.util.Map subClassMap
          LHS: superClass, RHS: list of direct and indirect subClasses
 
Fields inherited from class uk.ac.ic.doc.automed.wrappers.AutoMedWrapper
am, awf, debug, driver, emptyKeyProtection, emptyKeys, optionKeyProtection, optionKeys, password, protocol, s, url, username
 
Constructor Summary
OWLDLWrapper()
           
OWLDLWrapper(AccessMethod am, java.lang.String password)
           
 
Method Summary
protected  void connect()
          Use the connection details held with this wrapper to connect to the data source.
protected  ASG executeIQL(ASG q)
          Execute an IQL query on the datasource.
 java.util.ArrayList extractOWLClass(java.util.Collection classCollection, java.lang.String className)
           
private  java.util.ArrayList extractOWLDataTypeProperty(edu.stanford.smi.protegex.owl.model.OWLDatatypeProperty owlP)
           
private  java.util.ArrayList extractOWLObjectProperty(edu.stanford.smi.protegex.owl.model.OWLObjectProperty owlP, java.lang.String domainOrproperty)
           
private  java.util.ArrayList extractOWLProperty(java.util.Collection propertyCollection, java.lang.String propertyName, java.lang.String domainOrproperty)
           
protected  AutoMedWrapperFactory getDefaultWrapperFactory()
          Return the default AutoMedWrapperFactory that is used to generate Schema instances from information in a data sources
 java.lang.String getProtocolName()
          The name of the Protocol that this wrapper uses
 java.util.Map getSubClassMap()
           
protected  void populateSubClassMap()
           
 
Methods inherited from class uk.ac.ic.doc.automed.wrappers.AutoMedWrapper
atDebugLevel, cacheWrapper, costIQL, deleteIQL, executeIQL, executeIQLIncrementally, executeLocalQuery, executeSourceIQL, getAccessMethod, getAutoMedPeerInstance, getAutoMedWrapper, getAutoMedWrapper, getAutoMedWrapperFactory, getDrivers, getMetadata, getOption, getOptionKeyProtection, getOptionKeys, getProtocol, getQueryParser, getRange, getSchema, getSchema, getURL, getUserName, insertIQL, newAutoMedSchema, newAutoMedWrapper, newAutoMedWrapper, newAutoMedWrapper, newAutoMedWrapperInstance, registerWrapper, selectNewAutoMedWrapper, selectNewAutoMedWrapper, setDebugLevel, setOption
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

logger

protected static java.util.logging.Logger logger

driverString

public static final java.lang.String driverString
See Also:
Constant Field Values

protocolString

public static final java.lang.String protocolString
See Also:
Constant Field Values

myOWLModel

protected edu.stanford.smi.protegex.owl.model.OWLModel myOWLModel

subClassMap

protected java.util.Map subClassMap
LHS: superClass, RHS: list of direct and indirect subClasses

Constructor Detail

OWLDLWrapper

public OWLDLWrapper()

OWLDLWrapper

public OWLDLWrapper(AccessMethod am,
                    java.lang.String password)
             throws DataSourceException
Throws:
DataSourceException
Method Detail

getSubClassMap

public java.util.Map getSubClassMap()

populateSubClassMap

protected void populateSubClassMap()
                            throws NotFoundException
Throws:
NotFoundException

connect

protected void connect()
                throws DataSourceException
Description copied from class: AutoMedWrapper
Use the connection details held with this wrapper to connect to the data source.

Specified by:
connect in class AutoMedWrapper
Throws:
DataSourceException - if unable to connect to the data source

getDefaultWrapperFactory

protected AutoMedWrapperFactory getDefaultWrapperFactory()
Description copied from class: AutoMedWrapper
Return the default AutoMedWrapperFactory that is used to generate Schema instances from information in a data sources

Specified by:
getDefaultWrapperFactory in class AutoMedWrapper

getProtocolName

public java.lang.String getProtocolName()
Description copied from class: AutoMedWrapper
The name of the Protocol that this wrapper uses

Specified by:
getProtocolName in class AutoMedWrapper

executeIQL

protected ASG executeIQL(ASG q)
                  throws DataSourceException,
                         NotFoundException
Description copied from class: AutoMedWrapper
Execute an IQL query on the datasource.

Specified by:
executeIQL in class AutoMedWrapper
Parameters:
q - An IQL query held in an ASG which complies with the limitations of what this wrapper is able to process
Returns:
An ASG containing the results of the query
Throws:
DataSourceException
NotFoundException

extractOWLProperty

private java.util.ArrayList extractOWLProperty(java.util.Collection propertyCollection,
                                               java.lang.String propertyName,
                                               java.lang.String domainOrproperty)
                                        throws DataSourceException
Throws:
DataSourceException

extractOWLDataTypeProperty

private java.util.ArrayList extractOWLDataTypeProperty(edu.stanford.smi.protegex.owl.model.OWLDatatypeProperty owlP)

extractOWLObjectProperty

private java.util.ArrayList extractOWLObjectProperty(edu.stanford.smi.protegex.owl.model.OWLObjectProperty owlP,
                                                     java.lang.String domainOrproperty)
                                              throws DataSourceException
Throws:
DataSourceException

extractOWLClass

public java.util.ArrayList extractOWLClass(java.util.Collection classCollection,
                                           java.lang.String className)