jason.asSyntax
Class VarTerm

Package class diagram package VarTerm
java.lang.Object
  extended by jason.asSyntax.DefaultTerm
      extended by jason.asSyntax.Literal
          extended by jason.asSyntax.Atom
              extended by jason.asSyntax.Structure
                  extended by jason.asSyntax.Pred
                      extended by jason.asSyntax.LiteralImpl
                          extended by jason.asSyntax.VarTerm
All Implemented Interfaces:
ListTerm, LogicalFormula, NumberTerm, ObjectTerm, PlanBody, StringTerm, Term, ToDOM, java.io.Serializable, java.lang.Cloneable, java.lang.Comparable<Term>, java.lang.Iterable<Term>, java.util.Collection<Term>, java.util.List<Term>
Direct Known Subclasses:
UnnamedVar

public class VarTerm
extends LiteralImpl
implements NumberTerm, ListTerm, StringTerm, ObjectTerm, PlanBody

Represents a variable Term: like X (starts with upper case). It may have a value, after VarTerm.apply. An object of this class can be used in place of a Literal, Number, List, String, .... It behaves like a Literal, Number, .... just in case its value is a Literal, Number, ...

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from interface jason.asSyntax.PlanBody
PlanBody.BodyType
 
Field Summary
 
Fields inherited from class jason.asSyntax.Structure
emptyTermArray, emptyTermList
 
Fields inherited from class jason.asSyntax.Literal
LFalse, LNeg, LPos, LTrue, predicateIndicatorCache
 
Fields inherited from class jason.asSyntax.DefaultTerm
hashCodeCache, srcInfo
 
Constructor Summary
VarTerm(java.lang.String s)
           
 
Method Summary
 boolean add(int index, PlanBody bl)
           
 void add(int index, Term o)
           
 boolean add(PlanBody bl)
           
 boolean add(Term o)
           
 boolean addAll(java.util.Collection c)
           
 boolean addAll(int index, java.util.Collection c)
           
 boolean addAnnot(Term t)
           
 Literal addAnnots(java.util.List<Term> l)
          adds some annots and return this
 void addSource(Term t)
          adds the annotation source(agName)
 void addTerm(Term t)
           
 Literal addTerms(java.util.List<Term> l)
          adds some terms and return this
 ListTerm append(Term t)
           
 boolean apply(Unifier u)
          replaces variables by their values in the unifier, returns true if some variable was applied
 boolean canBeAddedInBB()
          to be overridden by subclasses (as internal action)
 void clear()
           
 void clearAnnots()
          removes all annotations
 Term clone()
          make a deep copy of the terms
 ListTerm cloneLT()
          clone the list term
 ListTerm cloneLTShallow()
          make a shallow copy of the list (terms are not cloned, only the structure)
 PlanBody clonePB()
          clone the plan body
 int compareTo(Term t)
           
 ListTerm concat(ListTerm lt)
           
 boolean contains(java.lang.Object o)
           
 boolean containsAll(java.util.Collection c)
           
 void countVars(java.util.Map<VarTerm,java.lang.Integer> c)
           
 boolean delAnnot(Term t)
           
 boolean delAnnots(java.util.List<Term> l)
          removes all annots in this pred that are in the list l.
 boolean delSource(Term s)
          deletes one source(agName) annotation, return true if deleted
 void delSources()
          deletes all source annotations
 ListTerm difference(ListTerm lt)
           
 boolean equals(java.lang.Object t)
           
 Term get(int index)
           
 ListTerm getAnnots()
          returns all annotations of the literal
 int getArity()
          returns the number of terms of this literal
 org.w3c.dom.Element getAsDOM(org.w3c.dom.Document document)
          get as XML
 java.util.List<Term> getAsList()
           
 PlanBody getBodyNext()
           
 Term getBodyTerm()
           
 PlanBody.BodyType getBodyType()
           
 java.lang.String getFunctor()
          returns the functor of this literal
 ListTerm getLast()
           
 PlanBody getLastBody()
           
 ListTerm getNext()
           
 java.lang.Object getObject()
           
 ListTerm getPenultimate()
           
 int getPlanSize()
           
 PredicateIndicator getPredicateIndicator()
          returns [~] super.getPredicateIndicator
 ListTerm getSources()
          returns the sources of this literal as a new list.
 java.lang.String getString()
          gets the Java string represented by this term, it normally does not return the same string as toString (which enclose the string by quotes)
 VarTerm getTail()
           
 Term getTerm()
           
 Term getTerm(int i)
          returns the i-th term (first term is 0)
 java.util.List<Term> getTerms()
          returns all terms of this literal
 Term[] getTermsArray()
          returns all terms of this literal as an array
 Term getValue()
          returns the value of this var.
 boolean hasAnnot()
          returns true if the pred has at least one annot
 boolean hasAnnot(Term t)
          returns true if there is some annotation t in the literal
 int hashCode()
           
 boolean hasSource()
          returns true if this literal has some source annotation
 boolean hasSource(Term s)
          returns true if this literal has a "source(agName)"
 boolean hasSubsetAnnot(Literal p)
          returns true if all this predicate annots are in p's annots
 boolean hasSubsetAnnot(Literal p, Unifier u)
          Returns true if all this predicate's annots are in p's annots using the unifier u.
 boolean hasValue()
          returns true if this var has a value
 boolean hasVar(VarTerm t)
           
 boolean importAnnots(Literal p)
          "import" annots from another predicate p.
 int indexOf(java.lang.Object o)
           
 ListTerm insert(Term t)
           
 ListTerm intersection(ListTerm lt)
           
 boolean isArithExpr()
           
 boolean isAtom()
           
 boolean isBodyTerm()
           
 boolean isEmpty()
           
 boolean isEmptyBody()
           
 boolean isEnd()
           
 boolean isGround()
           
 boolean isInternalAction()
           
 boolean isList()
           
 boolean isLiteral()
           
 boolean isNumeric()
           
 boolean isPlanBody()
           
 boolean isPred()
           
 boolean isRule()
           
 boolean isString()
           
 boolean isStructure()
           
 boolean isTail()
           
 boolean isUnnamedVar()
           
 boolean isVar()
           
 java.util.Iterator<Term> iterator()
           
 int lastIndexOf(java.lang.Object o)
           
 int length()
           
 java.util.ListIterator<Term> listIterator()
           
 java.util.ListIterator<Term> listIterator(int index)
           
 java.util.Iterator<ListTerm> listTermIterator()
           
 java.util.Iterator<Unifier> logicalConsequence(Agent ag, Unifier un)
          logicalConsequence checks whether one particular predicate is a logical consequence of the belief base.
 Literal makeVarsAnnon(Unifier un)
          replaces all variables of the term for unnamed variables (_).
 boolean negated()
          returns whether this literal is negated or not, use Literal.LNeg and Literal.LPos to compare the returned value
static VarTerm parseVar(java.lang.String sVar)
          Deprecated. prefer ASSyntax.parseVar(...)
 Term remove(int index)
           
 boolean remove(java.lang.Object o)
           
 boolean removeAll(java.util.Collection c)
           
 Term removeBody(int index)
           
 Term removeLast()
           
 boolean retainAll(java.util.Collection c)
           
 ListTerm reverse()
           
 Term set(int index, Term o)
           
 Literal setAnnots(ListTerm l)
           
 void setAsBodyTerm(boolean b)
           
 void setBodyNext(PlanBody bl)
           
 void setBodyTerm(Term t)
           
 void setBodyType(PlanBody.BodyType bt)
           
 void setNext(Term t)
           
 void setTail(VarTerm v)
           
 void setTerm(int i, Term t)
           
 void setTerm(Term t)
           
 Literal setTerms(java.util.List<Term> l)
          set all terms of the literal and return this
 boolean setValue(Term vl)
          grounds a variable, set a value for this var (e.g.
 int size()
           
 double solve()
          returns the numeric value of the term
 java.util.List<Term> subList(int arg0, int arg1)
           
 java.util.Iterator<java.util.List<Term>> subSets(int k)
          returns all subsets that take k elements of this list
 java.lang.Object[] toArray()
           
 java.lang.Object[] toArray(java.lang.Object[] arg0)
           
 java.lang.String toString()
           
 ListTerm union(ListTerm lt)
           
 
Methods inherited from class jason.asSyntax.LiteralImpl
calcHashCode, getErrorMsg, setNegated
 
Methods inherited from class jason.asSyntax.Pred
addAnnots, createSource, equalsAsStructure, getAnnots, parsePred, toStringAsTerm
 
Methods inherited from class jason.asSyntax.Structure
addTerms, delTerm, getSingletonVars, getTermsSize, hasTerm, makeTermsAnnon, makeVarsAnnon, parse, varToReplace
 
Methods inherited from class jason.asSyntax.Literal
copy, forceFullLiteralImpl, getAsListOfTerms, newFromListOfTerms, parseLiteral
 
Methods inherited from class jason.asSyntax.DefaultTerm
getSrcInfo, resetHashCodeCache, setSrcInfo
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface jason.asSyntax.Term
getSrcInfo, setSrcInfo
 

Constructor Detail

VarTerm

public VarTerm(java.lang.String s)
Method Detail

parseVar

public static VarTerm parseVar(java.lang.String sVar)
Deprecated. prefer ASSyntax.parseVar(...)


clone

public Term clone()
Description copied from class: Structure
make a deep copy of the terms

Specified by:
clone in interface Term
Overrides:
clone in class LiteralImpl

clonePB

public PlanBody clonePB()
Description copied from interface: PlanBody
clone the plan body

Specified by:
clonePB in interface PlanBody

cloneLT

public ListTerm cloneLT()
Description copied from interface: ListTerm
clone the list term

Specified by:
cloneLT in interface ListTerm

isVar

public boolean isVar()
Specified by:
isVar in interface Term
Overrides:
isVar in class DefaultTerm

isUnnamedVar

public boolean isUnnamedVar()
Specified by:
isUnnamedVar in interface Term
Overrides:
isUnnamedVar in class DefaultTerm

isGround

public boolean isGround()
Specified by:
isGround in interface Term
Overrides:
isGround in class Pred

setValue

public boolean setValue(Term vl)
grounds a variable, set a value for this var (e.g. X = 10; Y = a(b,c); ...)


hasValue

public boolean hasValue()
returns true if this var has a value


apply

public boolean apply(Unifier u)
Description copied from interface: Term
replaces variables by their values in the unifier, returns true if some variable was applied

Specified by:
apply in interface Term
Overrides:
apply in class Pred

getValue

public Term getValue()
returns the value of this var.


equals

public boolean equals(java.lang.Object t)
Specified by:
equals in interface Term
Specified by:
equals in interface java.util.Collection<Term>
Specified by:
equals in interface java.util.List<Term>
Overrides:
equals in class LiteralImpl

compareTo

public int compareTo(Term t)
Specified by:
compareTo in interface java.lang.Comparable<Term>
Overrides:
compareTo in class LiteralImpl

getFunctor

public java.lang.String getFunctor()
Description copied from class: Literal
returns the functor of this literal

Overrides:
getFunctor in class Atom

getPredicateIndicator

public PredicateIndicator getPredicateIndicator()
Description copied from class: LiteralImpl
returns [~] super.getPredicateIndicator

Overrides:
getPredicateIndicator in class LiteralImpl

hashCode

public int hashCode()
Specified by:
hashCode in interface java.util.Collection<Term>
Specified by:
hashCode in interface java.util.List<Term>
Overrides:
hashCode in class DefaultTerm

logicalConsequence

public java.util.Iterator<Unifier> logicalConsequence(Agent ag,
                                                      Unifier un)
Description copied from class: Literal
logicalConsequence checks whether one particular predicate is a logical consequence of the belief base. Returns an iterator for all unifiers that are logCons.

Specified by:
logicalConsequence in interface LogicalFormula
Overrides:
logicalConsequence in class Literal

getTerm

public Term getTerm(int i)
Description copied from class: Literal
returns the i-th term (first term is 0)

Overrides:
getTerm in class Structure

addTerm

public void addTerm(Term t)
Overrides:
addTerm in class Structure

getArity

public int getArity()
Description copied from class: Literal
returns the number of terms of this literal

Overrides:
getArity in class Structure

getTerms

public java.util.List<Term> getTerms()
Description copied from class: Literal
returns all terms of this literal

Overrides:
getTerms in class Structure

setTerms

public Literal setTerms(java.util.List<Term> l)
Description copied from class: Literal
set all terms of the literal and return this

Overrides:
setTerms in class Structure

setTerm

public void setTerm(int i,
                    Term t)
Overrides:
setTerm in class Structure

addTerms

public Literal addTerms(java.util.List<Term> l)
Description copied from class: Literal
adds some terms and return this

Overrides:
addTerms in class Structure

getTermsArray

public Term[] getTermsArray()
Description copied from class: Literal
returns all terms of this literal as an array

Overrides:
getTermsArray in class Literal

isInternalAction

public boolean isInternalAction()
Specified by:
isInternalAction in interface Term
Overrides:
isInternalAction in class DefaultTerm

isList

public boolean isList()
Specified by:
isList in interface Term
Overrides:
isList in class DefaultTerm

isString

public boolean isString()
Specified by:
isString in interface Term
Overrides:
isString in class DefaultTerm

isPlanBody

public boolean isPlanBody()
Specified by:
isPlanBody in interface Term
Overrides:
isPlanBody in class DefaultTerm

isNumeric

public boolean isNumeric()
Specified by:
isNumeric in interface Term
Overrides:
isNumeric in class DefaultTerm

isPred

public boolean isPred()
Specified by:
isPred in interface Term
Overrides:
isPred in class Pred

isLiteral

public boolean isLiteral()
Specified by:
isLiteral in interface Term
Overrides:
isLiteral in class Literal

isStructure

public boolean isStructure()
Specified by:
isStructure in interface Term
Overrides:
isStructure in class Structure

isAtom

public boolean isAtom()
Specified by:
isAtom in interface Term
Overrides:
isAtom in class LiteralImpl

isRule

public boolean isRule()
Specified by:
isRule in interface Term
Overrides:
isRule in class DefaultTerm

isArithExpr

public boolean isArithExpr()
Specified by:
isArithExpr in interface Term
Overrides:
isArithExpr in class DefaultTerm

hasVar

public boolean hasVar(VarTerm t)
Specified by:
hasVar in interface Term
Overrides:
hasVar in class Pred

countVars

public void countVars(java.util.Map<VarTerm,java.lang.Integer> c)
Specified by:
countVars in interface Term
Overrides:
countVars in class Pred

makeVarsAnnon

public Literal makeVarsAnnon(Unifier un)
Description copied from class: Literal
replaces all variables of the term for unnamed variables (_).

Overrides:
makeVarsAnnon in class Pred
Parameters:
un - is the unifier that contains the map of replacements

toString

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

setAnnots

public Literal setAnnots(ListTerm l)
Overrides:
setAnnots in class Pred

importAnnots

public boolean importAnnots(Literal p)
Description copied from class: Literal
"import" annots from another predicate p. p will be changed to contain only the annots actually imported (for Event), for example: p = b[a,b] this = b[b,c] after import, p = b[a] It is used to generate event <+b[a]>.

Overrides:
importAnnots in class Pred
Returns:
true if some annot was imported.

addAnnot

public boolean addAnnot(Term t)
Overrides:
addAnnot in class Pred

addAnnots

public Literal addAnnots(java.util.List<Term> l)
Description copied from class: Literal
adds some annots and return this

Overrides:
addAnnots in class Pred

clearAnnots

public void clearAnnots()
Description copied from class: Literal
removes all annotations

Overrides:
clearAnnots in class Pred

delAnnots

public boolean delAnnots(java.util.List<Term> l)
Description copied from class: Literal
removes all annots in this pred that are in the list l.

Overrides:
delAnnots in class Pred
Returns:
true if some annot was removed.

delAnnot

public boolean delAnnot(Term t)
Overrides:
delAnnot in class Pred

hasAnnot

public boolean hasAnnot(Term t)
Description copied from class: Literal
returns true if there is some annotation t in the literal

Overrides:
hasAnnot in class Pred

hasAnnot

public boolean hasAnnot()
Description copied from class: Literal
returns true if the pred has at least one annot

Overrides:
hasAnnot in class Pred

hasSubsetAnnot

public boolean hasSubsetAnnot(Literal p)
Description copied from class: Literal
returns true if all this predicate annots are in p's annots

Overrides:
hasSubsetAnnot in class Pred

hasSubsetAnnot

public boolean hasSubsetAnnot(Literal p,
                              Unifier u)
Description copied from class: Literal
Returns true if all this predicate's annots are in p's annots using the unifier u. if p annots has a Tail, p annots's Tail will receive this predicate's annots, e.g.: this[a,b,c] = p[x,y,b|T] unifies and T is [a,c] (this will be a subset if p has a and c in its annots). if this annots has a tail, the Tail will receive all necessary term to be a subset, e.g.: this[b|T] = p[x,y,b] unifies and T is [x,y] (this will be a subset if T is [x,y].

Overrides:
hasSubsetAnnot in class Pred

getAnnots

public ListTerm getAnnots()
Description copied from class: Literal
returns all annotations of the literal

Overrides:
getAnnots in class Pred

addSource

public void addSource(Term t)
Description copied from class: Literal
adds the annotation source(agName)

Overrides:
addSource in class Pred

delSource

public boolean delSource(Term s)
Description copied from class: Literal
deletes one source(agName) annotation, return true if deleted

Overrides:
delSource in class Pred

delSources

public void delSources()
Description copied from class: Literal
deletes all source annotations

Overrides:
delSources in class Pred

getSources

public ListTerm getSources()
Description copied from class: Literal
returns the sources of this literal as a new list. e.g.: from annots [source(a), source(b)], it returns [a,b]

Overrides:
getSources in class Pred

hasSource

public boolean hasSource()
Description copied from class: Literal
returns true if this literal has some source annotation

Overrides:
hasSource in class Pred

hasSource

public boolean hasSource(Term s)
Description copied from class: Literal
returns true if this literal has a "source(agName)"

Overrides:
hasSource in class Pred

negated

public boolean negated()
Description copied from class: Literal
returns whether this literal is negated or not, use Literal.LNeg and Literal.LPos to compare the returned value

Overrides:
negated in class LiteralImpl

canBeAddedInBB

public boolean canBeAddedInBB()
Description copied from class: LiteralImpl
to be overridden by subclasses (as internal action)

Overrides:
canBeAddedInBB in class LiteralImpl

solve

public double solve()
Description copied from interface: NumberTerm
returns the numeric value of the term

Specified by:
solve in interface NumberTerm

add

public void add(int index,
                Term o)
Specified by:
add in interface java.util.List<Term>

add

public boolean add(Term o)
Specified by:
add in interface java.util.Collection<Term>
Specified by:
add in interface java.util.List<Term>

addAll

public boolean addAll(java.util.Collection c)
Specified by:
addAll in interface java.util.Collection<Term>
Specified by:
addAll in interface java.util.List<Term>

addAll

public boolean addAll(int index,
                      java.util.Collection c)
Specified by:
addAll in interface java.util.List<Term>

clear

public void clear()
Specified by:
clear in interface java.util.Collection<Term>
Specified by:
clear in interface java.util.List<Term>

contains

public boolean contains(java.lang.Object o)
Specified by:
contains in interface java.util.Collection<Term>
Specified by:
contains in interface java.util.List<Term>

containsAll

public boolean containsAll(java.util.Collection c)
Specified by:
containsAll in interface java.util.Collection<Term>
Specified by:
containsAll in interface java.util.List<Term>

get

public Term get(int index)
Specified by:
get in interface java.util.List<Term>

indexOf

public int indexOf(java.lang.Object o)
Specified by:
indexOf in interface java.util.List<Term>

lastIndexOf

public int lastIndexOf(java.lang.Object o)
Specified by:
lastIndexOf in interface java.util.List<Term>

iterator

public java.util.Iterator<Term> iterator()
Specified by:
iterator in interface java.lang.Iterable<Term>
Specified by:
iterator in interface java.util.Collection<Term>
Specified by:
iterator in interface java.util.List<Term>

listIterator

public java.util.ListIterator<Term> listIterator()
Specified by:
listIterator in interface java.util.List<Term>

listIterator

public java.util.ListIterator<Term> listIterator(int index)
Specified by:
listIterator in interface java.util.List<Term>

remove

public Term remove(int index)
Specified by:
remove in interface java.util.List<Term>

remove

public boolean remove(java.lang.Object o)
Specified by:
remove in interface java.util.Collection<Term>
Specified by:
remove in interface java.util.List<Term>

removeAll

public boolean removeAll(java.util.Collection c)
Specified by:
removeAll in interface java.util.Collection<Term>
Specified by:
removeAll in interface java.util.List<Term>

retainAll

public boolean retainAll(java.util.Collection c)
Specified by:
retainAll in interface java.util.Collection<Term>
Specified by:
retainAll in interface java.util.List<Term>

set

public Term set(int index,
                Term o)
Specified by:
set in interface java.util.List<Term>

subList

public java.util.List<Term> subList(int arg0,
                                    int arg1)
Specified by:
subList in interface java.util.List<Term>

subSets

public java.util.Iterator<java.util.List<Term>> subSets(int k)
Description copied from interface: ListTerm
returns all subsets that take k elements of this list

Specified by:
subSets in interface ListTerm

toArray

public java.lang.Object[] toArray()
Specified by:
toArray in interface java.util.Collection<Term>
Specified by:
toArray in interface java.util.List<Term>

toArray

public java.lang.Object[] toArray(java.lang.Object[] arg0)
Specified by:
toArray in interface java.util.Collection<Term>
Specified by:
toArray in interface java.util.List<Term>

setTerm

public void setTerm(Term t)
Specified by:
setTerm in interface ListTerm

setNext

public void setNext(Term t)
Specified by:
setNext in interface ListTerm

append

public ListTerm append(Term t)
Specified by:
append in interface ListTerm

insert

public ListTerm insert(Term t)
Specified by:
insert in interface ListTerm

concat

public ListTerm concat(ListTerm lt)
Specified by:
concat in interface ListTerm

reverse

public ListTerm reverse()
Specified by:
reverse in interface ListTerm

union

public ListTerm union(ListTerm lt)
Specified by:
union in interface ListTerm

intersection

public ListTerm intersection(ListTerm lt)
Specified by:
intersection in interface ListTerm

difference

public ListTerm difference(ListTerm lt)
Specified by:
difference in interface ListTerm

getAsList

public java.util.List<Term> getAsList()
Specified by:
getAsList in interface ListTerm

getLast

public ListTerm getLast()
Specified by:
getLast in interface ListTerm

getPenultimate

public ListTerm getPenultimate()
Specified by:
getPenultimate in interface ListTerm

removeLast

public Term removeLast()
Specified by:
removeLast in interface ListTerm

getNext

public ListTerm getNext()
Specified by:
getNext in interface ListTerm

getTerm

public Term getTerm()
Specified by:
getTerm in interface ListTerm

isEmpty

public boolean isEmpty()
Specified by:
isEmpty in interface java.util.Collection<Term>
Specified by:
isEmpty in interface java.util.List<Term>

isEnd

public boolean isEnd()
Specified by:
isEnd in interface ListTerm

isTail

public boolean isTail()
Specified by:
isTail in interface ListTerm

setTail

public void setTail(VarTerm v)
Specified by:
setTail in interface ListTerm

getTail

public VarTerm getTail()
Specified by:
getTail in interface ListTerm

listTermIterator

public java.util.Iterator<ListTerm> listTermIterator()
Specified by:
listTermIterator in interface ListTerm

size

public int size()
Specified by:
size in interface java.util.Collection<Term>
Specified by:
size in interface java.util.List<Term>

cloneLTShallow

public ListTerm cloneLTShallow()
Description copied from interface: ListTerm
make a shallow copy of the list (terms are not cloned, only the structure)

Specified by:
cloneLTShallow in interface ListTerm

getString

public java.lang.String getString()
Description copied from interface: StringTerm
gets the Java string represented by this term, it normally does not return the same string as toString (which enclose the string by quotes)

Specified by:
getString in interface StringTerm

length

public int length()
Specified by:
length in interface StringTerm

getObject

public java.lang.Object getObject()
Specified by:
getObject in interface ObjectTerm

getBodyType

public PlanBody.BodyType getBodyType()
Specified by:
getBodyType in interface PlanBody

getBodyTerm

public Term getBodyTerm()
Specified by:
getBodyTerm in interface PlanBody

getBodyNext

public PlanBody getBodyNext()
Specified by:
getBodyNext in interface PlanBody

getLastBody

public PlanBody getLastBody()
Specified by:
getLastBody in interface PlanBody

isEmptyBody

public boolean isEmptyBody()
Specified by:
isEmptyBody in interface PlanBody

getPlanSize

public int getPlanSize()
Specified by:
getPlanSize in interface PlanBody

setBodyType

public void setBodyType(PlanBody.BodyType bt)
Specified by:
setBodyType in interface PlanBody

setBodyTerm

public void setBodyTerm(Term t)
Specified by:
setBodyTerm in interface PlanBody

setBodyNext

public void setBodyNext(PlanBody bl)
Specified by:
setBodyNext in interface PlanBody

isBodyTerm

public boolean isBodyTerm()
Specified by:
isBodyTerm in interface PlanBody

setAsBodyTerm

public void setAsBodyTerm(boolean b)
Specified by:
setAsBodyTerm in interface PlanBody

add

public boolean add(PlanBody bl)
Specified by:
add in interface PlanBody

add

public boolean add(int index,
                   PlanBody bl)
Specified by:
add in interface PlanBody

removeBody

public Term removeBody(int index)
Specified by:
removeBody in interface PlanBody

getAsDOM

public org.w3c.dom.Element getAsDOM(org.w3c.dom.Document document)
get as XML

Specified by:
getAsDOM in interface ToDOM
Overrides:
getAsDOM in class LiteralImpl