12345678910111213141516171819202122232425262728293031323334 |
- package classes.holonControlUnit.messages;
- import java.util.ArrayList;
- import classes.Holon;
- public class NeighborhoodMsg {
- public enum Type {
- NEW_VIRTUAL_NEIGHBOR, REMOVE_VIRTUAL_NEIGHBOR }
- // NEW_PHYSICAL_NEIGHBOR, REMOVE_PHYSICAL_NEIGHBOR, SEARCH_PHYSICAL_NEIGHBOR_REQ, SEARCH_PHYSICAL_NEIGHBOR_ANS }
- private Type type;
- private ArrayList<String> neighbors;
- public NeighborhoodMsg(Type type, ArrayList<String> newVirtualNeighbor) {
- super();
- this.type = type;
- this.neighbors = newVirtualNeighbor;
- }
- @Override
- public String toString() {
- return "NeighborhoodMsg [type=" + type + ", neighbors=" + neighbors + "]";
- }
- public ArrayList<String> getNeighbors() {
- return neighbors;
- }
- public Type getType() {
- return type;
- }
-
- }
|