Create VES client example for domain 'notification'
[oam.git] / features / devicemanager / g-ran / ru-fh / provider / src / main / java / org / opendaylight / yang / gen / v1 / urn / _3gpp / tsg / sa5 / nrm / types / rev180731 / TAMFPointer.java
1 package org.opendaylight.yang.gen.v1.urn._3gpp.tsg.sa5.nrm.types.rev180731;
2 import com.google.common.base.MoreObjects;
3 import com.google.common.collect.ImmutableList;
4 import java.beans.ConstructorProperties;
5 import java.io.Serializable;
6 import java.lang.Override;
7 import java.lang.String;
8 import java.util.List;
9 import java.util.Objects;
10 import java.util.regex.Pattern;
11 import org.opendaylight.yangtools.yang.binding.CodeHelpers;
12 import org.opendaylight.yangtools.yang.binding.TypeObject;
13
14 public class TAMFPointer
15  implements TypeObject, Serializable {
16     private static final long serialVersionUID = -7925647994457565082L;
17     public static final List<String> PATTERN_CONSTANTS = ImmutableList.of("^(?:[01]*)$");
18     private static final Pattern patterns = Pattern.compile(PATTERN_CONSTANTS.get(0));
19     private static final String regexes = "[01]*";
20     private final String _value;
21
22     private static void check_valueLength(final String value) {
23         final int length = value.length();
24         if (length == 6) {
25             return;
26         }
27         CodeHelpers.throwInvalidLength("[[6..6]]", value);
28     }
29
30     @ConstructorProperties("value")
31     public TAMFPointer(String _value) {
32         if (_value != null) {
33             check_valueLength(_value);
34         }
35     
36         Objects.requireNonNull(_value, "Supplied value may not be null");
37         CodeHelpers.checkPattern(_value, patterns, regexes);
38     
39         this._value = _value;
40     }
41     
42     /**
43      * Creates a copy from Source Object.
44      *
45      * @param source Source object
46      */
47     public TAMFPointer(TAMFPointer source) {
48         this._value = source._value;
49     }
50
51     public static TAMFPointer getDefaultInstance(String defaultValue) {
52         return new TAMFPointer(defaultValue);
53     }
54
55     public String getValue() {
56         return _value;
57     }
58
59
60     @Override
61     public int hashCode() {
62         return CodeHelpers.wrapperHashCode(_value);
63     }
64
65     @Override
66     public boolean equals(java.lang.Object obj) {
67         if (this == obj) {
68             return true;
69         }
70         if (obj == null) {
71             return false;
72         }
73         if (getClass() != obj.getClass()) {
74             return false;
75         }
76         TAMFPointer other = (TAMFPointer) obj;
77         if (!Objects.equals(_value, other._value)) {
78             return false;
79         }
80         return true;
81     }
82
83     @Override
84     public String toString() {
85         final MoreObjects.ToStringHelper helper = MoreObjects.toStringHelper(TAMFPointer.class);
86         CodeHelpers.appendValue(helper, "_value", _value);
87         return helper.toString();
88     }
89 }
90