owltools.ontologyrelease
Class OortConfiguration

java.lang.Object
  extended by owltools.ontologyrelease.OortConfiguration
Direct Known Subclasses:
OortGuiConfiguration

public class OortConfiguration
extends Object

Parameters for OboOntologyReleaseRunner. Contains methods to read and write the configuration from Properties.


Nested Class Summary
static class OortConfiguration.MacroStrategy
           
 
Constructor Summary
OortConfiguration()
           
 
Method Summary
 void addBridgeOntology(String bridgeOntology)
           
 void addPath(String path)
           
 void addSourceOntologyPrefix(String prefix)
           
 void addToSkipFormatSet(String fmt)
           
static void addValues(String s, Collection<String> values)
          Only public for testing purposes.
static OortConfiguration createOortConfig(Properties properties)
          Create an OortConfiguration from the given Properties.
static Properties createProperties(OortConfiguration config)
          Create a Properties object for the given configuration.
static CharSequence escape(String s, char escapeChar)
          Only public for testing purposes.
 File getBase()
           
 List<String> getBridgeOntologies()
           
 String getCatalogXML()
           
 org.semanticweb.owlapi.model.OWLOntologyFormat getDefaultFormat()
           
 OortConfiguration.MacroStrategy getMacroStrategy()
           
 org.semanticweb.owlapi.model.OWLOntologyFormat getOwlOfnFormat()
           
 org.semanticweb.owlapi.model.OWLOntologyFormat getOwlXMLFormat()
           
 Vector<String> getPaths()
           
 Set<PropertyView> getPropertyViews()
           
 String getQueryOntology()
           
 String getQueryOntologyReference()
           
 String getReasonerName()
           
 Set<String> getSkipFormatSet()
           
 Set<String> getSourceOntologyPrefixes()
           
 boolean isAddSupportFromImports()
           
 boolean isAllowEquivalentNamedClassPairs()
           
 boolean isAllowFileOverWrite()
           
 boolean isAsserted()
           
 boolean isAutoDetectBridgingOntology()
           
 boolean isCheckConsistency()
           
 boolean isEnforceEL()
           
 boolean isExecuteOntologyChecks()
           
 boolean isExpandMacros()
           
 boolean isExpandShortcutRelations()
           
 boolean isExpandXrefs()
           
 boolean isForceRelease()
           
 boolean isGafToOwl()
           
 boolean isJustifyAssertedSubclasses()
           
 boolean isQueryOntologyReferenceIsIRI()
           
 boolean isRecreateMireot()
           
 boolean isRemoveDanglingBeforeReasoning()
           
 boolean isRemoveQueryOntologyReference()
           
 boolean isRepairAnnotationCardinality()
           
 boolean isSimple()
           
 boolean isSkipFormat(String fmt)
           
 boolean isUseQueryOntology()
           
 boolean isUseReleaseFolder()
           
 boolean isWriteELOntology()
           
 boolean isWriteLabelOWL()
           
 boolean isWriteMetadata()
           
 boolean isWriteSubsets()
           
static void loadConfig(File file, OortConfiguration config)
          Load the configuration from a property file into the given OortConfiguration.
static void loadOortConfig(Properties properties, OortConfiguration config)
          Load the given Properties into the OortConfiguration.
static OortConfiguration readConfig(File file)
          Read from a configuration property file and load it into a new OortConfiguration object.
 void removeFromSkipFormatSet(String fmt)
           
 void setAddSupportFromImports(boolean addSupportFromImports)
           
 void setAllowEquivalentNamedClassPairs(boolean allowEquivalentNamedClassPairs)
           
 void setAllowFileOverWrite(boolean allowFileOverWrite)
          Set allowFileOverWrite
 void setAsserted(boolean asserted)
          Set asserted
 void setAutoDetectBridgingOntology(boolean isAutoDetectBridgingOntology)
           
 void setBase(File base)
           
 void setBridgeOntologies(List<String> bridgeOntologies)
           
 void setCatalogXML(String catalogXML)
           
 void setCheckConsistency(boolean checkConsistency)
           
 void setEnforceEL(boolean enforceEL)
           
 void setExecuteOntologyChecks(boolean executeOntologyChecks)
           
 void setExpandMacros(boolean expandMacros)
           
 void setExpandShortcutRelations(boolean expandShortcutRelations)
           
 void setExpandXrefs(boolean expandXrefs)
          Set export bridges
 void setForceRelease(boolean forceRelease)
           
 void setGafToOwl(boolean gafToOwl)
           
 void setJustifyAssertedSubclasses(boolean isJustifyAssertedSubclasses)
           
 void setMacroStrategy(OortConfiguration.MacroStrategy macroStrategy)
          Set the OortConfiguration.MacroStrategy
 void setPropertyViews(Set<PropertyView> propertyViews)
           
 void setQueryOntology(String queryOntology)
           
 void setQueryOntologyReference(String queryOntologyReference)
           
 void setQueryOntologyReferenceIsIRI(boolean queryOntologyReferenceIsIRI)
           
 void setReasonerName(String reasonerName)
          Set the reasoner name
 void setRecreateMireot(boolean recreateMireot)
          Set recreateMireot
 void setRemoveDanglingBeforeReasoning(boolean removeDanglingBeforeReasoning)
           
 void setRemoveQueryOntologyReference(boolean removeQueryOntologyReference)
           
 void setRepairAnnotationCardinality(boolean repairAnnotationCardinality)
           
 void setSimple(boolean simple)
          Set simple.
 void setSkipFormatSet(Set<String> skipFormatSet)
           
 void setSourceOntologyPrefixes(Set<String> sourceOntologyPrefixes)
           
 void setUseQueryOntology(boolean useQueryOntology)
           
 void setUseReleaseFolder(boolean useReleaseFolder)
           
 void setWriteELOntology(boolean writeELOntology)
           
 void setWriteLabelOWL(boolean writeLabelOWL)
           
 void setWriteMetadata(boolean writeMetadata)
           
 void setWriteSubsets(boolean isWriteSubsets)
           
 String toString()
           
static String unescape(String s)
          Only public for testing purposes.
static void writeConfig(File file, OortConfiguration config)
          Write the given OortConfiguration into the file as properties.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

OortConfiguration

public OortConfiguration()
Method Detail

getReasonerName

public String getReasonerName()
Returns:
the reasoner name

setReasonerName

public void setReasonerName(String reasonerName)
Set the reasoner name

Parameters:
reasonerName -

isAsserted

public boolean isAsserted()
Returns:
is asserted

setAsserted

public void setAsserted(boolean asserted)
Set asserted

Parameters:
asserted -

isSimple

public boolean isSimple()
Returns:
is simple

setSimple

public void setSimple(boolean simple)
Set simple.

Parameters:
simple -

isExpandXrefs

public boolean isExpandXrefs()
Returns:
is expand Xrefs

setExpandXrefs

public void setExpandXrefs(boolean expandXrefs)
Set export bridges

Parameters:
expandXrefs -

isAllowFileOverWrite

public boolean isAllowFileOverWrite()
Returns:
is AllowFileOverWrite

setAllowFileOverWrite

public void setAllowFileOverWrite(boolean allowFileOverWrite)
Set allowFileOverWrite

Parameters:
allowFileOverWrite -

getMacroStrategy

public OortConfiguration.MacroStrategy getMacroStrategy()
Returns:
OortConfiguration.MacroStrategy

setMacroStrategy

public void setMacroStrategy(OortConfiguration.MacroStrategy macroStrategy)
Set the OortConfiguration.MacroStrategy

Parameters:
macroStrategy -

isRecreateMireot

public boolean isRecreateMireot()
Returns:
is recreateMireot

setRecreateMireot

public void setRecreateMireot(boolean recreateMireot)
Set recreateMireot

Parameters:
recreateMireot -

isExpandShortcutRelations

public boolean isExpandShortcutRelations()
Returns:
is ExpandShortcutRelations

setExpandShortcutRelations

public void setExpandShortcutRelations(boolean expandShortcutRelations)

isEnforceEL

public boolean isEnforceEL()

setEnforceEL

public void setEnforceEL(boolean enforceEL)

isWriteELOntology

public boolean isWriteELOntology()

setWriteELOntology

public void setWriteELOntology(boolean writeELOntology)

getSkipFormatSet

public Set<String> getSkipFormatSet()

setSkipFormatSet

public void setSkipFormatSet(Set<String> skipFormatSet)

addToSkipFormatSet

public void addToSkipFormatSet(String fmt)

removeFromSkipFormatSet

public void removeFromSkipFormatSet(String fmt)

isSkipFormat

public boolean isSkipFormat(String fmt)

getSourceOntologyPrefixes

public Set<String> getSourceOntologyPrefixes()

setSourceOntologyPrefixes

public void setSourceOntologyPrefixes(Set<String> sourceOntologyPrefixes)

addSourceOntologyPrefix

public void addSourceOntologyPrefix(String prefix)

getBridgeOntologies

public List<String> getBridgeOntologies()
Returns:
the bridgeOntologies

setBridgeOntologies

public void setBridgeOntologies(List<String> bridgeOntologies)
Parameters:
bridgeOntologies - the bridgeOntologies to set

addBridgeOntology

public void addBridgeOntology(String bridgeOntology)

isExecuteOntologyChecks

public boolean isExecuteOntologyChecks()

setExecuteOntologyChecks

public void setExecuteOntologyChecks(boolean executeOntologyChecks)

isAllowEquivalentNamedClassPairs

public boolean isAllowEquivalentNamedClassPairs()

setAllowEquivalentNamedClassPairs

public void setAllowEquivalentNamedClassPairs(boolean allowEquivalentNamedClassPairs)

isWriteSubsets

public boolean isWriteSubsets()

setWriteSubsets

public void setWriteSubsets(boolean isWriteSubsets)

isJustifyAssertedSubclasses

public boolean isJustifyAssertedSubclasses()

setJustifyAssertedSubclasses

public void setJustifyAssertedSubclasses(boolean isJustifyAssertedSubclasses)

isAutoDetectBridgingOntology

public boolean isAutoDetectBridgingOntology()

setAutoDetectBridgingOntology

public void setAutoDetectBridgingOntology(boolean isAutoDetectBridgingOntology)

isExpandMacros

public boolean isExpandMacros()
Returns:
isExpandMacros

setExpandMacros

public void setExpandMacros(boolean expandMacros)
Parameters:
expandMacros - isExpandMacros to set

isForceRelease

public boolean isForceRelease()
Returns:
the isForceRelease

setForceRelease

public void setForceRelease(boolean forceRelease)
Parameters:
forceRelease - forceRelease to set

isCheckConsistency

public boolean isCheckConsistency()
Returns:
isCheckConsistency

setCheckConsistency

public void setCheckConsistency(boolean checkConsistency)
Parameters:
checkConsistency - the checkConsistency to set

isRemoveDanglingBeforeReasoning

public boolean isRemoveDanglingBeforeReasoning()

setRemoveDanglingBeforeReasoning

public void setRemoveDanglingBeforeReasoning(boolean removeDanglingBeforeReasoning)

isAddSupportFromImports

public boolean isAddSupportFromImports()

setAddSupportFromImports

public void setAddSupportFromImports(boolean addSupportFromImports)

isWriteMetadata

public boolean isWriteMetadata()
Returns:
isWriteMetadata

setWriteMetadata

public void setWriteMetadata(boolean writeMetadata)
Parameters:
writeMetadata - the writeMetadata to set

getDefaultFormat

public org.semanticweb.owlapi.model.OWLOntologyFormat getDefaultFormat()
Returns:
the defaultFormat

getOwlXMLFormat

public org.semanticweb.owlapi.model.OWLOntologyFormat getOwlXMLFormat()
Returns:
the owlXMLFormat

getPaths

public Vector<String> getPaths()
Returns:
the paths

addPath

public void addPath(String path)
Parameters:
path - the path to add to the set

getBase

public File getBase()
Returns:
the base

setBase

public void setBase(File base)
Parameters:
base - the base to set

isRepairAnnotationCardinality

public boolean isRepairAnnotationCardinality()
Returns:
the repairAnnotationCardinality

setRepairAnnotationCardinality

public void setRepairAnnotationCardinality(boolean repairAnnotationCardinality)
Parameters:
repairAnnotationCardinality - the repairAnnotationCardinality to set

getPropertyViews

public Set<PropertyView> getPropertyViews()

setPropertyViews

public void setPropertyViews(Set<PropertyView> propertyViews)

isUseReleaseFolder

public boolean isUseReleaseFolder()
Returns:
the useReleaseFolder

setUseReleaseFolder

public void setUseReleaseFolder(boolean useReleaseFolder)
Parameters:
useReleaseFolder - the useReleaseFolder to set

isGafToOwl

public boolean isGafToOwl()
Returns:
the gafToOwl

setGafToOwl

public void setGafToOwl(boolean gafToOwl)
Parameters:
gafToOwl - the gafToOwl to set

getCatalogXML

public String getCatalogXML()
Returns:
the catalogXML

setCatalogXML

public void setCatalogXML(String catalogXML)
Parameters:
catalogXML - the catalogXML to set

isUseQueryOntology

public boolean isUseQueryOntology()
Returns:
the useQueryOntology

setUseQueryOntology

public void setUseQueryOntology(boolean useQueryOntology)
Parameters:
useQueryOntology - the useQueryOntology to set

getQueryOntology

public String getQueryOntology()
Returns:
the queryOntology

setQueryOntology

public void setQueryOntology(String queryOntology)
Parameters:
queryOntology - the queryOntology to set

getQueryOntologyReference

public String getQueryOntologyReference()
Returns:
the queryOntologyReference

setQueryOntologyReference

public void setQueryOntologyReference(String queryOntologyReference)
Parameters:
queryOntologyReference - the queryOntologyReference to set

isQueryOntologyReferenceIsIRI

public boolean isQueryOntologyReferenceIsIRI()
Returns:
the queryOntologyReferenceIsIRI

setQueryOntologyReferenceIsIRI

public void setQueryOntologyReferenceIsIRI(boolean queryOntologyReferenceIsIRI)
Parameters:
queryOntologyReferenceIsIRI - the queryOntologyReferenceIsIRI to set

isRemoveQueryOntologyReference

public boolean isRemoveQueryOntologyReference()
Returns:
the removeQueryOntologyReference

isWriteLabelOWL

public boolean isWriteLabelOWL()
Returns:
the writeLabelOWL

setWriteLabelOWL

public void setWriteLabelOWL(boolean writeLabelOWL)
Parameters:
writeLabelOWL - the writeLabelOWL to set

getOwlOfnFormat

public org.semanticweb.owlapi.model.OWLOntologyFormat getOwlOfnFormat()
Returns:
the owlOFNFormat

setRemoveQueryOntologyReference

public void setRemoveQueryOntologyReference(boolean removeQueryOntologyReference)
Parameters:
removeQueryOntologyReference - the removeQueryOntologyReference to set

toString

public String toString()
Overrides:
toString in class Object

createProperties

public static Properties createProperties(OortConfiguration config)
Create a Properties object for the given configuration.

Parameters:
config -
Returns:
properties

createOortConfig

public static OortConfiguration createOortConfig(Properties properties)
Create an OortConfiguration from the given Properties.

Parameters:
properties -
Returns:
configuration

loadOortConfig

public static void loadOortConfig(Properties properties,
                                  OortConfiguration config)
Load the given Properties into the OortConfiguration.

Parameters:
properties -
config -

addValues

public static void addValues(String s,
                             Collection<String> values)
Only public for testing purposes.

Parameters:
s -
values -

escape

public static CharSequence escape(String s,
                                  char escapeChar)
Only public for testing purposes.

Parameters:
s -
escapeChar -
Returns:
escaped string

unescape

public static String unescape(String s)
Only public for testing purposes.

Parameters:
s -
Returns:
un-escaped string

readConfig

public static OortConfiguration readConfig(File file)
                                    throws IOException
Read from a configuration property file and load it into a new OortConfiguration object.

Parameters:
file -
Returns:
configuration
Throws:
IOException

loadConfig

public static void loadConfig(File file,
                              OortConfiguration config)
                       throws IOException
Load the configuration from a property file into the given OortConfiguration.

Parameters:
file - source property file
config - target configuration
Throws:
IOException

writeConfig

public static void writeConfig(File file,
                               OortConfiguration config)
                        throws IOException
Write the given OortConfiguration into the file as properties.

Parameters:
file - target file
config -
Throws:
IOException


Copyright © 2010-2012. All Rights Reserved.