public class BBFunction extends BlackBoxAgent implements java.io.Serializable
Constructor and Description |
---|
BBFunction()
Instantiates a new BB function.
|
Modifier and Type | Method and Description |
---|---|
void |
addInputAgent(Agent agent)
Adds the input agent.
|
void |
computeAMessage(Message m)
Compute A message.
|
int |
countFreeInputSlot()
Count free input slot.
|
void |
fastPlay()
Fast play.
|
Agent |
getAgentA()
Gets the agent A.
|
Agent |
getAgentB()
Gets the agent B.
|
MathFunction |
getFunc()
Gets the func.
|
double |
getValue()
Gets the value.
|
boolean |
isLoopingItself()
Checks if is looping itself.
|
boolean |
ownSpecificInput(Agent a)
Own specific input.
|
void |
play()
Play one agent step.
|
void |
setAgentA(Agent agentA)
Sets the agent A.
|
void |
setAgentB(Agent agentB)
Sets the agent B.
|
void |
setFunc(MathFunction func)
Sets the func.
|
addConstraint, computeCriticity, getConstraints, getCriticity, getTargets, getWorstConstraint, readMessage, setConstraints, setCriticity, setTargets
die, getID, getMessages, getMessagesBin, getName, isDying, sendExpressMessage, sendMessage, sendMessage, setDying, setID, setMessages, setMessagesBin, setName
public void play()
Agent
public void fastPlay()
BlackBoxAgent
fastPlay
in class BlackBoxAgent
public MathFunction getFunc()
public void setFunc(MathFunction func)
func
- the new funcpublic void computeAMessage(Message m)
Agent
computeAMessage
in class BlackBoxAgent
m
- the mpublic Agent getAgentA()
public void setAgentA(Agent agentA)
agentA
- the new agent Apublic Agent getAgentB()
public void setAgentB(Agent agentB)
agentB
- the new agent Bpublic double getValue()
BlackBoxAgent
getValue
in class BlackBoxAgent
public void addInputAgent(Agent agent)
agent
- the agentpublic int countFreeInputSlot()
public boolean ownSpecificInput(Agent a)
a
- the apublic boolean isLoopingItself()