Class NeutronUtils
- java.lang.Object
-
- org.opendaylight.netvirt.neutronvpn.api.utils.NeutronUtils
-
public final class NeutronUtils extends java.lang.Object
-
-
Field Summary
Fields Modifier and Type Field Description static java.lang.String
PORT_STATUS_ACTIVE
static java.lang.String
PORT_STATUS_BUILD
static java.lang.String
PORT_STATUS_DOWN
static java.lang.String
PORT_STATUS_ERROR
static java.lang.String
PORT_STATUS_NOTAPPLICABLE
static java.lang.String
VNIC_TYPE_NORMAL
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static boolean
createPortStatus(java.lang.String uuid, java.lang.String portStatus, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Create a Neutron Port status entry in the operational data store.static boolean
deletePortStatus(java.lang.String uuid, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Delete a Neutron Port status entry from the operational data store.static <T extends org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.networks.rev150712.NetworkTypeBase>
java.lang.StringgetSegmentationIdFromNeutronNetwork(org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.networks.rev150712.networks.attributes.networks.Network network, java.lang.Class<T> networkType)
static @NonNull java.util.List<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.Uuid>
getVpnMapRouterIdsListUuid(@Nullable java.util.List<RouterIds> routerIds)
static boolean
isPortVnicTypeNormal(org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.ports.rev150712.ports.attributes.ports.Port port)
static boolean
isUuid(java.lang.String possibleUuid)
static boolean
updatePortStatus(java.lang.String uuid, java.lang.String portStatus, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Update a Neutron Port status entry in the operational data store.
-
-
-
Field Detail
-
VNIC_TYPE_NORMAL
public static final java.lang.String VNIC_TYPE_NORMAL
- See Also:
- Constant Field Values
-
PORT_STATUS_ACTIVE
public static final java.lang.String PORT_STATUS_ACTIVE
- See Also:
- Constant Field Values
-
PORT_STATUS_BUILD
public static final java.lang.String PORT_STATUS_BUILD
- See Also:
- Constant Field Values
-
PORT_STATUS_DOWN
public static final java.lang.String PORT_STATUS_DOWN
- See Also:
- Constant Field Values
-
PORT_STATUS_ERROR
public static final java.lang.String PORT_STATUS_ERROR
- See Also:
- Constant Field Values
-
PORT_STATUS_NOTAPPLICABLE
public static final java.lang.String PORT_STATUS_NOTAPPLICABLE
- See Also:
- Constant Field Values
-
-
Method Detail
-
createPortStatus
public static boolean createPortStatus(java.lang.String uuid, java.lang.String portStatus, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Create a Neutron Port status entry in the operational data store.- Parameters:
uuid
- The uuid of the Neutron portportStatus
- value to set the status (see constants above)dataBroker
- DataBroker instance- Returns:
- true if transaction submitted successfully
-
updatePortStatus
public static boolean updatePortStatus(java.lang.String uuid, java.lang.String portStatus, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Update a Neutron Port status entry in the operational data store.- Parameters:
uuid
- The uuid of the Neutron portportStatus
- value to set the status (see constants above)dataBroker
- DataBroker instance- Returns:
- true if transaction submitted successfully
-
deletePortStatus
public static boolean deletePortStatus(java.lang.String uuid, org.opendaylight.mdsal.binding.api.DataBroker dataBroker)
Delete a Neutron Port status entry from the operational data store.- Parameters:
uuid
- The uuid of the Neutron portdataBroker
- DataBroker instance- Returns:
- true if transaction submitted successfully
-
isPortVnicTypeNormal
public static boolean isPortVnicTypeNormal(org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.ports.rev150712.ports.attributes.ports.Port port)
-
getSegmentationIdFromNeutronNetwork
public static <T extends org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.networks.rev150712.NetworkTypeBase> java.lang.String getSegmentationIdFromNeutronNetwork(org.opendaylight.yang.gen.v1.urn.opendaylight.neutron.networks.rev150712.networks.attributes.networks.Network network, java.lang.Class<T> networkType)
-
isUuid
public static boolean isUuid(java.lang.String possibleUuid)
-
getVpnMapRouterIdsListUuid
public static @NonNull java.util.List<org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.Uuid> getVpnMapRouterIdsListUuid(@Nullable java.util.List<RouterIds> routerIds)
-
-