public class GroupMembershipGDiffMessageTask
extends java.lang.Object
implements java.lang.Runnable
Constructor and Description |
---|
GroupMembershipGDiffMessageTask(GroupDefiner groupDefiner,
Message mobileNodeInformation)
Constructs a GroupMembershipGDiffMessageTask from GroupDefinerīs instance and the CxtU.
|
Modifier and Type | Method and Description |
---|---|
static void |
addAllGroups(java.util.Set<java.lang.Integer> groupCollection,
java.util.Collection<java.lang.Integer> groupsToBeInserted)
Adds a array of groups to the specified Set of groups
|
static java.util.Set<java.lang.Integer> |
getGDiffMessage(java.util.Set<java.lang.Integer> newGroupCollection,
java.util.Set<java.lang.Integer> oldGroupCollection)
Calculates the Gdiff message from the newGroupCollection and oldGroupCollection
|
static java.util.Set<java.lang.Integer> |
getGroupCollection(Message nodeMessage,
int groupType)
Gets all groups that have the specified group type
|
void |
run()
Processes the CxtU message and calculates the Gdiff message
|
public GroupMembershipGDiffMessageTask(GroupDefiner groupDefiner, Message mobileNodeInformation)
groupDefiner
- GroupDefinerīs instancemobileNodeInformation
- CxtU message produced by Mobile Nodepublic void run()
run
in interface java.lang.Runnable
public static java.util.Set<java.lang.Integer> getGroupCollection(Message nodeMessage, int groupType)
nodeMessage
- CxtU messagegroupType
- The specified group typepublic static void addAllGroups(java.util.Set<java.lang.Integer> groupCollection, java.util.Collection<java.lang.Integer> groupsToBeInserted)
groupCollection
- The specified collection where the groups will be insertedgroupsToBeInserted
- Groups to be inserted in the specified collectionpublic static java.util.Set<java.lang.Integer> getGDiffMessage(java.util.Set<java.lang.Integer> newGroupCollection, java.util.Set<java.lang.Integer> oldGroupCollection)
newGroupCollection
- The Mobile Nodeīs groups calculated by the Group Selection Module. These groups are also called the new (or current) MNīs groupsoldGroupCollection
- The Mobile Nodeīs groups informed by the Gateway. These groups are also called the old MNīs groups