Package MAKBPInterpreter.agents
Class Box
- java.lang.Object
-
- MAKBPInterpreter.agents.AgentKnowledge
-
- MAKBPInterpreter.agents.Box
-
- All Implemented Interfaces:
Formula
public class Box extends AgentKnowledge
Represents a knowledge that agent knows it true in a world in a modal logic system.
-
-
Field Summary
-
Fields inherited from class MAKBPInterpreter.agents.AgentKnowledge
agent, innerFormula
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanevaluate(LogicAssignment assignment)Evaluates a state that we passed into arguments.Formulasimplify()Simplifies the logic formula.-
Methods inherited from class MAKBPInterpreter.agents.AgentKnowledge
contains, equals, getAgent, getInnerFormula, getNegation, hashCode, toString
-
-
-
-
Method Detail
-
simplify
public Formula simplify()
Description copied from interface:FormulaSimplifies the logic formula.- Specified by:
simplifyin interfaceFormula- Overrides:
simplifyin classAgentKnowledge- Returns:
- simplified formula
-
evaluate
public boolean evaluate(LogicAssignment assignment) throws java.lang.Exception
Description copied from interface:FormulaEvaluates a state that we passed into arguments.- Specified by:
evaluatein interfaceFormula- Overrides:
evaluatein classAgentKnowledge- Parameters:
assignment- state to evaluate- Returns:
- result of the evaluation
- Throws:
java.lang.Exception- throws when the formula not supported this operation or expected object not given
-
-