Пример #1
0
 public static String getNodeKey(Node node) {
   String nodeName = node.getNodeName();
   if (nodeName == null) {
     nodeName = "";
   }
   return String.format("%s_%s_%s", node.getIp(), node.getPort(), nodeName);
 }
Пример #2
0
 private Node getNode(String name) {
   Node node = new Node();
   node.setNodeName(name);
   return node;
 }