diff options
author | 2020-01-30 12:08:35 +0100 | |
---|---|---|
committer | 2020-02-01 12:42:06 +0000 | |
commit | 149a57edf72762c7e0eb4062851c06356e6a75ab (patch) | |
tree | 0f6bf0087a2a82c637bb249ab09561f58202b969 /sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5 | |
parent | 8fb01420d6e5b5c3284da57292e28ce40874aaf4 (diff) |
SDN-R add updated devicemanager
add updated devicemanager and specific devicemanagers
Issue-ID: SDNC-1039
Signed-off-by: herbert <herbert.eiselt@highstreet-technologies.com>
Change-Id: I16f4c8d78da95ab12dbb50e50dfb561a85e8d6a2
Signed-off-by: herbert <herbert.eiselt@highstreet-technologies.com>
Diffstat (limited to 'sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5')
85 files changed, 6905 insertions, 0 deletions
diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModelBindingProvider.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModelBindingProvider.java new file mode 100644 index 000000000..925890b1a --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModelBindingProvider.java @@ -0,0 +1,8 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.top.rev180731; + +public final class $YangModelBindingProvider implements org.opendaylight.yangtools.yang.binding.YangModelBindingProvider { + @java.lang.Override + public org.opendaylight.yangtools.yang.binding.YangModuleInfo getModuleInfo() { + return $YangModuleInfoImpl.getInstance(); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModuleInfoImpl.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModuleInfoImpl.java new file mode 100644 index 000000000..7b43064b7 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/$YangModuleInfoImpl.java @@ -0,0 +1,46 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.top.rev180731; + +import org.opendaylight.yangtools.yang.binding.ResourceYangModuleInfo; +import org.opendaylight.yangtools.yang.common.QName; +import org.opendaylight.yangtools.yang.binding.YangModuleInfo; +import java.util.Set; +import java.util.HashSet; +import com.google.common.collect.ImmutableSet; + +public final class $YangModuleInfoImpl extends ResourceYangModuleInfo { + private static final QName NAME = QName.create("urn:3gpp:tsg:sa5:nrm:Top", "2018-07-31", "_3gpp-common-top").intern(); + private static final YangModuleInfo INSTANCE = new $YangModuleInfoImpl(); + + private final Set<YangModuleInfo> importedModules; + + public static YangModuleInfo getInstance() { + return INSTANCE; + } + + public static QName qnameOf(final java.lang.String localName) { + return QName.create(NAME, localName).intern(); + } + + private $YangModuleInfoImpl() { + Set<YangModuleInfo> set = new HashSet<>(); + set.add(org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl.getInstance()); + importedModules = ImmutableSet.copyOf(set); + } + + @java.lang.Override + public QName getName() { + return NAME; + } + + @java.lang.Override + protected java.lang.String resourceName() { + return "/META-INF/yang/_3gpp-common-top@2018-07-31.yang"; + } + + @java.lang.Override + public Set<YangModuleInfo> getImportedModules() { + return importedModules; + } + + +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/TopGrp.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/TopGrp.java new file mode 100644 index 000000000..521651261 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/top/rev180731/TopGrp.java @@ -0,0 +1,45 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.top.rev180731; +import java.lang.String; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TDistinguishedName; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-top</b> + * <pre> + * grouping TopGrp { + * leaf objectClass { + * type string; + * } + * leaf id { + * type nrm-type:t_DistinguishedName; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-top/TopGrp</i> + * + */ +public interface TopGrp + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("TopGrp"); + + /** + * @return <code>java.lang.String</code> <code>objectClass</code>, or <code>null</code> if not present + */ + @Nullable String getObjectClass(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TDistinguishedName</code> <code>id</code>, or <code>null</code> if not present + */ + @Nullable TDistinguishedName getId(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModelBindingProvider.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModelBindingProvider.java new file mode 100644 index 000000000..9bfd8cb97 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModelBindingProvider.java @@ -0,0 +1,8 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; + +public final class $YangModelBindingProvider implements org.opendaylight.yangtools.yang.binding.YangModelBindingProvider { + @java.lang.Override + public org.opendaylight.yangtools.yang.binding.YangModuleInfo getModuleInfo() { + return $YangModuleInfoImpl.getInstance(); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModuleInfoImpl.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModuleInfoImpl.java new file mode 100644 index 000000000..7ad939ace --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/$YangModuleInfoImpl.java @@ -0,0 +1,47 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; + +import org.opendaylight.yangtools.yang.binding.ResourceYangModuleInfo; +import org.opendaylight.yangtools.yang.common.QName; +import org.opendaylight.yangtools.yang.binding.YangModuleInfo; +import java.util.Set; +import java.util.HashSet; +import com.google.common.collect.ImmutableSet; + +public final class $YangModuleInfoImpl extends ResourceYangModuleInfo { + private static final QName NAME = QName.create("urn:3gpp:tsg:sa5:nrm:types", "2018-07-31", "_3gpp-common-yang-types").intern(); + private static final YangModuleInfo INSTANCE = new $YangModuleInfoImpl(); + + private final Set<YangModuleInfo> importedModules; + + public static YangModuleInfo getInstance() { + return INSTANCE; + } + + public static QName qnameOf(final java.lang.String localName) { + return QName.create(NAME, localName).intern(); + } + + private $YangModuleInfoImpl() { + Set<YangModuleInfo> set = new HashSet<>(); + set.add(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.$YangModuleInfoImpl.getInstance()); + set.add(org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.$YangModuleInfoImpl.getInstance()); + importedModules = ImmutableSet.copyOf(set); + } + + @java.lang.Override + public QName getName() { + return NAME; + } + + @java.lang.Override + protected java.lang.String resourceName() { + return "/META-INF/yang/_3gpp-common-yang-types@2018-07-31.yang"; + } + + @java.lang.Override + public Set<YangModuleInfo> getImportedModules() { + return importedModules; + } + + +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/AMFIdentifier.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/AMFIdentifier.java new file mode 100644 index 000000000..6068ed2e8 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/AMFIdentifier.java @@ -0,0 +1,51 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping aMFIdentifier { + * leaf AMF-Region-id { + * type t_aMF-Region-id; + * } + * leaf AMF-Set-id { + * type t_aMF-Set-id; + * } + * leaf AMF-Pointer { + * type t_aMF-Pointer; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/aMFIdentifier</i> + * + */ +public interface AMFIdentifier + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("aMFIdentifier"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFRegionId</code> <code>aMFRegionId</code>, or <code>null</code> if not present + */ + @Nullable TAMFRegionId getAMFRegionId(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFSetId</code> <code>aMFSetId</code>, or <code>null</code> if not present + */ + @Nullable TAMFSetId getAMFSetId(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFPointer</code> <code>aMFPointer</code>, or <code>null</code> if not present + */ + @Nullable TAMFPointer getAMFPointer(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/BwpContext.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/BwpContext.java new file mode 100644 index 000000000..c9e052bdd --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/BwpContext.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum BwpContext implements Enumeration { + DL(0, "DL"), + + UL(1, "UL"), + + SUL(2, "SUL") + ; + + private static final Map<String, BwpContext> NAME_MAP; + private static final Map<Integer, BwpContext> VALUE_MAP; + + static { + final Builder<String, BwpContext> nb = ImmutableMap.builder(); + final Builder<Integer, BwpContext> vb = ImmutableMap.builder(); + for (BwpContext enumItem : BwpContext.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private BwpContext(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding BwpContext item, if present + * @throws NullPointerException if name is null + */ + public static Optional<BwpContext> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding BwpContext item, or null if no such item exists + */ + public static BwpContext forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DataSetId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DataSetId.java new file mode 100644 index 000000000..3585bfbad --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DataSetId.java @@ -0,0 +1,75 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum DataSetId implements Enumeration { + SUBSCRIPTION(0, "SUBSCRIPTION"), + + POLICY(1, "POLICY"), + + EXPOSURE(2, "EXPOSURE"), + + APPLICATION(3, "APPLICATION") + ; + + private static final Map<String, DataSetId> NAME_MAP; + private static final Map<Integer, DataSetId> VALUE_MAP; + + static { + final Builder<String, DataSetId> nb = ImmutableMap.builder(); + final Builder<Integer, DataSetId> vb = ImmutableMap.builder(); + for (DataSetId enumItem : DataSetId.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private DataSetId(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding DataSetId item, if present + * @throws NullPointerException if name is null + */ + public static Optional<DataSetId> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding DataSetId item, or null if no such item exists + */ + public static DataSetId forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DefaultNotificationSubscription.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DefaultNotificationSubscription.java new file mode 100644 index 000000000..969d5cb9e --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DefaultNotificationSubscription.java @@ -0,0 +1,60 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Uri; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping defaultNotificationSubscription { + * leaf notificationType { + * type NotificationType; + * } + * leaf callbackUri { + * type inet:uri; + * } + * leaf n1MessageClass { + * type N1MessageClass; + * } + * leaf n2InformationClass { + * type N2InformationClass; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/defaultNotificationSubscription</i> + * + */ +public interface DefaultNotificationSubscription + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("defaultNotificationSubscription"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.NotificationType</code> <code>notificationType</code>, or <code>null</code> if not present + */ + @Nullable NotificationType getNotificationType(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Uri</code> <code>callbackUri</code>, or <code>null</code> if not present + */ + @Nullable Uri getCallbackUri(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.N1MessageClass</code> <code>n1MessageClass</code>, or <code>null</code> if not present + */ + @Nullable N1MessageClass getN1MessageClass(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.N2InformationClass</code> <code>n2InformationClass</code>, or <code>null</code> if not present + */ + @Nullable N2InformationClass getN2InformationClass(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DnnUpfInfoItem.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DnnUpfInfoItem.java new file mode 100644 index 000000000..a21ffc13a --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/DnnUpfInfoItem.java @@ -0,0 +1,35 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping DnnUpfInfoItem { + * leaf dnn { + * type t_Dnn; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/DnnUpfInfoItem</i> + * + */ +public interface DnnUpfInfoItem + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("DnnUpfInfoItem"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TDnn</code> <code>dnn</code>, or <code>null</code> if not present + */ + @Nullable TDnn getDnn(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Guami.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Guami.java new file mode 100644 index 000000000..94a4ca1f3 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Guami.java @@ -0,0 +1,45 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami.AmfId; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami.PlmnId; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping Guami { + * container plmnId { + * uses pLMNId; + * } + * container amfId { + * uses aMFIdentifier; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Guami</i> + * + */ +public interface Guami + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("Guami"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami.PlmnId</code> <code>plmnId</code>, or <code>null</code> if not present + */ + @Nullable PlmnId getPlmnId(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami.AmfId</code> <code>amfId</code>, or <code>null</code> if not present + */ + @Nullable AmfId getAmfId(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IdentityRange.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IdentityRange.java new file mode 100644 index 000000000..4146a260e --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IdentityRange.java @@ -0,0 +1,52 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping IdentityRange { + * leaf start { + * type string; + * } + * leaf end { + * type string; + * } + * leaf pattern { + * type string; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/IdentityRange</i> + * + */ +public interface IdentityRange + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("IdentityRange"); + + /** + * @return <code>java.lang.String</code> <code>start</code>, or <code>null</code> if not present + */ + @Nullable String getStart(); + + /** + * @return <code>java.lang.String</code> <code>end</code>, or <code>null</code> if not present + */ + @Nullable String getEnd(); + + /** + * @return <code>java.lang.String</code> <code>pattern</code>, or <code>null</code> if not present + */ + @Nullable String getPattern(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/InterfaceUpfInfoItem.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/InterfaceUpfInfoItem.java new file mode 100644 index 000000000..a3a32e2f3 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/InterfaceUpfInfoItem.java @@ -0,0 +1,72 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping InterfaceUpfInfoItem { + * leaf interfaceType { + * type UPInterfaceType; + * } + * choice address { + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * case endpointFqdn { + * leaf endpointFqdn { + * type inet:domain-name; + * } + * } + * } + * leaf networkInstance { + * type string; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem</i> + * + */ +public interface InterfaceUpfInfoItem + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("InterfaceUpfInfoItem"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.UPInterfaceType</code> <code>interfaceType</code>, or <code>null</code> if not present + */ + @Nullable UPInterfaceType getInterfaceType(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address</code> <code>address</code>, or <code>null</code> if not present + */ + @Nullable Address getAddress(); + + /** + * @return <code>java.lang.String</code> <code>networkInstance</code>, or <code>null</code> if not present + */ + @Nullable String getNetworkInstance(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IpEndPoint.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IpEndPoint.java new file mode 100644 index 000000000..4853cc331 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IpEndPoint.java @@ -0,0 +1,67 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.Integer; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.Address; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping ipEndPoint { + * choice address { + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * } + * leaf transport { + * type t_TransportProtocol; + * } + * leaf port { + * type uint16; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/ipEndPoint</i> + * + */ +public interface IpEndPoint + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipEndPoint"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.Address</code> <code>address</code>, or <code>null</code> if not present + */ + @Nullable Address getAddress(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TTransportProtocol</code> <code>transport</code>, or <code>null</code> if not present + */ + @Nullable TTransportProtocol getTransport(); + + /** + * @return <code>java.lang.Integer</code> <code>port</code>, or <code>null</code> if not present + */ + @Nullable Integer getPort(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv4AddressRange.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv4AddressRange.java new file mode 100644 index 000000000..16848931d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv4AddressRange.java @@ -0,0 +1,44 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping Ipv4AddressRange { + * leaf start { + * type inet:ipv4-address; + * } + * leaf end { + * type inet:ipv4-address; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Ipv4AddressRange</i> + * + */ +public interface Ipv4AddressRange + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("Ipv4AddressRange"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address</code> <code>start</code>, or <code>null</code> if not present + */ + @Nullable Ipv4Address getStart(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address</code> <code>end</code>, or <code>null</code> if not present + */ + @Nullable Ipv4Address getEnd(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv6PrefixRange.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv6PrefixRange.java new file mode 100644 index 000000000..60bb7db7d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Ipv6PrefixRange.java @@ -0,0 +1,44 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping Ipv6PrefixRange { + * leaf start { + * type inet:ipv6-prefix; + * } + * leaf end { + * type inet:ipv6-prefix; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Ipv6PrefixRange</i> + * + */ +public interface Ipv6PrefixRange + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("Ipv6PrefixRange"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix</code> <code>start</code>, or <code>null</code> if not present + */ + @Nullable Ipv6Prefix getStart(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix</code> <code>end</code>, or <code>null</code> if not present + */ + @Nullable Ipv6Prefix getEnd(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IsInitialBwp.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IsInitialBwp.java new file mode 100644 index 000000000..7073ca517 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/IsInitialBwp.java @@ -0,0 +1,71 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum IsInitialBwp implements Enumeration { + INITIAL(0, "INITIAL"), + + OTHER(1, "OTHER") + ; + + private static final Map<String, IsInitialBwp> NAME_MAP; + private static final Map<Integer, IsInitialBwp> VALUE_MAP; + + static { + final Builder<String, IsInitialBwp> nb = ImmutableMap.builder(); + final Builder<Integer, IsInitialBwp> vb = ImmutableMap.builder(); + for (IsInitialBwp enumItem : IsInitialBwp.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private IsInitialBwp(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding IsInitialBwp item, if present + * @throws NullPointerException if name is null + */ + public static Optional<IsInitialBwp> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding IsInitialBwp item, or null if no such item exists + */ + public static IsInitialBwp forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N1MessageClass.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N1MessageClass.java new file mode 100644 index 000000000..f08c1015f --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N1MessageClass.java @@ -0,0 +1,75 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum N1MessageClass implements Enumeration { + _5GMM(0, "5GMM"), + + SM(1, "SM"), + + LPP(2, "LPP"), + + SMS(3, "SMS") + ; + + private static final Map<String, N1MessageClass> NAME_MAP; + private static final Map<Integer, N1MessageClass> VALUE_MAP; + + static { + final Builder<String, N1MessageClass> nb = ImmutableMap.builder(); + final Builder<Integer, N1MessageClass> vb = ImmutableMap.builder(); + for (N1MessageClass enumItem : N1MessageClass.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private N1MessageClass(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding N1MessageClass item, if present + * @throws NullPointerException if name is null + */ + public static Optional<N1MessageClass> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding N1MessageClass item, or null if no such item exists + */ + public static N1MessageClass forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N2InformationClass.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N2InformationClass.java new file mode 100644 index 000000000..8353780bc --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/N2InformationClass.java @@ -0,0 +1,77 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum N2InformationClass implements Enumeration { + SM(0, "SM"), + + NRPPa(1, "NRPPa"), + + PWS(2, "PWS"), + + PWSBCAL(3, "PWS-BCAL"), + + PWSRF(4, "PWS-RF") + ; + + private static final Map<String, N2InformationClass> NAME_MAP; + private static final Map<Integer, N2InformationClass> VALUE_MAP; + + static { + final Builder<String, N2InformationClass> nb = ImmutableMap.builder(); + final Builder<Integer, N2InformationClass> vb = ImmutableMap.builder(); + for (N2InformationClass enumItem : N2InformationClass.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private N2InformationClass(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding N2InformationClass item, if present + * @throws NullPointerException if name is null + */ + public static Optional<N2InformationClass> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding N2InformationClass item, or null if no such item exists + */ + public static N2InformationClass forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFServiceVersion.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFServiceVersion.java new file mode 100644 index 000000000..983cc5be7 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFServiceVersion.java @@ -0,0 +1,53 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.DateAndTime; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping NFServiceVersion { + * leaf apiVersionInUri { + * type string; + * } + * leaf apiFullVersion { + * type string; + * } + * leaf expiry { + * type yang:date-and-time; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/NFServiceVersion</i> + * + */ +public interface NFServiceVersion + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("NFServiceVersion"); + + /** + * @return <code>java.lang.String</code> <code>apiVersionInUri</code>, or <code>null</code> if not present + */ + @Nullable String getApiVersionInUri(); + + /** + * @return <code>java.lang.String</code> <code>apiFullVersion</code>, or <code>null</code> if not present + */ + @Nullable String getApiFullVersion(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.yang.types.rev130715.DateAndTime</code> <code>expiry</code>, or <code>null</code> if not present + */ + @Nullable DateAndTime getExpiry(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFStatus.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFStatus.java new file mode 100644 index 000000000..aa11f7135 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFStatus.java @@ -0,0 +1,71 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum NFStatus implements Enumeration { + REGISTERED(0, "REGISTERED"), + + SUSPENDED(1, "SUSPENDED") + ; + + private static final Map<String, NFStatus> NAME_MAP; + private static final Map<Integer, NFStatus> VALUE_MAP; + + static { + final Builder<String, NFStatus> nb = ImmutableMap.builder(); + final Builder<Integer, NFStatus> vb = ImmutableMap.builder(); + for (NFStatus enumItem : NFStatus.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private NFStatus(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding NFStatus item, if present + * @throws NullPointerException if name is null + */ + public static Optional<NFStatus> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding NFStatus item, or null if no such item exists + */ + public static NFStatus forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFType.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFType.java new file mode 100644 index 000000000..8789e4395 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NFType.java @@ -0,0 +1,107 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum NFType implements Enumeration { + NRF(0, "NRF"), + + UDM(1, "UDM"), + + AMF(2, "AMF"), + + SMF(3, "SMF"), + + AUSF(4, "AUSF"), + + NEF(5, "NEF"), + + PCF(6, "PCF"), + + SMSF(7, "SMSF"), + + NSSF(8, "NSSF"), + + UDR(9, "UDR"), + + LMF(10, "LMF"), + + GMLC(11, "GMLC"), + + _5GEIR(12, "5G_EIR"), + + SEPP(13, "SEPP"), + + UPF(14, "UPF"), + + N3IWF(15, "N3IWF"), + + AF(16, "AF"), + + UDSF(17, "UDSF"), + + BSF(18, "BSF"), + + CHF(19, "CHF") + ; + + private static final Map<String, NFType> NAME_MAP; + private static final Map<Integer, NFType> VALUE_MAP; + + static { + final Builder<String, NFType> nb = ImmutableMap.builder(); + final Builder<Integer, NFType> vb = ImmutableMap.builder(); + for (NFType enumItem : NFType.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private NFType(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding NFType item, if present + * @throws NullPointerException if name is null + */ + public static Optional<NFType> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding NFType item, or null if no such item exists + */ + public static NFType forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationEventType.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationEventType.java new file mode 100644 index 000000000..e0857a80d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationEventType.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum NotificationEventType implements Enumeration { + NFREGISTERED(0, "NF_REGISTERED"), + + NFDEREGISTERED(1, "NF_DEREGISTERED"), + + NFPROFILECHANGED(2, "NF_PROFILE_CHANGED") + ; + + private static final Map<String, NotificationEventType> NAME_MAP; + private static final Map<Integer, NotificationEventType> VALUE_MAP; + + static { + final Builder<String, NotificationEventType> nb = ImmutableMap.builder(); + final Builder<Integer, NotificationEventType> vb = ImmutableMap.builder(); + for (NotificationEventType enumItem : NotificationEventType.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private NotificationEventType(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding NotificationEventType item, if present + * @throws NullPointerException if name is null + */ + public static Optional<NotificationEventType> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding NotificationEventType item, or null if no such item exists + */ + public static NotificationEventType forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationType.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationType.java new file mode 100644 index 000000000..e78ba7b4d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/NotificationType.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum NotificationType implements Enumeration { + N1MESSAGES(0, "N1_MESSAGES"), + + N2INFORMATION(1, "N2_INFORMATION"), + + LOCATIONNOTIFICATION(2, "LOCATION_NOTIFICATION") + ; + + private static final Map<String, NotificationType> NAME_MAP; + private static final Map<Integer, NotificationType> VALUE_MAP; + + static { + final Builder<String, NotificationType> nb = ImmutableMap.builder(); + final Builder<Integer, NotificationType> vb = ImmutableMap.builder(); + for (NotificationType enumItem : NotificationType.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private NotificationType(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding NotificationType item, if present + * @throws NullPointerException if name is null + */ + public static Optional<NotificationType> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding NotificationType item, or null if no such item exists + */ + public static NotificationType forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/PLMNId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/PLMNId.java new file mode 100644 index 000000000..24bb8d6d5 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/PLMNId.java @@ -0,0 +1,55 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * A Public Land Mobile Network is uniquely identified by its PLMN identifier. + * PLMN-Id consists of Mobile Country Code (MCC) and Mobile Network Code (MNC). + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping pLMNId { + * leaf MCC { + * type t_mcc; + * } + * leaf MNC { + * type t_mnc; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/pLMNId</i> + * + */ +public interface PLMNId + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("pLMNId"); + + /** + * Mobile Country Code (MCC), consisting of three decimal digits.The MCC identifies + * uniquely the country of domicile of the mobile subscription. + * + * + * + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMcc</code> <code>mCC</code>, or <code>null</code> if not present + */ + @Nullable TMcc getMCC(); + + /** + * Mobile Network Code (MNC), consisting of two or three decimal digits.The MNC + * identifies the home PLMN of the mobile subscription. + * + * + * + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMnc</code> <code>mNC</code>, or <code>null</code> if not present + */ + @Nullable TMnc getMNC(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/QOffsetRange.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/QOffsetRange.java new file mode 100644 index 000000000..5854ab526 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/QOffsetRange.java @@ -0,0 +1,83 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.Short; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class QOffsetRange + implements TypeObject, Serializable { + private static final long serialVersionUID = 6398961204554971940L; + private final Short _value; + + private static void check_valueRange(final short value) { + if (value >= (short)0 && value <= (short)255) { + return; + } + CodeHelpers.throwInvalidRange("[[0..255]]", value); + } + + @ConstructorProperties("value") + public QOffsetRange(Short _value) { + if (_value != null) { + check_valueRange(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public QOffsetRange(QOffsetRange source) { + this._value = source._value; + } + + public static QOffsetRange getDefaultInstance(String defaultValue) { + return new QOffsetRange(Short.valueOf(defaultValue)); + } + + public Short getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + QOffsetRange other = (QOffsetRange) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(QOffsetRange.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/RRMPolicyRatio2.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/RRMPolicyRatio2.java new file mode 100644 index 000000000..5669971d9 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/RRMPolicyRatio2.java @@ -0,0 +1,86 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.Integer; +import java.lang.Short; +import java.util.List; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping RRMPolicyRatio2 { + * leaf groupId { + * type uint16; + * } + * leaf-list sNSSAI { + * type t_s-NSSAI; + * } + * leaf quotaType { + * type t_quotaType; + * } + * leaf rRMPolicyMaxRation { + * type uint8; + * } + * leaf rRMPolicyMarginMaxRation { + * type uint8; + * } + * leaf rRMPolicyMinRation { + * type uint8; + * } + * leaf rRMPolicyMarginMinRation { + * type uint8; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/RRMPolicyRatio2</i> + * + */ +public interface RRMPolicyRatio2 + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("RRMPolicyRatio2"); + + /** + * @return <code>java.lang.Integer</code> <code>groupId</code>, or <code>null</code> if not present + */ + @Nullable Integer getGroupId(); + + /** + * @return <code>java.util.List</code> <code>sNSSAI</code>, or <code>null</code> if not present + */ + @Nullable List<TSNSSAI> getSNSSAI(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TQuotaType</code> <code>quotaType</code>, or <code>null</code> if not present + */ + @Nullable TQuotaType getQuotaType(); + + /** + * @return <code>java.lang.Short</code> <code>rRMPolicyMaxRation</code>, or <code>null</code> if not present + */ + @Nullable Short getRRMPolicyMaxRation(); + + /** + * @return <code>java.lang.Short</code> <code>rRMPolicyMarginMaxRation</code>, or <code>null</code> if not present + */ + @Nullable Short getRRMPolicyMarginMaxRation(); + + /** + * @return <code>java.lang.Short</code> <code>rRMPolicyMinRation</code>, or <code>null</code> if not present + */ + @Nullable Short getRRMPolicyMinRation(); + + /** + * @return <code>java.lang.Short</code> <code>rRMPolicyMarginMinRation</code>, or <code>null</code> if not present + */ + @Nullable Short getRRMPolicyMarginMinRation(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SnssaiUpfInfoItem.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SnssaiUpfInfoItem.java new file mode 100644 index 000000000..04f47b0f4 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SnssaiUpfInfoItem.java @@ -0,0 +1,55 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.util.List; +import org.eclipse.jdt.annotation.NonNull; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.snssaiupfinfoitem.DnnUpfInfo; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping SnssaiUpfInfoItem { + * leaf sNssai { + * type t_s-NSSAI; + * } + * list dnnUpfInfo { + * key dnn; + * uses DnnUpfInfoItem; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/SnssaiUpfInfoItem</i> + * + */ +public interface SnssaiUpfInfoItem + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("SnssaiUpfInfoItem"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TSNSSAI</code> <code>sNssai</code>, or <code>null</code> if not present + */ + @Nullable TSNSSAI getSNssai(); + + /** + * @return <code>java.util.List</code> <code>dnnUpfInfo</code>, or <code>null</code> if not present + */ + @Nullable List<DnnUpfInfo> getDnnUpfInfo(); + + /** + * @return <code>java.util.List</code> <code>dnnUpfInfo</code>, or an empty list if it is not present + */ + default @NonNull List<DnnUpfInfo> nonnullDnnUpfInfo() { + return CodeHelpers.nonnull(getDnnUpfInfo()); + } + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupiRange.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupiRange.java new file mode 100644 index 000000000..e959fcaad --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupiRange.java @@ -0,0 +1,52 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping SupiRange { + * leaf start { + * type string; + * } + * leaf end { + * type string; + * } + * leaf pattern { + * type string; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/SupiRange</i> + * + */ +public interface SupiRange + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("SupiRange"); + + /** + * @return <code>java.lang.String</code> <code>start</code>, or <code>null</code> if not present + */ + @Nullable String getStart(); + + /** + * @return <code>java.lang.String</code> <code>end</code>, or <code>null</code> if not present + */ + @Nullable String getEnd(); + + /** + * @return <code>java.lang.String</code> <code>pattern</code>, or <code>null</code> if not present + */ + @Nullable String getPattern(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupportedFeatures.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupportedFeatures.java new file mode 100644 index 000000000..dec0ed6c6 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/SupportedFeatures.java @@ -0,0 +1,85 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class SupportedFeatures + implements TypeObject, Serializable { + private static final long serialVersionUID = 237085469237900179L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[A-Fa-f0-9]*)$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[A-Fa-f0-9]*"; + private final String _value; + + private static void check_valueLength(final String value) { + } + + @ConstructorProperties("value") + public SupportedFeatures(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public SupportedFeatures(SupportedFeatures source) { + this._value = source._value; + } + + public static SupportedFeatures getDefaultInstance(String defaultValue) { + return new SupportedFeatures(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + SupportedFeatures other = (SupportedFeatures) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(SupportedFeatures.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFPointer.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFPointer.java new file mode 100644 index 000000000..05ec3a321 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFPointer.java @@ -0,0 +1,90 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TAMFPointer + implements TypeObject, Serializable { + private static final long serialVersionUID = -7925647994457565082L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[01]*)$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[01]*"; + private final String _value; + + private static void check_valueLength(final String value) { + final int length = value.length(); + if (length == 6) { + return; + } + CodeHelpers.throwInvalidLength("[[6..6]]", value); + } + + @ConstructorProperties("value") + public TAMFPointer(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TAMFPointer(TAMFPointer source) { + this._value = source._value; + } + + public static TAMFPointer getDefaultInstance(String defaultValue) { + return new TAMFPointer(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TAMFPointer other = (TAMFPointer) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TAMFPointer.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFRegionId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFRegionId.java new file mode 100644 index 000000000..bb70b4fc4 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFRegionId.java @@ -0,0 +1,90 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TAMFRegionId + implements TypeObject, Serializable { + private static final long serialVersionUID = -4812289071560773109L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[01]*)$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[01]*"; + private final String _value; + + private static void check_valueLength(final String value) { + final int length = value.length(); + if (length == 8) { + return; + } + CodeHelpers.throwInvalidLength("[[8..8]]", value); + } + + @ConstructorProperties("value") + public TAMFRegionId(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TAMFRegionId(TAMFRegionId source) { + this._value = source._value; + } + + public static TAMFRegionId getDefaultInstance(String defaultValue) { + return new TAMFRegionId(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TAMFRegionId other = (TAMFRegionId) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TAMFRegionId.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFSetId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFSetId.java new file mode 100644 index 000000000..6ecd82e95 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAMFSetId.java @@ -0,0 +1,90 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TAMFSetId + implements TypeObject, Serializable { + private static final long serialVersionUID = 6265848852591033404L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[01]*)$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[01]*"; + private final String _value; + + private static void check_valueLength(final String value) { + final int length = value.length(); + if (length == 10) { + return; + } + CodeHelpers.throwInvalidLength("[[10..10]]", value); + } + + @ConstructorProperties("value") + public TAMFSetId(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TAMFSetId(TAMFSetId source) { + this._value = source._value; + } + + public static TAMFSetId getDefaultInstance(String defaultValue) { + return new TAMFSetId(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TAMFSetId other = (TAMFSetId) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TAMFSetId.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAdministrativeState.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAdministrativeState.java new file mode 100644 index 000000000..2838c3c5c --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAdministrativeState.java @@ -0,0 +1,89 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TAdministrativeState implements Enumeration { + /** + * The resource is administratively prohibited from performingservices for its + * users. + * + */ + Locked(0, "Locked"), + + /** + * Use of the resource is administratively permitted to existinginstances of use + * only. While the system remains in the shutting down statethe manager may at any + * time cause the managed object to revert to theunlocked state. + * + */ + Shutdown(1, "Shutdown"), + + /** + * The resource is administratively permitted to perform services forits users. + * This is independent of its inherent operability. + * + */ + Unlocked(2, "Unlocked") + ; + + private static final Map<String, TAdministrativeState> NAME_MAP; + private static final Map<Integer, TAdministrativeState> VALUE_MAP; + + static { + final Builder<String, TAdministrativeState> nb = ImmutableMap.builder(); + final Builder<Integer, TAdministrativeState> vb = ImmutableMap.builder(); + for (TAdministrativeState enumItem : TAdministrativeState.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TAdministrativeState(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TAdministrativeState item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TAdministrativeState> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TAdministrativeState item, or null if no such item exists + */ + public static TAdministrativeState forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAvailabilityStatus.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAvailabilityStatus.java new file mode 100644 index 000000000..d86f68880 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TAvailabilityStatus.java @@ -0,0 +1,147 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TAvailabilityStatus implements Enumeration { + /** + * The resource is undergoing a test procedure. If the administrativestate is + * locked or shutting down then normal users are precluded from usingthe resource + * and the control status attribute has the value reserved for test.Tests that do + * not exclude additional users can be present in any operationalor administrative + * state but the reserved for test condition should not bepresent. + * + */ + INTEST(0, "IN TEST"), + + /** + * The resource has an internal fault that prevents it from operating.The + * operational state is disabled. + * + */ + FAILED(1, "FAILED"), + + /** + * The resource requires power to be applied and is not powered on.For example, a + * fuse or other protection device is known to have removedpower or a low voltage + * condition has been detected. The operational stateis disabled. + * + */ + POWEROFF(2, "POWER OFF"), + + /** + * The resource requires a routine operation to be performed to placeit online and + * make it available for use. The operation may be manual orautomatic, or both. The + * operational state is disabled. + * + */ + OFFLINE(3, "OFF LINE"), + + /** + * The resource has been made inactive by an internal control processin accordance + * with a predetermined time schedule. Under normal conditionsthe control process + * can be expected to reactivate the resource at somescheduled time, and it is + * therefore considered to be optional. Theoperational state is enabled or + * disabled. + * + */ + OFFDUTY(4, "OFF DUTY"), + + /** + * The resource cannot operate because some other resource on which itdepends is + * (i.e. a resource not represented by the same managed object)unavailable. For + * example, a device is not accessible because its controlleris powered off. The + * operational state is disabled. + * + */ + DEPENDENCY(5, "DEPENDENCY"), + + /** + * The service available from the resource is degraded in some respect,such as in + * speed or operating capacity. Failure of a test or an unacceptableperformance + * measurement has established that some or all services are notfunctional or are + * degraded due to the presence of a defect. However, theresource remains available + * for service, either because some services aresatisfactory or because degraded + * service is preferable to no service at all.Object specific attributes may be + * defined to represent further informationindicating, for example, which services + * are not functional and the nature ofthe degradation. The operational state is + * enabled. + * + */ + DEGRADED(6, "DEGRADED"), + + /** + * The resource represented by the managed object is not present, or isincomplete. + * For example, a plug-in module is missing, a cable is disconnectedor a software + * module is not loaded. The operational state is disabled. + * + */ + NOTINSTALLED(7, "NOT INSTALLED"), + + /** + * This indicates a log full condition. + * + */ + LOGFULL(8, "LOG FULL") + ; + + private static final Map<String, TAvailabilityStatus> NAME_MAP; + private static final Map<Integer, TAvailabilityStatus> VALUE_MAP; + + static { + final Builder<String, TAvailabilityStatus> nb = ImmutableMap.builder(); + final Builder<Integer, TAvailabilityStatus> vb = ImmutableMap.builder(); + for (TAvailabilityStatus enumItem : TAvailabilityStatus.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TAvailabilityStatus(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TAvailabilityStatus item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TAvailabilityStatus> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TAvailabilityStatus item, or null if no such item exists + */ + public static TAvailabilityStatus forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCellState.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCellState.java new file mode 100644 index 000000000..0082d6c4b --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCellState.java @@ -0,0 +1,85 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TCellState implements Enumeration { + /** + * The resource is not currently in use. + * + */ + Idle(0, "Idle"), + + /** + * The resource is not available for use. + * + */ + Inactive(1, "Inactive"), + + /** + * The resource is in use. + * + */ + Active(2, "Active") + ; + + private static final Map<String, TCellState> NAME_MAP; + private static final Map<Integer, TCellState> VALUE_MAP; + + static { + final Builder<String, TCellState> nb = ImmutableMap.builder(); + final Builder<Integer, TCellState> vb = ImmutableMap.builder(); + for (TCellState enumItem : TCellState.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TCellState(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TCellState item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TCellState> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TCellState item, or null if no such item exists + */ + public static TCellState forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCyclicPrefix.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCyclicPrefix.java new file mode 100644 index 000000000..e8b2f3fed --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TCyclicPrefix.java @@ -0,0 +1,71 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TCyclicPrefix implements Enumeration { + Normal(0, "Normal"), + + Extended(1, "Extended") + ; + + private static final Map<String, TCyclicPrefix> NAME_MAP; + private static final Map<Integer, TCyclicPrefix> VALUE_MAP; + + static { + final Builder<String, TCyclicPrefix> nb = ImmutableMap.builder(); + final Builder<Integer, TCyclicPrefix> vb = ImmutableMap.builder(); + for (TCyclicPrefix enumItem : TCyclicPrefix.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TCyclicPrefix(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TCyclicPrefix item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TCyclicPrefix> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TCyclicPrefix item, or null if no such item exists + */ + public static TCyclicPrefix forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDistinguishedName.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDistinguishedName.java new file mode 100644 index 000000000..fbf1a49d1 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDistinguishedName.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TDistinguishedName + implements TypeObject, Serializable { + private static final long serialVersionUID = 2209417379079206418L; + private final String _value; + + + @ConstructorProperties("value") + public TDistinguishedName(String _value) { + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TDistinguishedName(TDistinguishedName source) { + this._value = source._value; + } + + public static TDistinguishedName getDefaultInstance(String defaultValue) { + return new TDistinguishedName(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TDistinguishedName other = (TDistinguishedName) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TDistinguishedName.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDnn.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDnn.java new file mode 100644 index 000000000..b7d485793 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TDnn.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TDnn + implements TypeObject, Serializable { + private static final long serialVersionUID = -6761478371390250952L; + private final String _value; + + + @ConstructorProperties("value") + public TDnn(String _value) { + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TDnn(TDnn source) { + this._value = source._value; + } + + public static TDnn getDefaultInstance(String defaultValue) { + return new TDnn(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TDnn other = (TDnn) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TDnn.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TLoad.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TLoad.java new file mode 100644 index 000000000..65038cb7d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TLoad.java @@ -0,0 +1,83 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.Short; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TLoad + implements TypeObject, Serializable { + private static final long serialVersionUID = -1391841480548249841L; + private final Short _value; + + private static void check_valueRange(final short value) { + if (value >= (short)0 && value <= (short)100) { + return; + } + CodeHelpers.throwInvalidRange("[[0..100]]", value); + } + + @ConstructorProperties("value") + public TLoad(Short _value) { + if (_value != null) { + check_valueRange(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TLoad(TLoad source) { + this._value = source._value; + } + + public static TLoad getDefaultInstance(String defaultValue) { + return new TLoad(Short.valueOf(defaultValue)); + } + + public Short getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TLoad other = (TLoad) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TLoad.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMcc.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMcc.java new file mode 100644 index 000000000..a5d32a30b --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMcc.java @@ -0,0 +1,85 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TMcc + implements TypeObject, Serializable { + private static final long serialVersionUID = 8336530756398858673L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[02-79][0-9][0-9])$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[02-79][0-9][0-9]"; + private final String _value; + + private static void check_valueLength(final String value) { + } + + @ConstructorProperties("value") + public TMcc(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TMcc(TMcc source) { + this._value = source._value; + } + + public static TMcc getDefaultInstance(String defaultValue) { + return new TMcc(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TMcc other = (TMcc) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TMcc.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMnc.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMnc.java new file mode 100644 index 000000000..d5de22dfe --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TMnc.java @@ -0,0 +1,85 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TMnc + implements TypeObject, Serializable { + private static final long serialVersionUID = 7207647705509368021L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[0-9][0-9][0-9]|[0-9][0-9])$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[0-9][0-9][0-9]|[0-9][0-9]"; + private final String _value; + + private static void check_valueLength(final String value) { + } + + @ConstructorProperties("value") + public TMnc(String _value) { + if (_value != null) { + check_valueLength(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + CodeHelpers.checkPattern(_value, patterns, regexes); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TMnc(TMnc source) { + this._value = source._value; + } + + public static TMnc getDefaultInstance(String defaultValue) { + return new TMnc(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TMnc other = (TMnc) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TMnc.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCI.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCI.java new file mode 100644 index 000000000..e7786506f --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCI.java @@ -0,0 +1,93 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TNCI + implements TypeObject, Serializable { + private static final long serialVersionUID = 6536694555014033331L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[01]*)$", "^(?:[a-fA-F0-9]*)$"); + private static final Pattern[] patterns = CodeHelpers.compilePatterns(PATTERN_CONSTANTS); + private static final String[] regexes = { "[01]*", "[a-fA-F0-9]*" }; + private final String _string; + + + private static void check_stringLength(final String value) { + final int length = value.length(); + if (length == 36) { + return; + } + CodeHelpers.throwInvalidLength("[[36..36]]", value); + } + public TNCI(String _string) { + super(); + check_stringLength(_string); + + this._string = _string; + } + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TNCI(TNCI source) { + this._string = source._string; + } + + /** + * Return a String representing the value of this union. + * + * @return String representation of this union's value. + */ + public String stringValue() { + if (_string != null) { + return _string; + } + + throw new IllegalStateException("No value assinged"); + } + + + public String getString() { + return _string; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_string); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TNCI other = (TNCI) obj; + if (!Objects.equals(_string, other._string)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TNCI.class); + CodeHelpers.appendValue(helper, "_string", _string); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCIBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCIBuilder.java new file mode 100644 index 000000000..3c8462dd0 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNCIBuilder.java @@ -0,0 +1,23 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import java.lang.UnsupportedOperationException; + +/** + * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation. + * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32). + * + * The reason behind putting it under src/main/java is: + * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent + * loss of user code. + * + */ +public class TNCIBuilder { + private TNCIBuilder() { + //Exists only to defeat instantiation. + } + + public static TNCI getDefaultInstance(String defaultValue) { + throw new UnsupportedOperationException("Not yet implemented"); + } + +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNRPCI.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNRPCI.java new file mode 100644 index 000000000..72a8400ba --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNRPCI.java @@ -0,0 +1,83 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Long; +import java.lang.Override; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TNRPCI + implements TypeObject, Serializable { + private static final long serialVersionUID = -8223745380422869872L; + private final Long _value; + + private static void check_valueRange(final long value) { + if (value >= 0L && value <= 4294967295L) { + return; + } + CodeHelpers.throwInvalidRange("[[0..4294967295]]", value); + } + + @ConstructorProperties("value") + public TNRPCI(Long _value) { + if (_value != null) { + check_valueRange(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TNRPCI(TNRPCI source) { + this._value = source._value; + } + + public static TNRPCI getDefaultInstance(String defaultValue) { + return new TNRPCI(Long.valueOf(defaultValue)); + } + + public Long getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TNRPCI other = (TNRPCI) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TNRPCI.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNsiId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNsiId.java new file mode 100644 index 000000000..1ae6f3c02 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TNsiId.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TNsiId + implements TypeObject, Serializable { + private static final long serialVersionUID = 5629408106052088513L; + private final String _value; + + + @ConstructorProperties("value") + public TNsiId(String _value) { + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TNsiId(TNsiId source) { + this._value = source._value; + } + + public static TNsiId getDefaultInstance(String defaultValue) { + return new TNsiId(defaultValue); + } + + public String getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TNsiId other = (TNsiId) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TNsiId.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TOperationalState.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TOperationalState.java new file mode 100644 index 000000000..8aae8b46d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TOperationalState.java @@ -0,0 +1,79 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TOperationalState implements Enumeration { + /** + * The resource is partially or fully operable and available for use. + * + */ + Enabled(0, "Enabled"), + + /** + * The resource is totally inoperable and unable to provide serviceto the user(s). + * + */ + Disabled(1, "Disabled") + ; + + private static final Map<String, TOperationalState> NAME_MAP; + private static final Map<Integer, TOperationalState> VALUE_MAP; + + static { + final Builder<String, TOperationalState> nb = ImmutableMap.builder(); + final Builder<Integer, TOperationalState> vb = ImmutableMap.builder(); + for (TOperationalState enumItem : TOperationalState.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TOperationalState(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TOperationalState item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TOperationalState> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TOperationalState item, or null if no such item exists + */ + public static TOperationalState forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TQuotaType.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TQuotaType.java new file mode 100644 index 000000000..2b66b0cbf --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TQuotaType.java @@ -0,0 +1,71 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TQuotaType implements Enumeration { + Strict(0, "strict"), + + Float(1, "float") + ; + + private static final Map<String, TQuotaType> NAME_MAP; + private static final Map<Integer, TQuotaType> VALUE_MAP; + + static { + final Builder<String, TQuotaType> nb = ImmutableMap.builder(); + final Builder<Integer, TQuotaType> vb = ImmutableMap.builder(); + for (TQuotaType enumItem : TQuotaType.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TQuotaType(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TQuotaType item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TQuotaType> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TQuotaType item, or null if no such item exists + */ + public static TQuotaType forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TResourceSharingLevel.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TResourceSharingLevel.java new file mode 100644 index 000000000..ea8eca6ec --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TResourceSharingLevel.java @@ -0,0 +1,71 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TResourceSharingLevel implements Enumeration { + Shared(0, "shared"), + + NotShared(1, "not-shared") + ; + + private static final Map<String, TResourceSharingLevel> NAME_MAP; + private static final Map<Integer, TResourceSharingLevel> VALUE_MAP; + + static { + final Builder<String, TResourceSharingLevel> nb = ImmutableMap.builder(); + final Builder<Integer, TResourceSharingLevel> vb = ImmutableMap.builder(); + for (TResourceSharingLevel enumItem : TResourceSharingLevel.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TResourceSharingLevel(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TResourceSharingLevel item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TResourceSharingLevel> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TResourceSharingLevel item, or null if no such item exists + */ + public static TResourceSharingLevel forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAI.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAI.java new file mode 100644 index 000000000..09cf3522e --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAI.java @@ -0,0 +1,120 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.io.Serializable; +import java.lang.Long; +import java.lang.Override; +import java.lang.Short; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TSNSSAI + implements TypeObject, Serializable { + private static final long serialVersionUID = -2943261658086489871L; + private final Short _uint8; + private final Long _uint32; + + + private static void checkUint8Range(final short value) { + if (value >= (short)0 && value <= (short)255) { + return; + } + CodeHelpers.throwInvalidRange("[[0..255]]", value); + } + public TSNSSAI(Short _uint8) { + super(); + checkUint8Range(_uint8); + + this._uint8 = _uint8; + this._uint32 = null; + } + + private static void checkUint32Range(final long value) { + if (value >= 0L && value <= 4294967295L) { + return; + } + CodeHelpers.throwInvalidRange("[[0..4294967295]]", value); + } + public TSNSSAI(Long _uint32) { + super(); + checkUint32Range(_uint32); + + this._uint32 = _uint32; + this._uint8 = null; + } + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TSNSSAI(TSNSSAI source) { + this._uint8 = source._uint8; + this._uint32 = source._uint32; + } + + /** + * Return a String representing the value of this union. + * + * @return String representation of this union's value. + */ + public String stringValue() { + if (_uint8 != null) { + return _uint8.toString(); + } + if (_uint32 != null) { + return _uint32.toString(); + } + + throw new IllegalStateException("No value assinged"); + } + + + public Short getUint8() { + return _uint8; + } + + public Long getUint32() { + return _uint32; + } + + + @Override + public int hashCode() { + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_uint8); + result = prime * result + Objects.hashCode(_uint32); + return result; + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TSNSSAI other = (TSNSSAI) obj; + if (!Objects.equals(_uint8, other._uint8)) { + return false; + } + if (!Objects.equals(_uint32, other._uint32)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TSNSSAI.class); + CodeHelpers.appendValue(helper, "_uint8", _uint8); + CodeHelpers.appendValue(helper, "_uint32", _uint32); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAIBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAIBuilder.java new file mode 100644 index 000000000..b0d11a747 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSNSSAIBuilder.java @@ -0,0 +1,23 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import java.lang.UnsupportedOperationException; + +/** + * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation. + * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32). + * + * The reason behind putting it under src/main/java is: + * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent + * loss of user code. + * + */ +public class TSNSSAIBuilder { + private TSNSSAIBuilder() { + //Exists only to defeat instantiation. + } + + public static TSNSSAI getDefaultInstance(String defaultValue) { + throw new UnsupportedOperationException("Not yet implemented"); + } + +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSST.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSST.java new file mode 100644 index 000000000..1045aa995 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSST.java @@ -0,0 +1,83 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import java.beans.ConstructorProperties; +import java.io.Serializable; +import java.lang.Override; +import java.lang.Short; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TSST + implements TypeObject, Serializable { + private static final long serialVersionUID = -2844923602415446951L; + private final Short _value; + + private static void check_valueRange(final short value) { + if (value >= (short)0 && value <= (short)255) { + return; + } + CodeHelpers.throwInvalidRange("[[0..255]]", value); + } + + @ConstructorProperties("value") + public TSST(Short _value) { + if (_value != null) { + check_valueRange(_value); + } + + Objects.requireNonNull(_value, "Supplied value may not be null"); + + this._value = _value; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TSST(TSST source) { + this._value = source._value; + } + + public static TSST getDefaultInstance(String defaultValue) { + return new TSST(Short.valueOf(defaultValue)); + } + + public Short getValue() { + return _value; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_value); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TSST other = (TSST) obj; + if (!Objects.equals(_value, other._value)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TSST.class); + CodeHelpers.appendValue(helper, "_value", _value); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSubcarrierSpacing.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSubcarrierSpacing.java new file mode 100644 index 000000000..49124021e --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TSubcarrierSpacing.java @@ -0,0 +1,75 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TSubcarrierSpacing implements Enumeration { + _15(0, "15"), + + _30(1, "30"), + + _60(2, "60"), + + _120(3, "120") + ; + + private static final Map<String, TSubcarrierSpacing> NAME_MAP; + private static final Map<Integer, TSubcarrierSpacing> VALUE_MAP; + + static { + final Builder<String, TSubcarrierSpacing> nb = ImmutableMap.builder(); + final Builder<Integer, TSubcarrierSpacing> vb = ImmutableMap.builder(); + for (TSubcarrierSpacing enumItem : TSubcarrierSpacing.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TSubcarrierSpacing(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TSubcarrierSpacing item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TSubcarrierSpacing> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TSubcarrierSpacing item, or null if no such item exists + */ + public static TSubcarrierSpacing forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTAC.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTAC.java new file mode 100644 index 000000000..f85c972b7 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTAC.java @@ -0,0 +1,93 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableList; +import java.io.Serializable; +import java.lang.Override; +import java.lang.String; +import java.util.List; +import java.util.Objects; +import java.util.regex.Pattern; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.TypeObject; + +public class TTAC + implements TypeObject, Serializable { + private static final long serialVersionUID = -7663797870532797015L; + public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[a-fA-F0-9]*)$"); + private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0)); + private static final String regexes = "[a-fA-F0-9]*"; + private final String _string; + + + private static void check_stringLength(final String value) { + final int length = value.length(); + if (length == 4) { + return; + } + CodeHelpers.throwInvalidLength("[[4..4]]", value); + } + public TTAC(String _string) { + super(); + check_stringLength(_string); + + this._string = _string; + } + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public TTAC(TTAC source) { + this._string = source._string; + } + + /** + * Return a String representing the value of this union. + * + * @return String representation of this union's value. + */ + public String stringValue() { + if (_string != null) { + return _string; + } + + throw new IllegalStateException("No value assinged"); + } + + + public String getString() { + return _string; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_string); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + TTAC other = (TTAC) obj; + if (!Objects.equals(_string, other._string)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TTAC.class); + CodeHelpers.appendValue(helper, "_string", _string); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTACBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTACBuilder.java new file mode 100644 index 000000000..e9aba2668 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTACBuilder.java @@ -0,0 +1,23 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import java.lang.String; +import java.lang.UnsupportedOperationException; + +/** + * The purpose of generated class in src/main/java for Union types is to create new instances of unions from a string representation. + * In some cases it is very difficult to automate it since there can be unions such as (uint32 - uint16), or (string - uint32). + * + * The reason behind putting it under src/main/java is: + * This class is generated in form of a stub and needs to be finished by the user. This class is generated only once to prevent + * loss of user code. + * + */ +public class TTACBuilder { + private TTACBuilder() { + //Exists only to defeat instantiation. + } + + public static TTAC getDefaultInstance(String defaultValue) { + throw new UnsupportedOperationException("Not yet implemented"); + } + +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTransportProtocol.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTransportProtocol.java new file mode 100644 index 000000000..bfdf26cc1 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TTransportProtocol.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TTransportProtocol implements Enumeration { + TCP(0, "TCP"), + + STCP(1, "STCP"), + + UDP(2, "UDP") + ; + + private static final Map<String, TTransportProtocol> NAME_MAP; + private static final Map<Integer, TTransportProtocol> VALUE_MAP; + + static { + final Builder<String, TTransportProtocol> nb = ImmutableMap.builder(); + final Builder<Integer, TTransportProtocol> vb = ImmutableMap.builder(); + for (TTransportProtocol enumItem : TTransportProtocol.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TTransportProtocol(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TTransportProtocol item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TTransportProtocol> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TTransportProtocol item, or null if no such item exists + */ + public static TTransportProtocol forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TUEMobilityLevel.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TUEMobilityLevel.java new file mode 100644 index 000000000..96aa56c07 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TUEMobilityLevel.java @@ -0,0 +1,75 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TUEMobilityLevel implements Enumeration { + Stationary(0, "stationary"), + + Nomadic(1, "nomadic"), + + RestrictedMobility(2, "restricted mobility"), + + FullyMobility(3, "fully mobility") + ; + + private static final Map<String, TUEMobilityLevel> NAME_MAP; + private static final Map<Integer, TUEMobilityLevel> VALUE_MAP; + + static { + final Builder<String, TUEMobilityLevel> nb = ImmutableMap.builder(); + final Builder<Integer, TUEMobilityLevel> vb = ImmutableMap.builder(); + for (TUEMobilityLevel enumItem : TUEMobilityLevel.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TUEMobilityLevel(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TUEMobilityLevel item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TUEMobilityLevel> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TUEMobilityLevel item, or null if no such item exists + */ + public static TUEMobilityLevel forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Tai.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Tai.java new file mode 100644 index 000000000..325f70a66 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/Tai.java @@ -0,0 +1,44 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.tai.PlmnId; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * grouping Tai { + * container plmnId { + * uses pLMNId; + * } + * leaf tac { + * type t_tAC; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Tai</i> + * + */ +public interface Tai + extends + DataObject +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("Tai"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.tai.PlmnId</code> <code>plmnId</code>, or <code>null</code> if not present + */ + @Nullable PlmnId getPlmnId(); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TTAC</code> <code>tac</code>, or <code>null</code> if not present + */ + @Nullable TTAC getTac(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TxDirection.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TxDirection.java new file mode 100644 index 000000000..a02cee620 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/TxDirection.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum TxDirection implements Enumeration { + DL(0, "DL"), + + UL(1, "UL"), + + DLAndUL(2, "DL and UL") + ; + + private static final Map<String, TxDirection> NAME_MAP; + private static final Map<Integer, TxDirection> VALUE_MAP; + + static { + final Builder<String, TxDirection> nb = ImmutableMap.builder(); + final Builder<Integer, TxDirection> vb = ImmutableMap.builder(); + for (TxDirection enumItem : TxDirection.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private TxDirection(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding TxDirection item, if present + * @throws NullPointerException if name is null + */ + public static Optional<TxDirection> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding TxDirection item, or null if no such item exists + */ + public static TxDirection forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/UPInterfaceType.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/UPInterfaceType.java new file mode 100644 index 000000000..bdcf43aee --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/UPInterfaceType.java @@ -0,0 +1,73 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731; +import com.google.common.collect.ImmutableMap; +import com.google.common.collect.ImmutableMap.Builder; +import java.lang.Integer; +import java.lang.Override; +import java.lang.String; +import java.util.Map; +import java.util.Objects; +import java.util.Optional; +import org.opendaylight.yangtools.yang.binding.Enumeration; + +public enum UPInterfaceType implements Enumeration { + N3(0, "N3"), + + N6(1, "N6"), + + N9(2, "N9") + ; + + private static final Map<String, UPInterfaceType> NAME_MAP; + private static final Map<Integer, UPInterfaceType> VALUE_MAP; + + static { + final Builder<String, UPInterfaceType> nb = ImmutableMap.builder(); + final Builder<Integer, UPInterfaceType> vb = ImmutableMap.builder(); + for (UPInterfaceType enumItem : UPInterfaceType.values()) { + vb.put(enumItem.value, enumItem); + nb.put(enumItem.name, enumItem); + } + + NAME_MAP = nb.build(); + VALUE_MAP = vb.build(); + } + + private final String name; + private final int value; + + private UPInterfaceType(int value, String name) { + this.value = value; + this.name = name; + } + + @Override + public String getName() { + return name; + } + + @Override + public int getIntValue() { + return value; + } + + /** + * Return the enumeration member whose {@link #getName()} matches specified value. + * + * @param name YANG assigned name + * @return corresponding UPInterfaceType item, if present + * @throws NullPointerException if name is null + */ + public static Optional<UPInterfaceType> forName(String name) { + return Optional.ofNullable(NAME_MAP.get(Objects.requireNonNull(name))); + } + + /** + * Return the enumeration member whose {@link #getIntValue()} matches specified value. + * + * @param intValue integer value + * @return corresponding UPInterfaceType item, or null if no such item exists + */ + public static UPInterfaceType forValue(int intValue) { + return VALUE_MAP.get(intValue); + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfId.java new file mode 100644 index 000000000..3918d23d0 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfId.java @@ -0,0 +1,37 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.Guami; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.ChildOf; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * container amfId { + * uses aMFIdentifier; + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Guami/amfId</i> + * + * <p>To create instances of this class use {@link AmfIdBuilder}. + * @see AmfIdBuilder + * + */ +public interface AmfId + extends + ChildOf<Guami>, + Augmentable<AmfId>, + AMFIdentifier +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("amfId"); + + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfIdBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfIdBuilder.java new file mode 100644 index 000000000..03348babe --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/AmfIdBuilder.java @@ -0,0 +1,255 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFPointer; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFRegionId; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TAMFSetId; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link AmfIdBuilder} instances. + * + * @see AmfIdBuilder + * + */ +public class AmfIdBuilder implements Builder<AmfId> { + + private TAMFPointer _aMFPointer; + private TAMFRegionId _aMFRegionId; + private TAMFSetId _aMFSetId; + + + Map<Class<? extends Augmentation<AmfId>>, Augmentation<AmfId>> augmentation = Collections.emptyMap(); + + public AmfIdBuilder() { + } + public AmfIdBuilder(org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier arg) { + this._aMFRegionId = arg.getAMFRegionId(); + this._aMFSetId = arg.getAMFSetId(); + this._aMFPointer = arg.getAMFPointer(); + } + + public AmfIdBuilder(AmfId base) { + this._aMFPointer = base.getAMFPointer(); + this._aMFRegionId = base.getAMFRegionId(); + this._aMFSetId = base.getAMFSetId(); + if (base instanceof AmfIdImpl) { + AmfIdImpl impl = (AmfIdImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<AmfId>>, Augmentation<AmfId>> aug =((AugmentationHolder<AmfId>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + /** + * Set fields from given grouping argument. Valid argument is instance of one of following types: + * <ul> + * <li>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier</li> + * </ul> + * + * @param arg grouping object + * @throws IllegalArgumentException if given argument is none of valid types + */ + public void fieldsFrom(DataObject arg) { + boolean isValidArg = false; + if (arg instanceof org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier) { + this._aMFRegionId = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier)arg).getAMFRegionId(); + this._aMFSetId = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier)arg).getAMFSetId(); + this._aMFPointer = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier)arg).getAMFPointer(); + isValidArg = true; + } + CodeHelpers.validValue(isValidArg, arg, "[org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.AMFIdentifier]"); + } + + public TAMFPointer getAMFPointer() { + return _aMFPointer; + } + + public TAMFRegionId getAMFRegionId() { + return _aMFRegionId; + } + + public TAMFSetId getAMFSetId() { + return _aMFSetId; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<AmfId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public AmfIdBuilder setAMFPointer(final TAMFPointer value) { + this._aMFPointer = value; + return this; + } + + public AmfIdBuilder setAMFRegionId(final TAMFRegionId value) { + this._aMFRegionId = value; + return this; + } + + public AmfIdBuilder setAMFSetId(final TAMFSetId value) { + this._aMFSetId = value; + return this; + } + + public AmfIdBuilder addAugmentation(Class<? extends Augmentation<AmfId>> augmentationType, Augmentation<AmfId> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public AmfIdBuilder removeAugmentation(Class<? extends Augmentation<AmfId>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public AmfId build() { + return new AmfIdImpl(this); + } + + private static final class AmfIdImpl implements AmfId { + + private final TAMFPointer _aMFPointer; + private final TAMFRegionId _aMFRegionId; + private final TAMFSetId _aMFSetId; + + private Map<Class<? extends Augmentation<AmfId>>, Augmentation<AmfId>> augmentation = Collections.emptyMap(); + + AmfIdImpl(AmfIdBuilder base) { + this._aMFPointer = base.getAMFPointer(); + this._aMFRegionId = base.getAMFRegionId(); + this._aMFSetId = base.getAMFSetId(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<AmfId> getImplementedInterface() { + return AmfId.class; + } + + @Override + public TAMFPointer getAMFPointer() { + return _aMFPointer; + } + + @Override + public TAMFRegionId getAMFRegionId() { + return _aMFRegionId; + } + + @Override + public TAMFSetId getAMFSetId() { + return _aMFSetId; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<AmfId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_aMFPointer); + result = prime * result + Objects.hashCode(_aMFRegionId); + result = prime * result + Objects.hashCode(_aMFSetId); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!AmfId.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + AmfId other = (AmfId)obj; + if (!Objects.equals(_aMFPointer, other.getAMFPointer())) { + return false; + } + if (!Objects.equals(_aMFRegionId, other.getAMFRegionId())) { + return false; + } + if (!Objects.equals(_aMFSetId, other.getAMFSetId())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + AmfIdImpl otherImpl = (AmfIdImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<AmfId>>, Augmentation<AmfId>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("AmfId"); + CodeHelpers.appendValue(helper, "_aMFPointer", _aMFPointer); + CodeHelpers.appendValue(helper, "_aMFRegionId", _aMFRegionId); + CodeHelpers.appendValue(helper, "_aMFSetId", _aMFSetId); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnId.java new file mode 100644 index 000000000..6f0017139 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnId.java @@ -0,0 +1,37 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.Guami; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.ChildOf; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * container plmnId { + * uses pLMNId; + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Guami/plmnId</i> + * + * <p>To create instances of this class use {@link PlmnIdBuilder}. + * @see PlmnIdBuilder + * + */ +public interface PlmnId + extends + ChildOf<Guami>, + Augmentable<PlmnId>, + PLMNId +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("plmnId"); + + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnIdBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnIdBuilder.java new file mode 100644 index 000000000..d1087256f --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/guami/PlmnIdBuilder.java @@ -0,0 +1,229 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.guami; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMcc; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMnc; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link PlmnIdBuilder} instances. + * + * @see PlmnIdBuilder + * + */ +public class PlmnIdBuilder implements Builder<PlmnId> { + + private TMcc _mCC; + private TMnc _mNC; + + + Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> augmentation = Collections.emptyMap(); + + public PlmnIdBuilder() { + } + public PlmnIdBuilder(org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId arg) { + this._mCC = arg.getMCC(); + this._mNC = arg.getMNC(); + } + + public PlmnIdBuilder(PlmnId base) { + this._mCC = base.getMCC(); + this._mNC = base.getMNC(); + if (base instanceof PlmnIdImpl) { + PlmnIdImpl impl = (PlmnIdImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> aug =((AugmentationHolder<PlmnId>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + /** + * Set fields from given grouping argument. Valid argument is instance of one of following types: + * <ul> + * <li>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId</li> + * </ul> + * + * @param arg grouping object + * @throws IllegalArgumentException if given argument is none of valid types + */ + public void fieldsFrom(DataObject arg) { + boolean isValidArg = false; + if (arg instanceof org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId) { + this._mCC = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId)arg).getMCC(); + this._mNC = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId)arg).getMNC(); + isValidArg = true; + } + CodeHelpers.validValue(isValidArg, arg, "[org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId]"); + } + + public TMcc getMCC() { + return _mCC; + } + + public TMnc getMNC() { + return _mNC; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<PlmnId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public PlmnIdBuilder setMCC(final TMcc value) { + this._mCC = value; + return this; + } + + public PlmnIdBuilder setMNC(final TMnc value) { + this._mNC = value; + return this; + } + + public PlmnIdBuilder addAugmentation(Class<? extends Augmentation<PlmnId>> augmentationType, Augmentation<PlmnId> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public PlmnIdBuilder removeAugmentation(Class<? extends Augmentation<PlmnId>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public PlmnId build() { + return new PlmnIdImpl(this); + } + + private static final class PlmnIdImpl implements PlmnId { + + private final TMcc _mCC; + private final TMnc _mNC; + + private Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> augmentation = Collections.emptyMap(); + + PlmnIdImpl(PlmnIdBuilder base) { + this._mCC = base.getMCC(); + this._mNC = base.getMNC(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<PlmnId> getImplementedInterface() { + return PlmnId.class; + } + + @Override + public TMcc getMCC() { + return _mCC; + } + + @Override + public TMnc getMNC() { + return _mNC; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<PlmnId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_mCC); + result = prime * result + Objects.hashCode(_mNC); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!PlmnId.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + PlmnId other = (PlmnId)obj; + if (!Objects.equals(_mCC, other.getMCC())) { + return false; + } + if (!Objects.equals(_mNC, other.getMNC())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + PlmnIdImpl otherImpl = (PlmnIdImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("PlmnId"); + CodeHelpers.appendValue(helper, "_mCC", _mCC); + CodeHelpers.appendValue(helper, "_mNC", _mNC); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/Address.java new file mode 100644 index 000000000..d9718e665 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/Address.java @@ -0,0 +1,49 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.InterfaceUpfInfoItem; +import org.opendaylight.yangtools.yang.binding.ChoiceIn; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * choice address { + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * case endpointFqdn { + * leaf endpointFqdn { + * type inet:domain-name; + * } + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem/address</i> + * + */ +public interface Address + extends + ChoiceIn<InterfaceUpfInfoItem> +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("address"); + + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdn.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdn.java new file mode 100644 index 000000000..4bf58dda3 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdn.java @@ -0,0 +1,41 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.DomainName; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case endpointFqdn { + * leaf endpointFqdn { + * type inet:domain-name; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem/address/endpointFqdn</i> + * + */ +public interface EndpointFqdn + extends + DataObject, + Augmentable<EndpointFqdn>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("endpointFqdn"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.DomainName</code> <code>endpointFqdn</code>, or <code>null</code> if not present + */ + @Nullable DomainName getEndpointFqdn(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdnBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdnBuilder.java new file mode 100644 index 000000000..2abed8b15 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/EndpointFqdnBuilder.java @@ -0,0 +1,183 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.DomainName; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link EndpointFqdnBuilder} instances. + * + * @see EndpointFqdnBuilder + * + */ +public class EndpointFqdnBuilder implements Builder<EndpointFqdn> { + + private DomainName _endpointFqdn; + + + Map<Class<? extends Augmentation<EndpointFqdn>>, Augmentation<EndpointFqdn>> augmentation = Collections.emptyMap(); + + public EndpointFqdnBuilder() { + } + + public EndpointFqdnBuilder(EndpointFqdn base) { + this._endpointFqdn = base.getEndpointFqdn(); + if (base instanceof EndpointFqdnImpl) { + EndpointFqdnImpl impl = (EndpointFqdnImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<EndpointFqdn>>, Augmentation<EndpointFqdn>> aug =((AugmentationHolder<EndpointFqdn>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public DomainName getEndpointFqdn() { + return _endpointFqdn; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<EndpointFqdn>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public EndpointFqdnBuilder setEndpointFqdn(final DomainName value) { + this._endpointFqdn = value; + return this; + } + + public EndpointFqdnBuilder addAugmentation(Class<? extends Augmentation<EndpointFqdn>> augmentationType, Augmentation<EndpointFqdn> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public EndpointFqdnBuilder removeAugmentation(Class<? extends Augmentation<EndpointFqdn>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public EndpointFqdn build() { + return new EndpointFqdnImpl(this); + } + + private static final class EndpointFqdnImpl implements EndpointFqdn { + + private final DomainName _endpointFqdn; + + private Map<Class<? extends Augmentation<EndpointFqdn>>, Augmentation<EndpointFqdn>> augmentation = Collections.emptyMap(); + + EndpointFqdnImpl(EndpointFqdnBuilder base) { + this._endpointFqdn = base.getEndpointFqdn(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<EndpointFqdn> getImplementedInterface() { + return EndpointFqdn.class; + } + + @Override + public DomainName getEndpointFqdn() { + return _endpointFqdn; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<EndpointFqdn>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_endpointFqdn); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!EndpointFqdn.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + EndpointFqdn other = (EndpointFqdn)obj; + if (!Objects.equals(_endpointFqdn, other.getEndpointFqdn())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + EndpointFqdnImpl otherImpl = (EndpointFqdnImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<EndpointFqdn>>, Augmentation<EndpointFqdn>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("EndpointFqdn"); + CodeHelpers.appendValue(helper, "_endpointFqdn", _endpointFqdn); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4Address.java new file mode 100644 index 000000000..92483f476 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4Address.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem/address/ipv4Address</i> + * + */ +public interface Ipv4Address + extends + DataObject, + Augmentable<Ipv4Address>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv4Address"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address</code> <code>ipv4Address</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv4Address getIpv4Address(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4AddressBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4AddressBuilder.java new file mode 100644 index 000000000..4ad474a9c --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv4AddressBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv4AddressBuilder} instances. + * + * @see Ipv4AddressBuilder + * + */ +public class Ipv4AddressBuilder implements Builder<Ipv4Address> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address _ipv4Address; + + + Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> augmentation = Collections.emptyMap(); + + public Ipv4AddressBuilder() { + } + + public Ipv4AddressBuilder(Ipv4Address base) { + this._ipv4Address = base.getIpv4Address(); + if (base instanceof Ipv4AddressImpl) { + Ipv4AddressImpl impl = (Ipv4AddressImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> aug =((AugmentationHolder<Ipv4Address>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address getIpv4Address() { + return _ipv4Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv4Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv4AddressBuilder setIpv4Address(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address value) { + this._ipv4Address = value; + return this; + } + + public Ipv4AddressBuilder addAugmentation(Class<? extends Augmentation<Ipv4Address>> augmentationType, Augmentation<Ipv4Address> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv4AddressBuilder removeAugmentation(Class<? extends Augmentation<Ipv4Address>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv4Address build() { + return new Ipv4AddressImpl(this); + } + + private static final class Ipv4AddressImpl implements Ipv4Address { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address _ipv4Address; + + private Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> augmentation = Collections.emptyMap(); + + Ipv4AddressImpl(Ipv4AddressBuilder base) { + this._ipv4Address = base.getIpv4Address(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv4Address> getImplementedInterface() { + return Ipv4Address.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address getIpv4Address() { + return _ipv4Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv4Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv4Address); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv4Address.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv4Address other = (Ipv4Address)obj; + if (!Objects.equals(_ipv4Address, other.getIpv4Address())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv4AddressImpl otherImpl = (Ipv4AddressImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv4Address"); + CodeHelpers.appendValue(helper, "_ipv4Address", _ipv4Address); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Address.java new file mode 100644 index 000000000..93a8affbd --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Address.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem/address/ipv6Address</i> + * + */ +public interface Ipv6Address + extends + DataObject, + Augmentable<Ipv6Address>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv6Address"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address</code> <code>ipv6Address</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv6Address getIpv6Address(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6AddressBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6AddressBuilder.java new file mode 100644 index 000000000..4d0416e3b --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6AddressBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv6AddressBuilder} instances. + * + * @see Ipv6AddressBuilder + * + */ +public class Ipv6AddressBuilder implements Builder<Ipv6Address> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address _ipv6Address; + + + Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> augmentation = Collections.emptyMap(); + + public Ipv6AddressBuilder() { + } + + public Ipv6AddressBuilder(Ipv6Address base) { + this._ipv6Address = base.getIpv6Address(); + if (base instanceof Ipv6AddressImpl) { + Ipv6AddressImpl impl = (Ipv6AddressImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> aug =((AugmentationHolder<Ipv6Address>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getIpv6Address() { + return _ipv6Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv6Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv6AddressBuilder setIpv6Address(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value) { + this._ipv6Address = value; + return this; + } + + public Ipv6AddressBuilder addAugmentation(Class<? extends Augmentation<Ipv6Address>> augmentationType, Augmentation<Ipv6Address> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv6AddressBuilder removeAugmentation(Class<? extends Augmentation<Ipv6Address>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv6Address build() { + return new Ipv6AddressImpl(this); + } + + private static final class Ipv6AddressImpl implements Ipv6Address { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address _ipv6Address; + + private Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> augmentation = Collections.emptyMap(); + + Ipv6AddressImpl(Ipv6AddressBuilder base) { + this._ipv6Address = base.getIpv6Address(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv6Address> getImplementedInterface() { + return Ipv6Address.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getIpv6Address() { + return _ipv6Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv6Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv6Address); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv6Address.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv6Address other = (Ipv6Address)obj; + if (!Objects.equals(_ipv6Address, other.getIpv6Address())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv6AddressImpl otherImpl = (Ipv6AddressImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv6Address"); + CodeHelpers.appendValue(helper, "_ipv6Address", _ipv6Address); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Prefix.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Prefix.java new file mode 100644 index 000000000..e18a666dd --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6Prefix.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/InterfaceUpfInfoItem/address/ipv6Prefix</i> + * + */ +public interface Ipv6Prefix + extends + DataObject, + Augmentable<Ipv6Prefix>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv6Prefix"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix</code> <code>ipv6Prefix</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv6Prefix getIpv6Prefix(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6PrefixBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6PrefixBuilder.java new file mode 100644 index 000000000..2fc644826 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/interfaceupfinfoitem/address/Ipv6PrefixBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.interfaceupfinfoitem.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv6PrefixBuilder} instances. + * + * @see Ipv6PrefixBuilder + * + */ +public class Ipv6PrefixBuilder implements Builder<Ipv6Prefix> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix _ipv6Prefix; + + + Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> augmentation = Collections.emptyMap(); + + public Ipv6PrefixBuilder() { + } + + public Ipv6PrefixBuilder(Ipv6Prefix base) { + this._ipv6Prefix = base.getIpv6Prefix(); + if (base instanceof Ipv6PrefixImpl) { + Ipv6PrefixImpl impl = (Ipv6PrefixImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> aug =((AugmentationHolder<Ipv6Prefix>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix getIpv6Prefix() { + return _ipv6Prefix; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv6Prefix>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv6PrefixBuilder setIpv6Prefix(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix value) { + this._ipv6Prefix = value; + return this; + } + + public Ipv6PrefixBuilder addAugmentation(Class<? extends Augmentation<Ipv6Prefix>> augmentationType, Augmentation<Ipv6Prefix> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv6PrefixBuilder removeAugmentation(Class<? extends Augmentation<Ipv6Prefix>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv6Prefix build() { + return new Ipv6PrefixImpl(this); + } + + private static final class Ipv6PrefixImpl implements Ipv6Prefix { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix _ipv6Prefix; + + private Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> augmentation = Collections.emptyMap(); + + Ipv6PrefixImpl(Ipv6PrefixBuilder base) { + this._ipv6Prefix = base.getIpv6Prefix(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv6Prefix> getImplementedInterface() { + return Ipv6Prefix.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix getIpv6Prefix() { + return _ipv6Prefix; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv6Prefix>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv6Prefix); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv6Prefix.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv6Prefix other = (Ipv6Prefix)obj; + if (!Objects.equals(_ipv6Prefix, other.getIpv6Prefix())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv6PrefixImpl otherImpl = (Ipv6PrefixImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv6Prefix"); + CodeHelpers.appendValue(helper, "_ipv6Prefix", _ipv6Prefix); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/Address.java new file mode 100644 index 000000000..f15a2bdc6 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/Address.java @@ -0,0 +1,44 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.IpEndPoint; +import org.opendaylight.yangtools.yang.binding.ChoiceIn; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * choice address { + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/ipEndPoint/address</i> + * + */ +public interface Address + extends + ChoiceIn<IpEndPoint> +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("address"); + + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4Address.java new file mode 100644 index 000000000..b387e3fc8 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4Address.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv4Address { + * leaf ipv4Address { + * type inet:ipv4-address; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/ipEndPoint/address/ipv4Address</i> + * + */ +public interface Ipv4Address + extends + DataObject, + Augmentable<Ipv4Address>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv4Address"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address</code> <code>ipv4Address</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv4Address getIpv4Address(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4AddressBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4AddressBuilder.java new file mode 100644 index 000000000..530eafef0 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv4AddressBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv4AddressBuilder} instances. + * + * @see Ipv4AddressBuilder + * + */ +public class Ipv4AddressBuilder implements Builder<Ipv4Address> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address _ipv4Address; + + + Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> augmentation = Collections.emptyMap(); + + public Ipv4AddressBuilder() { + } + + public Ipv4AddressBuilder(Ipv4Address base) { + this._ipv4Address = base.getIpv4Address(); + if (base instanceof Ipv4AddressImpl) { + Ipv4AddressImpl impl = (Ipv4AddressImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> aug =((AugmentationHolder<Ipv4Address>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address getIpv4Address() { + return _ipv4Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv4Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv4AddressBuilder setIpv4Address(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address value) { + this._ipv4Address = value; + return this; + } + + public Ipv4AddressBuilder addAugmentation(Class<? extends Augmentation<Ipv4Address>> augmentationType, Augmentation<Ipv4Address> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv4AddressBuilder removeAugmentation(Class<? extends Augmentation<Ipv4Address>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv4Address build() { + return new Ipv4AddressImpl(this); + } + + private static final class Ipv4AddressImpl implements Ipv4Address { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address _ipv4Address; + + private Map<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> augmentation = Collections.emptyMap(); + + Ipv4AddressImpl(Ipv4AddressBuilder base) { + this._ipv4Address = base.getIpv4Address(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv4Address> getImplementedInterface() { + return Ipv4Address.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv4Address getIpv4Address() { + return _ipv4Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv4Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv4Address); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv4Address.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv4Address other = (Ipv4Address)obj; + if (!Objects.equals(_ipv4Address, other.getIpv4Address())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv4AddressImpl otherImpl = (Ipv4AddressImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv4Address>>, Augmentation<Ipv4Address>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv4Address"); + CodeHelpers.appendValue(helper, "_ipv4Address", _ipv4Address); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Address.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Address.java new file mode 100644 index 000000000..f6a3a4a3d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Address.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv6Address { + * leaf ipv6Address { + * type inet:ipv6-address; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/ipEndPoint/address/ipv6Address</i> + * + */ +public interface Ipv6Address + extends + DataObject, + Augmentable<Ipv6Address>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv6Address"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address</code> <code>ipv6Address</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv6Address getIpv6Address(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6AddressBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6AddressBuilder.java new file mode 100644 index 000000000..525e2b3a6 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6AddressBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv6AddressBuilder} instances. + * + * @see Ipv6AddressBuilder + * + */ +public class Ipv6AddressBuilder implements Builder<Ipv6Address> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address _ipv6Address; + + + Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> augmentation = Collections.emptyMap(); + + public Ipv6AddressBuilder() { + } + + public Ipv6AddressBuilder(Ipv6Address base) { + this._ipv6Address = base.getIpv6Address(); + if (base instanceof Ipv6AddressImpl) { + Ipv6AddressImpl impl = (Ipv6AddressImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> aug =((AugmentationHolder<Ipv6Address>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getIpv6Address() { + return _ipv6Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv6Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv6AddressBuilder setIpv6Address(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address value) { + this._ipv6Address = value; + return this; + } + + public Ipv6AddressBuilder addAugmentation(Class<? extends Augmentation<Ipv6Address>> augmentationType, Augmentation<Ipv6Address> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv6AddressBuilder removeAugmentation(Class<? extends Augmentation<Ipv6Address>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv6Address build() { + return new Ipv6AddressImpl(this); + } + + private static final class Ipv6AddressImpl implements Ipv6Address { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address _ipv6Address; + + private Map<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> augmentation = Collections.emptyMap(); + + Ipv6AddressImpl(Ipv6AddressBuilder base) { + this._ipv6Address = base.getIpv6Address(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv6Address> getImplementedInterface() { + return Ipv6Address.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Address getIpv6Address() { + return _ipv6Address; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv6Address>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv6Address); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv6Address.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv6Address other = (Ipv6Address)obj; + if (!Objects.equals(_ipv6Address, other.getIpv6Address())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv6AddressImpl otherImpl = (Ipv6AddressImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv6Address>>, Augmentation<Ipv6Address>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv6Address"); + CodeHelpers.appendValue(helper, "_ipv6Address", _ipv6Address); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Prefix.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Prefix.java new file mode 100644 index 000000000..95022a340 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6Prefix.java @@ -0,0 +1,40 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import org.eclipse.jdt.annotation.Nullable; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.Address; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.DataObject; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * case ipv6Prefix { + * leaf ipv6Prefix { + * type inet:ipv6-prefix; + * } + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/ipEndPoint/address/ipv6Prefix</i> + * + */ +public interface Ipv6Prefix + extends + DataObject, + Augmentable<Ipv6Prefix>, + Address +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("ipv6Prefix"); + + /** + * @return <code>org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix</code> <code>ipv6Prefix</code>, or <code>null</code> if not present + */ + org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.@Nullable Ipv6Prefix getIpv6Prefix(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6PrefixBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6PrefixBuilder.java new file mode 100644 index 000000000..8bb742cf3 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/ipendpoint/address/Ipv6PrefixBuilder.java @@ -0,0 +1,182 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.ipendpoint.address; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link Ipv6PrefixBuilder} instances. + * + * @see Ipv6PrefixBuilder + * + */ +public class Ipv6PrefixBuilder implements Builder<Ipv6Prefix> { + + private org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix _ipv6Prefix; + + + Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> augmentation = Collections.emptyMap(); + + public Ipv6PrefixBuilder() { + } + + public Ipv6PrefixBuilder(Ipv6Prefix base) { + this._ipv6Prefix = base.getIpv6Prefix(); + if (base instanceof Ipv6PrefixImpl) { + Ipv6PrefixImpl impl = (Ipv6PrefixImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> aug =((AugmentationHolder<Ipv6Prefix>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix getIpv6Prefix() { + return _ipv6Prefix; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<Ipv6Prefix>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public Ipv6PrefixBuilder setIpv6Prefix(final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix value) { + this._ipv6Prefix = value; + return this; + } + + public Ipv6PrefixBuilder addAugmentation(Class<? extends Augmentation<Ipv6Prefix>> augmentationType, Augmentation<Ipv6Prefix> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public Ipv6PrefixBuilder removeAugmentation(Class<? extends Augmentation<Ipv6Prefix>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public Ipv6Prefix build() { + return new Ipv6PrefixImpl(this); + } + + private static final class Ipv6PrefixImpl implements Ipv6Prefix { + + private final org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix _ipv6Prefix; + + private Map<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> augmentation = Collections.emptyMap(); + + Ipv6PrefixImpl(Ipv6PrefixBuilder base) { + this._ipv6Prefix = base.getIpv6Prefix(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<Ipv6Prefix> getImplementedInterface() { + return Ipv6Prefix.class; + } + + @Override + public org.opendaylight.yang.gen.v1.urn.ietf.params.xml.ns.yang.ietf.inet.types.rev130715.Ipv6Prefix getIpv6Prefix() { + return _ipv6Prefix; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<Ipv6Prefix>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_ipv6Prefix); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!Ipv6Prefix.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + Ipv6Prefix other = (Ipv6Prefix)obj; + if (!Objects.equals(_ipv6Prefix, other.getIpv6Prefix())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + Ipv6PrefixImpl otherImpl = (Ipv6PrefixImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<Ipv6Prefix>>, Augmentation<Ipv6Prefix>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("Ipv6Prefix"); + CodeHelpers.appendValue(helper, "_ipv6Prefix", _ipv6Prefix); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfo.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfo.java new file mode 100644 index 000000000..025706355 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfo.java @@ -0,0 +1,44 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.snssaiupfinfoitem; +import java.lang.Override; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.SnssaiUpfInfoItem; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.ChildOf; +import org.opendaylight.yangtools.yang.binding.Identifiable; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * list dnnUpfInfo { + * key dnn; + * uses DnnUpfInfoItem; + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/SnssaiUpfInfoItem/dnnUpfInfo</i> + * + * <p>To create instances of this class use {@link DnnUpfInfoBuilder}. + * @see DnnUpfInfoBuilder + * @see DnnUpfInfoKey + * + */ +public interface DnnUpfInfo + extends + ChildOf<SnssaiUpfInfoItem>, + Augmentable<DnnUpfInfo>, + DnnUpfInfoItem, + Identifiable<DnnUpfInfoKey> +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("dnnUpfInfo"); + + @Override + DnnUpfInfoKey key(); + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoBuilder.java new file mode 100644 index 000000000..248c8304e --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoBuilder.java @@ -0,0 +1,224 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.snssaiupfinfoitem; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TDnn; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link DnnUpfInfoBuilder} instances. + * + * @see DnnUpfInfoBuilder + * + */ +public class DnnUpfInfoBuilder implements Builder<DnnUpfInfo> { + + private TDnn _dnn; + private DnnUpfInfoKey key; + + + Map<Class<? extends Augmentation<DnnUpfInfo>>, Augmentation<DnnUpfInfo>> augmentation = Collections.emptyMap(); + + public DnnUpfInfoBuilder() { + } + public DnnUpfInfoBuilder(org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem arg) { + this._dnn = arg.getDnn(); + } + + public DnnUpfInfoBuilder(DnnUpfInfo base) { + this.key = base.key(); + this._dnn = base.getDnn(); + if (base instanceof DnnUpfInfoImpl) { + DnnUpfInfoImpl impl = (DnnUpfInfoImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<DnnUpfInfo>>, Augmentation<DnnUpfInfo>> aug =((AugmentationHolder<DnnUpfInfo>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + /** + * Set fields from given grouping argument. Valid argument is instance of one of following types: + * <ul> + * <li>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem</li> + * </ul> + * + * @param arg grouping object + * @throws IllegalArgumentException if given argument is none of valid types + */ + public void fieldsFrom(DataObject arg) { + boolean isValidArg = false; + if (arg instanceof org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem) { + this._dnn = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem)arg).getDnn(); + isValidArg = true; + } + CodeHelpers.validValue(isValidArg, arg, "[org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.DnnUpfInfoItem]"); + } + + public DnnUpfInfoKey key() { + return key; + } + + public TDnn getDnn() { + return _dnn; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<DnnUpfInfo>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + public DnnUpfInfoBuilder withKey(final DnnUpfInfoKey key) { + this.key = key; + return this; + } + + public DnnUpfInfoBuilder setDnn(final TDnn value) { + this._dnn = value; + return this; + } + + public DnnUpfInfoBuilder addAugmentation(Class<? extends Augmentation<DnnUpfInfo>> augmentationType, Augmentation<DnnUpfInfo> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public DnnUpfInfoBuilder removeAugmentation(Class<? extends Augmentation<DnnUpfInfo>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public DnnUpfInfo build() { + return new DnnUpfInfoImpl(this); + } + + private static final class DnnUpfInfoImpl implements DnnUpfInfo { + + private final TDnn _dnn; + private final DnnUpfInfoKey key; + + private Map<Class<? extends Augmentation<DnnUpfInfo>>, Augmentation<DnnUpfInfo>> augmentation = Collections.emptyMap(); + + DnnUpfInfoImpl(DnnUpfInfoBuilder base) { + if (base.key() != null) { + this.key = base.key(); + } else { + this.key = new DnnUpfInfoKey(base.getDnn()); + } + this._dnn = key.getDnn(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<DnnUpfInfo> getImplementedInterface() { + return DnnUpfInfo.class; + } + + @Override + public DnnUpfInfoKey key() { + return key; + } + + @Override + public TDnn getDnn() { + return _dnn; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<DnnUpfInfo>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_dnn); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!DnnUpfInfo.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + DnnUpfInfo other = (DnnUpfInfo)obj; + if (!Objects.equals(_dnn, other.getDnn())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + DnnUpfInfoImpl otherImpl = (DnnUpfInfoImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<DnnUpfInfo>>, Augmentation<DnnUpfInfo>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("DnnUpfInfo"); + CodeHelpers.appendValue(helper, "_dnn", _dnn); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoKey.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoKey.java new file mode 100644 index 000000000..faa589d7d --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/snssaiupfinfoitem/DnnUpfInfoKey.java @@ -0,0 +1,67 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.snssaiupfinfoitem; +import com.google.common.base.MoreObjects; +import java.lang.Override; +import java.lang.String; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TDnn; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.Identifier; + +public class DnnUpfInfoKey + implements Identifier<DnnUpfInfo> { + private static final long serialVersionUID = -3246452801435528856L; + private final TDnn _dnn; + + + public DnnUpfInfoKey(TDnn _dnn) { + + + this._dnn = _dnn; + } + + /** + * Creates a copy from Source Object. + * + * @param source Source object + */ + public DnnUpfInfoKey(DnnUpfInfoKey source) { + this._dnn = source._dnn; + } + + + public TDnn getDnn() { + return _dnn; + } + + + @Override + public int hashCode() { + return CodeHelpers.wrapperHashCode(_dnn); + } + + @Override + public boolean equals(java.lang.Object obj) { + if (this == obj) { + return true; + } + if (obj == null) { + return false; + } + if (getClass() != obj.getClass()) { + return false; + } + DnnUpfInfoKey other = (DnnUpfInfoKey) obj; + if (!Objects.equals(_dnn, other._dnn)) { + return false; + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(DnnUpfInfoKey.class); + CodeHelpers.appendValue(helper, "_dnn", _dnn); + return helper.toString(); + } +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnId.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnId.java new file mode 100644 index 000000000..44c34f278 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnId.java @@ -0,0 +1,37 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.tai; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.$YangModuleInfoImpl; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.Tai; +import org.opendaylight.yangtools.yang.binding.Augmentable; +import org.opendaylight.yangtools.yang.binding.ChildOf; +import org.opendaylight.yangtools.yang.common.QName; + +/** + * + * <p> + * This class represents the following YANG schema fragment defined in module <b>_3gpp-common-yang-types</b> + * <pre> + * container plmnId { + * uses pLMNId; + * } + * </pre>The schema path to identify an instance is + * <i>_3gpp-common-yang-types/Tai/plmnId</i> + * + * <p>To create instances of this class use {@link PlmnIdBuilder}. + * @see PlmnIdBuilder + * + */ +public interface PlmnId + extends + ChildOf<Tai>, + Augmentable<PlmnId>, + PLMNId +{ + + + + public static final QName QNAME = $YangModuleInfoImpl.qnameOf("plmnId"); + + +} + diff --git a/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnIdBuilder.java b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnIdBuilder.java new file mode 100644 index 000000000..530d59d26 --- /dev/null +++ b/sdnr/wt/devicemanager-gran/provider/src/main/java/org/opendaylight/yang/gen/v1/urn/_3gpp/tsg/sa5/nrm/types/rev180731/tai/PlmnIdBuilder.java @@ -0,0 +1,229 @@ +package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.tai; +import com.google.common.base.MoreObjects; +import com.google.common.collect.ImmutableMap; +import java.lang.Class; +import java.lang.Object; +import java.lang.Override; +import java.lang.String; +import java.lang.SuppressWarnings; +import java.util.Collections; +import java.util.HashMap; +import java.util.Map; +import java.util.Objects; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMcc; +import org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.TMnc; +import org.opendaylight.yangtools.concepts.Builder; +import org.opendaylight.yangtools.yang.binding.Augmentation; +import org.opendaylight.yangtools.yang.binding.AugmentationHolder; +import org.opendaylight.yangtools.yang.binding.CodeHelpers; +import org.opendaylight.yangtools.yang.binding.DataObject; + +/** + * Class that builds {@link PlmnIdBuilder} instances. + * + * @see PlmnIdBuilder + * + */ +public class PlmnIdBuilder implements Builder<PlmnId> { + + private TMcc _mCC; + private TMnc _mNC; + + + Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> augmentation = Collections.emptyMap(); + + public PlmnIdBuilder() { + } + public PlmnIdBuilder(org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId arg) { + this._mCC = arg.getMCC(); + this._mNC = arg.getMNC(); + } + + public PlmnIdBuilder(PlmnId base) { + this._mCC = base.getMCC(); + this._mNC = base.getMNC(); + if (base instanceof PlmnIdImpl) { + PlmnIdImpl impl = (PlmnIdImpl) base; + if (!impl.augmentation.isEmpty()) { + this.augmentation = new HashMap<>(impl.augmentation); + } + } else if (base instanceof AugmentationHolder) { + @SuppressWarnings("unchecked") + Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> aug =((AugmentationHolder<PlmnId>) base).augmentations(); + if (!aug.isEmpty()) { + this.augmentation = new HashMap<>(aug); + } + } + } + + /** + * Set fields from given grouping argument. Valid argument is instance of one of following types: + * <ul> + * <li>org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId</li> + * </ul> + * + * @param arg grouping object + * @throws IllegalArgumentException if given argument is none of valid types + */ + public void fieldsFrom(DataObject arg) { + boolean isValidArg = false; + if (arg instanceof org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId) { + this._mCC = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId)arg).getMCC(); + this._mNC = ((org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId)arg).getMNC(); + isValidArg = true; + } + CodeHelpers.validValue(isValidArg, arg, "[org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731.PLMNId]"); + } + + public TMcc getMCC() { + return _mCC; + } + + public TMnc getMNC() { + return _mNC; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + public <E$$ extends Augmentation<PlmnId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + + public PlmnIdBuilder setMCC(final TMcc value) { + this._mCC = value; + return this; + } + + public PlmnIdBuilder setMNC(final TMnc value) { + this._mNC = value; + return this; + } + + public PlmnIdBuilder addAugmentation(Class<? extends Augmentation<PlmnId>> augmentationType, Augmentation<PlmnId> augmentationValue) { + if (augmentationValue == null) { + return removeAugmentation(augmentationType); + } + + if (!(this.augmentation instanceof HashMap)) { + this.augmentation = new HashMap<>(); + } + + this.augmentation.put(augmentationType, augmentationValue); + return this; + } + + public PlmnIdBuilder removeAugmentation(Class<? extends Augmentation<PlmnId>> augmentationType) { + if (this.augmentation instanceof HashMap) { + this.augmentation.remove(augmentationType); + } + return this; + } + + @Override + public PlmnId build() { + return new PlmnIdImpl(this); + } + + private static final class PlmnIdImpl implements PlmnId { + + private final TMcc _mCC; + private final TMnc _mNC; + + private Map<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> augmentation = Collections.emptyMap(); + + PlmnIdImpl(PlmnIdBuilder base) { + this._mCC = base.getMCC(); + this._mNC = base.getMNC(); + this.augmentation = ImmutableMap.copyOf(base.augmentation); + } + + @Override + public Class<PlmnId> getImplementedInterface() { + return PlmnId.class; + } + + @Override + public TMcc getMCC() { + return _mCC; + } + + @Override + public TMnc getMNC() { + return _mNC; + } + + @SuppressWarnings({ "unchecked", "checkstyle:methodTypeParameterName"}) + @Override + public <E$$ extends Augmentation<PlmnId>> E$$ augmentation(Class<E$$> augmentationType) { + return (E$$) augmentation.get(CodeHelpers.nonNullValue(augmentationType, "augmentationType")); + } + + private int hash = 0; + private volatile boolean hashValid = false; + + @Override + public int hashCode() { + if (hashValid) { + return hash; + } + + final int prime = 31; + int result = 1; + result = prime * result + Objects.hashCode(_mCC); + result = prime * result + Objects.hashCode(_mNC); + result = prime * result + Objects.hashCode(augmentation); + + hash = result; + hashValid = true; + return result; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) { + return true; + } + if (!(obj instanceof DataObject)) { + return false; + } + if (!PlmnId.class.equals(((DataObject)obj).getImplementedInterface())) { + return false; + } + PlmnId other = (PlmnId)obj; + if (!Objects.equals(_mCC, other.getMCC())) { + return false; + } + if (!Objects.equals(_mNC, other.getMNC())) { + return false; + } + if (getClass() == obj.getClass()) { + // Simple case: we are comparing against self + PlmnIdImpl otherImpl = (PlmnIdImpl) obj; + if (!Objects.equals(augmentation, otherImpl.augmentation)) { + return false; + } + } else { + // Hard case: compare our augments with presence there... + for (Map.Entry<Class<? extends Augmentation<PlmnId>>, Augmentation<PlmnId>> e : augmentation.entrySet()) { + if (!e.getValue().equals(other.augmentation(e.getKey()))) { + return false; + } + } + // .. and give the other one the chance to do the same + if (!obj.equals(this)) { + return false; + } + } + return true; + } + + @Override + public String toString() { + final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper("PlmnId"); + CodeHelpers.appendValue(helper, "_mCC", _mCC); + CodeHelpers.appendValue(helper, "_mNC", _mNC); + CodeHelpers.appendValue(helper, "augmentation", augmentation.values()); + return helper.toString(); + } + } +} |