org.omwg.logicalexpression
Interface Atom

All Superinterfaces:
AtomicExpression, LogicalExpression
All Known Subinterfaces:
BuiltInAtom

public interface Atom
extends AtomicExpression

This interface represents an atom with a n-ary domain, where n is the arity of the predicate represented.

Version:
$Revision: 1946 $ $Date: 2007-04-02 15:13:28 +0300 (Mon, 02 Apr 2007) $
Author:
DERI Innsbruck, reto.krummenacher@deri.org
See Also:
AtomicExpression

Method Summary
 int getArity()
          The arity of the Atom indicates how many Terms are contained in the Atom's list of arguments.
 Identifier getIdentifier()
          The returned Identifier represents the name of the predicate.
 Term getParameter(int i)
          The index i points to a position in the Atom's list of arguments.
 List<Term> listParameters()
           
 void setParameters(List<Term> parameter)
           
 
Methods inherited from interface org.omwg.logicalexpression.LogicalExpression
accept, toString
 

Method Detail

getArity

int getArity()
The arity of the Atom indicates how many Terms are contained in the Atom's list of arguments.

Returns:
the arity of the atom, i.e. the number of parameters

getIdentifier

Identifier getIdentifier()
The returned Identifier represents the name of the predicate.

Returns:
the identifier of the atom, i.e. the name of the predicate

getParameter

Term getParameter(int i)
                  throws IllegalArgumentException
The index i points to a position in the Atom's list of arguments. So i mustn't exceed the arity of the atom. The desired Term, to which the index points, is returned.

Parameters:
i - the position of the parameter desired, maximal value getArity-1
Returns:
the parameter at the position provided as parameter
Throws:
IllegalArgumentException - in case i<0 or i exceeds the arity of the atom

listParameters

List<Term> listParameters()
Returns:
List containing the Atom's arguments (a list of Terms).

setParameters

void setParameters(List<Term> parameter)


Copyright © 2004-2008 Ontotext Lab.. All Rights Reserved.