|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.jmlspecs.checker.JmlDataGroupMemberMap
This class acts as a
| Field Summary | |
private boolean |
inheritedMembersAdded
|
private HashMap |
memberMap
A mapping from JmlSourceField objects to
JmlAssignableFieldsSet objects for handling members
of data groups and checking assignable clauses. |
| Constructor Summary | |
JmlDataGroupMemberMap()
|
|
| Method Summary | |
void |
addGroup(JmlSourceField field)
Add a mapping from field to the members
of its data group. |
void |
addInheritedMembers(JmlDataGroupMemberMap parentMap)
Add mappings for any groups in parentMap that are
already in this map. |
void |
addMember(JmlSourceField group,
CField member)
Add member to the member set of group
if group is already in this map. |
void |
addMembers(JmlSourceField group,
JmlAssignableFieldSet members)
Add a mapping for group if it is not already in this
map. |
JmlAssignableFieldSet |
getMembers(JmlSourceField group)
Returns the members of the given data group. |
Iterator |
keyGroupIterator()
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
private HashMap memberMap
JmlSourceField objects to
JmlAssignableFieldsSet objects for handling members
of data groups and checking assignable clauses.
private invariant memberMap != null;
private boolean inheritedMembersAdded
| Constructor Detail |
public JmlDataGroupMemberMap()
| Method Detail |
public void addGroup(JmlSourceField field)
field to the members
of its data group. Initially the member set only has
one member, i.e., field. This is only
done if field is a data group, i.e., if it
is a model field or has either a spec_public or spec_protected
visibility modifier.
public void addMember(JmlSourceField group,
CField member)
member to the member set of group
if group is already in this map.
Otherwise, create a new group and add member
to the member set for group.
requires group != null && member != null && group.isDataGroup();
public void addMembers(JmlSourceField group,
JmlAssignableFieldSet members)
group if it is not already in this
map. Otherwise, merge (union) member with
sets for any groups that are in both maps.
requires group != null && members != null && group.isDataGroup();
public Iterator keyGroupIterator()
public void addInheritedMembers(JmlDataGroupMemberMap parentMap)
parentMap that are
already in this map. Also, merge (union) the member sets for any
groups that are in both maps.
requires parentMap != null && inheritedMembersAdded == false;
public JmlAssignableFieldSet getMembers(JmlSourceField group)
group is not in the domain of this map,
then null is returned.
requires group != null;
public String toString()
toString in class Object
|
JML | ||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||