Class AtomicRole

  • All Implemented Interfaces:
    net.sf.tweety.commons.Formula, net.sf.tweety.logics.commons.syntax.interfaces.ClassicalFormula, net.sf.tweety.logics.commons.syntax.interfaces.Conjunctable, net.sf.tweety.logics.commons.syntax.interfaces.Disjunctable, net.sf.tweety.logics.commons.syntax.interfaces.Invertable, net.sf.tweety.logics.commons.syntax.interfaces.ProbabilityAware, net.sf.tweety.logics.commons.syntax.interfaces.SimpleLogicalFormula

    public class AtomicRole
    extends ComplexConcept
    This class models a role in description logics.
    Note: Role assertions like (a,b):r ("the Individuals a,b are in the extension of the role r") are modeled with a different class: ConceptAssertion.
    Author:
    Anna Gessler
    • Constructor Detail

      • AtomicRole

        public AtomicRole​(String name)
        Initializes a role with the given name.
        Parameters:
        name - the name of the role
      • AtomicRole

        public AtomicRole​(net.sf.tweety.logics.commons.syntax.Predicate p)
    • Method Detail

      • getPredicate

        public net.sf.tweety.logics.commons.syntax.Predicate getPredicate()
      • getName

        public String getName()
      • getPredicates

        public Set<net.sf.tweety.logics.commons.syntax.Predicate> getPredicates()
        Specified by:
        getPredicates in interface net.sf.tweety.logics.commons.syntax.interfaces.SimpleLogicalFormula
        Specified by:
        getPredicates in class ComplexConcept
      • clone

        public ComplexConcept clone()
        Description copied from class: ComplexConcept
        Creates a deep copy of this formula
        Specified by:
        clone in interface net.sf.tweety.logics.commons.syntax.interfaces.SimpleLogicalFormula
        Specified by:
        clone in class ComplexConcept
      • collapseAssociativeFormulas

        public AtomicRole collapseAssociativeFormulas()
        Description copied from class: ComplexConcept
        This method collapses all associative operations appearing in this term, e.g. every a||(b||c) becomes a||b||c.
        Specified by:
        collapseAssociativeFormulas in class ComplexConcept
        Returns:
        the collapsed formula.
      • isLiteral

        public boolean isLiteral()
      • hashCode

        public int hashCode()
        Specified by:
        hashCode in interface net.sf.tweety.logics.commons.syntax.interfaces.SimpleLogicalFormula
        Specified by:
        hashCode in class ComplexConcept
      • equals

        public boolean equals​(Object obj)
        Specified by:
        equals in interface net.sf.tweety.logics.commons.syntax.interfaces.SimpleLogicalFormula
        Specified by:
        equals in class ComplexConcept