Package org.semanticweb.owlapi.util
Class OWLEntityComparator
java.lang.Object
org.semanticweb.owlapi.util.OWLEntityComparator
- All Implemented Interfaces:
Comparator<OWLEntity>
,OWLClassVisitorBase
,OWLDataEntityVisitorBase
,OWLEntityVisitor
,OWLIndividualEntityVisitorBase
,OWLPropertyEntityVisitorBase
,OWLVisitorBase
A
Comparator
which compares entities. Entities are compared first by
their type (in the following order: Class, Object property, Data property,
Individual, Datatype) then by their short form (using the specified short
form provider).- Since:
- 2.0.0
- Author:
- Matthew Horridge, The University Of Manchester, Bio-Health Informatics Group
-
Constructor Summary
ConstructorsConstructorDescriptionOWLEntityComparator
(ShortFormProvider shortFormProvider) Constructs an entity comparator which uses the specified short form provider. -
Method Summary
Modifier and TypeMethodDescriptionint
void
visit
(OWLAnnotationProperty property) visit OWLAnnotationProperty typevoid
visit OWLClass typevoid
visit
(OWLDataProperty property) visit OWLDataProperty typevoid
visit
(OWLDatatype datatype) visit OWLDatatype typevoid
visit
(OWLNamedIndividual individual) visit OWLNamedIndividual typevoid
visit
(OWLObjectProperty property) visit OWLObjectProperty typeMethods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface java.util.Comparator
equals, reversed, thenComparing, thenComparing, thenComparing, thenComparingDouble, thenComparingInt, thenComparingLong
Methods inherited from interface org.semanticweb.owlapi.model.OWLVisitorBase
doDefault, getDefaultReturnValue, handleDefault
-
Constructor Details
-
OWLEntityComparator
Constructs an entity comparator which uses the specified short form provider.- Parameters:
shortFormProvider
- the short form provider to use
-
-
Method Details
-
compare
- Specified by:
compare
in interfaceComparator<OWLEntity>
-
visit
Description copied from interface:OWLClassVisitorBase
visit OWLClass type- Specified by:
visit
in interfaceOWLClassVisitorBase
- Parameters:
cls
- ce to visit
-
visit
Description copied from interface:OWLPropertyEntityVisitorBase
visit OWLObjectProperty type- Specified by:
visit
in interfaceOWLPropertyEntityVisitorBase
- Parameters:
property
- property to visit
-
visit
Description copied from interface:OWLPropertyEntityVisitorBase
visit OWLDataProperty type- Specified by:
visit
in interfaceOWLPropertyEntityVisitorBase
- Parameters:
property
- property to visit
-
visit
Description copied from interface:OWLIndividualEntityVisitorBase
visit OWLNamedIndividual type- Specified by:
visit
in interfaceOWLIndividualEntityVisitorBase
- Parameters:
individual
- individual to visit
-
visit
Description copied from interface:OWLPropertyEntityVisitorBase
visit OWLAnnotationProperty type- Specified by:
visit
in interfaceOWLPropertyEntityVisitorBase
- Parameters:
property
- property to visit
-
visit
Description copied from interface:OWLDataEntityVisitorBase
visit OWLDatatype type- Specified by:
visit
in interfaceOWLDataEntityVisitorBase
- Parameters:
datatype
- node to visit
-