|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object jildt.Functions
public class Functions
Class that implements generic functions for being used in different internal actions.
Constructor Summary | |
---|---|
Functions()
|
Method Summary | |
---|---|
static java.lang.String |
agentName(jason.asSemantics.Agent ag)
Gets the name of an agent. |
static jason.asSyntax.Term |
cleanTerm(jason.asSyntax.Term query)
Cleans a Term from anonymous variables to variables. e.g., if the term clear(_89X), is given, the function will return the term clear(X). |
static void |
collectBoundedVars(jason.asSyntax.Term Qn,
java.util.HashSet<jason.asSyntax.Term> vars)
Find the bounded variables in a query. |
static java.lang.String |
getNewVar(java.util.HashSet<jason.asSyntax.Term> used)
Selects a new variable. |
static jason.bb.DefaultBeliefBase |
joinBB(jason.asSyntax.ListTerm beliefs,
java.util.ArrayList<jason.asSyntax.Term> background)
Joins a belief base (ListTerm) and a background belief base. |
static boolean |
logicalConsequence(jason.asSyntax.LogicalFormula form,
jason.bb.BeliefBase bb)
Asks if a formula is logical consequence of a belief base plus a background belief base. |
static jason.asSyntax.LogicalFormula |
parseConjCtxt(jason.asSyntax.ListTerm terms)
Parses a ListTerm to a conjunctive logical formula. |
static jason.asSyntax.LogicalFormula |
parseDisyCtxt(jason.asSyntax.ListTerm terms)
Parses a ListTerm to a disjunctive logical formula. |
static java.util.logging.Level |
traceLevel(Learner agent)
Specify the logging level for tracing, accordingly the agent attribute for trace. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Functions()
Method Detail |
---|
public static jason.asSyntax.Term cleanTerm(jason.asSyntax.Term query)
query
- The term to be cleaned.
public static java.lang.String agentName(jason.asSemantics.Agent ag)
ag
- The agent.
public static jason.asSyntax.LogicalFormula parseConjCtxt(jason.asSyntax.ListTerm terms) throws jason.asSyntax.parser.ParseException
terms
- the ListTerm to be parsed.
jason.asSyntax.parser.ParseException
public static jason.asSyntax.LogicalFormula parseDisyCtxt(jason.asSyntax.ListTerm terms) throws jason.asSyntax.parser.ParseException
terms
- the ListTerm to be parsed.
jason.asSyntax.parser.ParseException
public static jason.bb.DefaultBeliefBase joinBB(jason.asSyntax.ListTerm beliefs, java.util.ArrayList<jason.asSyntax.Term> background)
beliefs
- The belief basebackground
- The background belief base
public static boolean logicalConsequence(jason.asSyntax.LogicalFormula form, jason.bb.BeliefBase bb)
form
- The logical formula to be tested.bb
- The belief base the formula will be evaluated for.
public static void collectBoundedVars(jason.asSyntax.Term Qn, java.util.HashSet<jason.asSyntax.Term> vars) throws jason.asSyntax.parser.ParseException
Qn
- The nth element of a query Q.vars
- A set to store the vars found.
jason.asSyntax.parser.ParseException
public static java.lang.String getNewVar(java.util.HashSet<jason.asSyntax.Term> used)
used
- A set with the variables that cannot be used.
public static java.util.logging.Level traceLevel(Learner agent)
agent
- The agent that knows if an internal action is traceable.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |