edu.udo.cs.ie.cowbots.logic
Class NegLiteral

Package class diagram package NegLiteral
java.lang.Object
  extended by edu.udo.cs.ie.cowbots.logic.NegLiteral
All Implemented Interfaces:
ELPLiteral
Direct Known Subclasses:
DLPNegLiteral

public class NegLiteral
extends java.lang.Object
implements ELPLiteral

class for strict negated literals


Field Summary
protected  ELPAtom atom
           
 
Constructor Summary
NegLiteral(ELPAtom a)
           
 
Method Summary
 boolean equals(java.lang.Object o)
           
 ELPAtom getAtom()
          returns the atom of this literal
 ELPLiteral getLiteral()
          returns a possibly nested literal, or the object itself if this literal is not (strict or default) negated.
 boolean isArithmetic()
          deprecated, use isPredicate instead !
 boolean isAtom()
           
 boolean isDefaultNegated()
           
 boolean isPredicate()
          this method indicates if the literal appearing in a program is a build-in or external dlv predicate
 boolean isStrictNegated()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

atom

protected ELPAtom atom
Constructor Detail

NegLiteral

public NegLiteral(ELPAtom a)
Method Detail

getLiteral

public ELPLiteral getLiteral()
Description copied from interface: ELPLiteral
returns a possibly nested literal, or the object itself if this literal is not (strict or default) negated.

Specified by:
getLiteral in interface ELPLiteral
Returns:
nested literal

isAtom

public boolean isAtom()
Specified by:
isAtom in interface ELPLiteral
Returns:
true if this literal is an atom

isDefaultNegated

public boolean isDefaultNegated()
Specified by:
isDefaultNegated in interface ELPLiteral
Returns:
true if this literal is default negated

isStrictNegated

public boolean isStrictNegated()
Specified by:
isStrictNegated in interface ELPLiteral
Returns:
true if this literal is strictly negated

getAtom

public ELPAtom getAtom()
Description copied from interface: ELPLiteral
returns the atom of this literal

Specified by:
getAtom in interface ELPLiteral
Returns:
atom

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object

isArithmetic

public boolean isArithmetic()
Description copied from interface: ELPLiteral
deprecated, use isPredicate instead !

Specified by:
isArithmetic in interface ELPLiteral
Returns:
true if this objects models an arithmetic expression

equals

public boolean equals(java.lang.Object o)
Overrides:
equals in class java.lang.Object

isPredicate

public boolean isPredicate()
Description copied from interface: ELPLiteral
this method indicates if the literal appearing in a program is a build-in or external dlv predicate

Specified by:
isPredicate in interface ELPLiteral
Returns:
true if this object models a dlv predicate