Git Product home page Git Product logo

gov.nasa.jpl.omf.scala.binding.owlapi's Introduction

OWL API binding for OMF (Ontological Modeling Framework)

Build Status Download

Copyrights

Caltech

License

Apache-2.0

Description

The OWL API binding for OMF implements the OMF Core functional API using the OWL API. This particular binding captures the conventions and restrictions on the use of OWL2-DL adopted for the development of JPL's Integrated Model-Centric Engineering (IMCE) ontologies. OWL2-DL ontologies that conform to these conventions and restrictions enjoy several useful properties, including:

  • standard syntax for creating, editing, saving ontologies with tools that conform to the W3C's OWL Functional Syntax and RDF/XML Mapping specifications

  • standard semantics for reasoning ontologies with tools that conform to the W3C's OWL Functional Syntax for OWL-DL ontologies and the direct and RDF-based mapping semantics specifications

Dependencies

  • This project depends on JPL's IMCE ontologies for MBSE, which should be publicly available soon.
  • See build.sbt

Building the OWL API Scala binding for OMF Scala

Updating license header

sbt formatLicenseHeaders

Building with SBT

sbt owlapiLibs/pack
sbt publishLocal

Building with Eclipse

The Eclipse .classpath file refers to the OMF Scala Core project as "gov.nasa.omf.scala.core". Make sure that this project is imported in the Eclipse workspace.

Build the Scala project as usual with Eclipse

Unit Tests

Running unit tests from SBT:

sbt test

Running unit tests from the Scala IDE in Eclipse:

In the Scala perspective, use the Run or Debug menus to launch the configurations included in the launchers/ folder.

logging

Set system properties:

  • gov.nasa.jpl.omf.scala.binding.owlapi.log.GraphStore
  • gov.nasa.jpl.omf.scala.binding.owlapi.log.ResolverHelper1
  • gov.nasa.jpl.omf.scala.binding.owlapi.log.ResolverHelper2
  • gov.nasa.jpl.omf.scala.binding.owlapi.log.ImmutableModelTerminologyGraphResolver1
  • gov.nasa.jpl.omf.scala.binding.owlapi.log.ImmutableModelTerminologyGraphResolver2
  • gov.nasa.jpl.omf.scala.binding.owlapi.log.MutableModelTerminologyGraph

gov.nasa.jpl.omf.scala.binding.owlapi's People

Contributors

nicolasrouquette avatar

Stargazers

 avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

gov.nasa.jpl.omf.scala.binding.owlapi's Issues

Improve handling of annotation properties

The OWL API does not reliably produce abbreviated IRIs; especially for dc, rdf and rdfs.
For other ontologies, if the OWLAPI doesn't provide a proper abbreviated IRI, construct one from the last segment of the IRI and of the IRI fragment.

OWL representation of SWRL rules is incorrect.

OML => OWL results in incorrect representation of reified relationships.

	reifiedRelationship Supplies {
		inverseFunctional
		asymmetric
		irreflexive
		unreified = supplies
		inverse = isSuppliedBy
		source = Authority
		target = SuppliedElement }

produced:


    <rdf:Description>
        <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#Imp"/>
        <swrl:body>
            <rdf:Description>
                <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#AtomList"/>
                <rdf:first>
                    <rdf:Description>
                        <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#IndividualPropertyAtom"/>
                        <swrl:propertyPredicate rdf:resource="http://imce.jpl.nasa.gov/foundation/project/project#hasSuppliesSource"/>
                        <swrl:argument1 rdf:resource="urn:swrl#r"/>
                        <swrl:argument2 rdf:resource="urn:swrl#s"/>
                    </rdf:Description>
                </rdf:first>
                <rdf:rest>
                    <rdf:Description>
                        <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#AtomList"/>
                        <rdf:first>
                            <rdf:Description>
                                <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#IndividualPropertyAtom"/>
                                <swrl:propertyPredicate rdf:resource="http://imce.jpl.nasa.gov/foundation/project/project#hasSuppliesTarget"/>
                                <swrl:argument1 rdf:resource="urn:swrl#r"/>
                                <swrl:argument2 rdf:resource="urn:swrl#t"/>
                            </rdf:Description>
                        </rdf:first>
                        <rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
                    </rdf:Description>
                </rdf:rest>
            </rdf:Description>
        </swrl:body>
        <swrl:head>
            <rdf:Description>
                <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#AtomList"/>
                <rdf:first>
                    <rdf:Description>
                        <rdf:type rdf:resource="http://www.w3.org/2003/11/swrl#IndividualPropertyAtom"/>
                        <swrl:propertyPredicate rdf:resource="http://imce.jpl.nasa.gov/foundation/project/project#Supplies"/>
                        <swrl:argument1 rdf:resource="urn:swrl#s"/>
                        <swrl:argument2 rdf:resource="urn:swrl#t"/>
                    </rdf:Description>
                </rdf:first>
                <rdf:rest rdf:resource="http://www.w3.org/1999/02/22-rdf-syntax-ns#nil"/>
            </rdf:Description>
        </swrl:head>
    </rdf:Description>

The swrl:head should refer to project#supplies instead of project#Supplies

When parsing SWRL rules, need to reorder the body atoms for OML

In SWRL, a rule may be written like this:

behavior:InteractionBehaviorRegion(?R) ^ 
behavior:InteractionBehaviorAutomaton(?A) ^ 
behavior:hasRegion(?A, ?R) ^
behavior:Interaction(?I) ^ 
behavior:hasInteractionBehaviorClass(?I, ?A) -> 
behavior:hasInteractionBehavior(?I, ?R)

In OML, the corresponding OML ChainRule must be written with the body atoms ordered like this:

behavior:Interaction(?I) ^ 
behavior:hasInteractionBehaviorClass(?I, ?A) ^ 
behavior:InteractionBehaviorAutomaton(?A) ^ 
behavior:hasRegion(?A, ?R) ^ 
behavior:InteractionBehaviorRegion(?R) -> 
behavior:hasInteractionBehavior(?I, ?R)

Some OWL Axioms are lost

There is a subtle problem with the interaction between Scala & Java8 Streams used in the OWLAPI.

def resolveConceptSubClassAxioms
  (conceptCMs: Map[OWLClass, Concept],
   allConceptsIncludingImported: Map[OWLClass, Concept])
  (implicit reasoner: OWLReasoner, backbone: OMFBackbone)
  : Set[java.lang.Throwable] \/ Unit
  = {

    val sub_sup = for {
      (subC, subM) <- conceptCMs
      supC <- reasoner.getSuperClasses(subC, true).entities().toScala[Set]
      supM <- findEntityConcept(supC.getIRI, allConceptsIncludingImported)
    } yield (subM, supM)

    ( ().right[Set[java.lang.Throwable]] /: sub_sup ) { ... }
}

The problem is in this line: supC <- reasoner.getSuperClasses(subC, true).entities().toScala[Set]

reasoner.getSuperClasses(subC, true) produces an OWLAPI NodeSet
reasoner.getSuperClasses(subC, true).entities() produces a Java8 Stream of OWLAPI Entities.
reasoner.getSuperClasses(subC, true).entities().toScala[Set] converts that Java8 Stream to a Scala Set collection.
supC <- reasoner.getSuperClasses(subC, true).entities().toScala[Set] should iterate over all elements in the converted Scala Set collection.

Unfortunately, only the first element of the stream is iterated over.

The following iterates properly over all elements in the stream:

val sub_sup = for {
      (subC, subM) <- conceptCMs
      supE = reasoner.getSuperClasses(subC, true).entities()
      supS = supE.toScala[Set]
      supC <- supS
      supM <- findEntityConcept(supC.getIRI, allConceptsIncludingImported)
    } yield (subM, supM)

Check OWL ontology manager before loading an ontology document

When loading an ontology document (e.g., via a file), the OWL OntologyManager may throw OWLOntologyAlreadyExistsException. This behavior should be avoided; that is, check whether there exists an ontology for a given ontology document before trying to load that document. This way, normal processing should not trigger any OWLOntologyAlreadyExistsException errors.

Improve the OWLAPI parser to handle alternative SWRL formulations

JPL-IMCE/gov.nasa.jpl.imce.ontologies.public#37

For example either of the SWRL rules below should be acceptable:

fault-management:PerformanceConstraint(?P) ^ 
fault-management:ViolationExplanation(?V) ^ 
behavior:ElementBehavior(?B) ^ 
analysis:analyzes(?V, ?P) ^ 
analysis:explains(?V, ?B) -> 
fault-management:violates(?B, ?P)
behavior:ElementBehavior(?B) ^ 
analysis:isExplainedBy(?B, ?V)  ^ 
fault-management:ViolationExplanation(?V) ^ 
analysis:analyzes(?V, ?P) ^ 
fault-management:PerformanceConstraint(?P)-> 
fault-management:violates(?B, ?P)

Either one should result in OML in the following rule:

behavior:ElementBehavior ^ 
analysis:isExplainedBy  ^ 
fault-management:ViolationExplanation ^ 
analysis:analyzes ^ 
fault-management:PerformanceConstraint-> 
fault-management:violates

Turn off `scalax.collection.connectivity.GraphComponents` logger.

This fails CI builds, eg.: https://travis-ci.org/JPL-IMCE/gov.nasa.jpl.omf.scala.binding.owlapi/builds/240473772#L5031

[info] - when load xsd *** FAILED ***
[info]   java.util.IllegalFormatConversionException: c != org.semanticweb.owlapi.model.IRI
[info]   at java.util.Formatter$FormatSpecifier.failConversion(Formatter.java:4302)
[info]   at java.util.Formatter$FormatSpecifier.printCharacter(Formatter.java:2869)
[info]   at java.util.Formatter$FormatSpecifier.print(Formatter.java:2757)
[info]   at java.util.Formatter.format(Formatter.java:2520)
[info]   at java.util.Formatter.format(Formatter.java:2455)
[info]   at java.lang.String.format(String.java:2927)
[info]   at scala.collection.immutable.StringLike$class.format(StringLike.scala:318)
[info]   at scalax.collection.connectivity.GraphComponents$$anonfun$scalax$collection$connectivity$GraphComponents$$visit$1$1.apply(GraphComponents.scala:120)

This is a workaround to this issue: scala-graph/scala-graph#75

Speed up processing large models with hashCode & equals

Exploit the immutable character of many OMF/OWLAPI objects to speed up hashCode operations:

	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ModelScalarDataType.hashCode(ModelScalarDataType.scala:26)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ScalarDataTypeFacetRestrictionAxiom.hashCode(ScalarDataTypeFacetRestrictionAxiom.scala:28)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:110)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:109)
	at scala.collection.Iterator$class.foreach(Iterator.scala:893)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
	at scala.util.hashing.MurmurHash3.orderedHash(MurmurHash3.scala:109)
	at scala.util.hashing.MurmurHash3$.seqHash(MurmurHash3.scala:219)
	at scala.collection.IndexedSeqLike$class.hashCode(IndexedSeqLike.scala:44)
	at scala.collection.immutable.Vector.hashCode(Vector.scala:62)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.TerminologyGraphDirectExtensionAxiom.hashCode(TerminologyGraphDirectExtensionAxiom.scala:25)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:110)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:109)
	at scala.collection.Iterator$class.foreach(Iterator.scala:893)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
	at scala.util.hashing.MurmurHash3.orderedHash(MurmurHash3.scala:109)
	at scala.util.hashing.MurmurHash3$.seqHash(MurmurHash3.scala:219)
	at scala.collection.IndexedSeqLike$class.hashCode(IndexedSeqLike.scala:44)
	at scala.collection.immutable.Vector.hashCode(Vector.scala:62)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.TerminologyGraphDirectExtensionAxiom.hashCode(TerminologyGraphDirectExtensionAxiom.scala:25)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:110)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:109)
	at scala.collection.Iterator$class.foreach(Iterator.scala:893)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
	at scala.util.hashing.MurmurHash3.orderedHash(MurmurHash3.scala:109)
	at scala.util.hashing.MurmurHash3$.seqHash(MurmurHash3.scala:219)
	at scala.collection.IndexedSeqLike$class.hashCode(IndexedSeqLike.scala:44)
	at scala.collection.immutable.Vector.hashCode(Vector.scala:62)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.TerminologyGraphDirectExtensionAxiom.hashCode(TerminologyGraphDirectExtensionAxiom.scala:25)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:110)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:109)
	at scala.collection.Iterator$class.foreach(Iterator.scala:893)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
	at scala.util.hashing.MurmurHash3.orderedHash(MurmurHash3.scala:109)
	at scala.util.hashing.MurmurHash3$.seqHash(MurmurHash3.scala:219)
	at scala.collection.IndexedSeqLike$class.hashCode(IndexedSeqLike.scala:44)
	at scala.collection.immutable.Vector.hashCode(Vector.scala:62)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.TerminologyGraphDirectExtensionAxiom.hashCode(TerminologyGraphDirectExtensionAxiom.scala:25)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:110)
	at scala.util.hashing.MurmurHash3$$anonfun$orderedHash$1.apply(MurmurHash3.scala:109)
	at scala.collection.Iterator$class.foreach(Iterator.scala:893)
	at scala.collection.AbstractIterator.foreach(Iterator.scala:1336)
	at scala.collection.IterableLike$class.foreach(IterableLike.scala:72)
	at scala.collection.AbstractIterable.foreach(Iterable.scala:54)
	at scala.util.hashing.MurmurHash3.orderedHash(MurmurHash3.scala:109)
	at scala.util.hashing.MurmurHash3$.seqHash(MurmurHash3.scala:219)
	at scala.collection.IndexedSeqLike$class.hashCode(IndexedSeqLike.scala:44)
	at scala.collection.immutable.Vector.hashCode(Vector.scala:62)
	at scala.runtime.ScalaRunTime$.hash(ScalaRunTime.scala:206)
	at scala.util.hashing.MurmurHash3.productHash(MurmurHash3.scala:64)
	at scala.util.hashing.MurmurHash3$.productHash(MurmurHash3.scala:211)
	at scala.runtime.ScalaRunTime$._hashCode(ScalaRunTime.scala:168)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
	at scala.collection.mutable.FlatHashTable$class.addEntry(FlatHashTable.scala:148)
	at scala.collection.mutable.HashSet.addEntry(HashSet.scala:40)
	at scala.collection.mutable.FlatHashTable$class.growTable(FlatHashTable.scala:225)
	at scala.collection.mutable.FlatHashTable$class.addEntry(FlatHashTable.scala:159)
	at scala.collection.mutable.HashSet.addEntry(HashSet.scala:40)
	at scala.collection.mutable.FlatHashTable$class.addElem(FlatHashTable.scala:139)
	at scala.collection.mutable.HashSet.addElem(HashSet.scala:40)
	at scala.collection.mutable.HashSet.$plus$eq(HashSet.scala:59)
	at scala.collection.mutable.HashSet.$plus$eq(HashSet.scala:40)
	at gov.nasa.jpl.omf.scala.core.OMFOps$$anonfun$closure$1.apply(OMFOps.scala:64)
	at scala.collection.immutable.HashSet$HashSet1.foreach(HashSet.scala:316)
	at scala.collection.immutable.HashSet$HashTrieSet.foreach(HashSet.scala:972)
	at gov.nasa.jpl.omf.scala.core.OMFOps$.closure(OMFOps.scala:63)
	at gov.nasa.jpl.omf.scala.core.package$.terminologyGraphImportClosure(package.scala:123)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ModelTerminologyGraph.isTypeTermDefinedRecursively(ModelTerminologyGraph.scala:93)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.MutableModelTerminologyGraph.addEntityConceptSubClassAxiom(MutableModelTerminologyGraph.scala:1345)
	at gov.nasa.jpl.omf.scala.binding.owlapi.OWLAPIMutableTerminologyGraphOps$class.addEntityConceptSubClassAxiom(OWLAPIOMFOps.scala:1011)
	at gov.nasa.jpl.omf.scala.binding.owlapi.OWLAPIOMFOps.addEntityConceptSubClassAxiom(OWLAPIOMFOps.scala:1257)
	at gov.nasa.jpl.omf.scala.binding.owlapi.OWLAPIOMFOps.addEntityConceptSubClassAxiom(OWLAPIOMFOps.scala:1257)
	at gov.nasa.jpl.omf.scala.core.MutableTerminologyGraphOps$$anonfun$addEntityConceptSubClassAxiom$2.apply(OMFOps.scala:1542)
	at gov.nasa.jpl.omf.scala.core.MutableTerminologyGraphOps$$anonfun$addEntityConceptSubClassAxiom$2.apply(OMFOps.scala:1538)
	at scalaz.$bslash$div.flatMap(Either.scala:135)
	at gov.nasa.jpl.omf.scala.core.MutableTerminologyGraphOps$class.addEntityConceptSubClassAxiom(OMFOps.scala:1538)
	at gov.nasa.jpl.omf.scala.binding.owlapi.OWLAPIOMFOps.addEntityConceptSubClassAxiom(OWLAPIOMFOps.scala:1257)

In this stack trace, there are 4 customizable hashCode methods that have been invoked:


	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ModelScalarDataType.hashCode(ModelScalarDataType.scala:26)
	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ScalarDataTypeFacetRestrictionAxiom.hashCode(ScalarDataTypeFacetRestrictionAxiom.scala:28)
4x	at gov.nasa.jpl.omf.scala.binding.owlapi.types.ImmutableModelTerminologyGraph.hashCode(ImmutableModelTerminologyGraph.scala:63)
4x	at gov.nasa.jpl.omf.scala.binding.owlapi.types.TerminologyGraphDirectExtensionAxiom.hashCode(TerminologyGraphDirectExtensionAxiom.scala:25)

All of these case classes represent immutable objects; which means that it is possible to exploit the optimization trick in Programming in Scala, 3rd Ed, chapter 30, Recipe for hashCode, which defines it as a val computed once at object creation instead of as def method.

Handle circular imports among ontologies.

Conversions from OWL => OML are currently not possible if the OWL ontologies have circular imports. This happens for RDF & RDFS that import each other but could also happen for other ontologies since circular references are allowed in OML.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.