Updated sal-netconf-connector mountpoint integration
[controller.git] / opendaylight / md-sal / sal-netconf-connector / src / main / java / org / opendaylight / controller / sal / connect / netconf / NetconfInventoryUtils.java
1 package org.opendaylight.controller.sal.connect.netconf;
2
3 import org.opendaylight.yangtools.yang.common.QName;
4 import org.opendaylight.yangtools.yang.data.api.CompositeNode;
5
6 public class NetconfInventoryUtils {
7
8     
9     public static final QName NETCONF_MOUNT = null;
10     public static final QName NETCONF_ENDPOINT = null;
11     public static final QName NETCONF_ENDPOINT_ADDRESS = null;
12     public static final QName NETCONF_ENDPOINT_PORT = null;
13
14
15     public static String getEndpointAddress(CompositeNode node) {
16         return node.getCompositesByName(NETCONF_ENDPOINT).get(0).getFirstSimpleByName(NETCONF_ENDPOINT_ADDRESS).getValue().toString();
17     }
18     
19     public static String getEndpointPort(CompositeNode node) {
20         return node.getCompositesByName(NETCONF_ENDPOINT).get(0).getFirstSimpleByName(NETCONF_ENDPOINT_PORT).getValue().toString();
21     }
22 }