use of org.onosproject.openstacknode.api.NodeState in project onos by opennetworkinglab.
the class OpenstackNetworkingUtilTest method genGateway.
/**
* Util for generating dummy gateway node.
*
* @param index dummy gateway number
* @return dummy gateway node
*/
public OpenstackNode genGateway(int index) {
Device intgBrg = InternalOpenstackNodeTest.createDevice(index);
String hostname = "gateway-" + index;
IpAddress ip = Ip4Address.valueOf("10.10.10." + index);
NodeState state = NodeState.COMPLETE;
String uplinkPort = "eth0";
return InternalOpenstackNodeTest.createNode(hostname, OpenstackNode.NodeType.GATEWAY, intgBrg, ip, uplinkPort, state);
}