public class Relations
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
private java.util.Map<java.lang.Integer,java.util.Set<Formula>> |
announcements |
private KripkeModel |
parent |
| Constructor and Description |
|---|
Relations(KripkeModel parent)
Initialises a relation matrix in which all possible relations are present.
|
Relations(Relations other)
Makes a deep copy
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(java.lang.Integer from,
java.lang.Integer to,
java.lang.Integer agent) |
boolean |
containsAll(java.lang.Integer from,
java.lang.Integer to,
java.util.Set<java.lang.Integer> agents) |
boolean |
containsAny(java.lang.Integer from,
java.lang.Integer to,
java.util.Set<java.lang.Integer> agents) |
void |
privateAnnouncement(Formula phi,
java.lang.Integer agent)
Updates the relations according to the specified private announcement
|
private KripkeModel parent
private java.util.Map<java.lang.Integer,java.util.Set<Formula>> announcements
public Relations(KripkeModel parent)
parent - KripkeModel instance that this Relations belongs to.public Relations(Relations other)
other - The to be deep copied Relations instancepublic boolean contains(java.lang.Integer from,
java.lang.Integer to,
java.lang.Integer agent)
from - One of the states involved in the relation. This can be switched with the to parameter without consequences since the Kripke model is in S5.to - One of the states involved in the relation. This can be switched with the from parameter without consequences since the Kripke model is in S5.agent - The agent for which the function checks whether the queried relation holds.public boolean containsAny(java.lang.Integer from,
java.lang.Integer to,
java.util.Set<java.lang.Integer> agents)
from - One of the states involved in the relation. This can be switched with the to parameter without consequences since the Kripke model is in S5.to - One of the states involved in the relation. This can be switched with the from parameter without consequences since the Kripke model is in S5.agents - The agents for which the function checks whether the queried relation holds.public boolean containsAll(java.lang.Integer from,
java.lang.Integer to,
java.util.Set<java.lang.Integer> agents)
from - One of the states involved in the relation. This can be switched with the to parameter without consequences since the Kripke model is in S5.to - One of the states involved in the relation. This can be switched with the from parameter without consequences since the Kripke model is in S5.agents - The agents for which the function checks whether the queried relation holds.public void privateAnnouncement(Formula phi, java.lang.Integer agent)
phi - Formula that is announcedagent - Agent to which the private announcement is done