We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 8aaf95f commit 322829aCopy full SHA for 322829a
development/src/main/java/gurux/dlms/enums/ClockStatus.java
@@ -132,12 +132,10 @@ private static ClockStatus[] getEnumConstants() {
132
* @return The enumerated value, which represents the integer.
133
*/
134
public static java.util.Set<ClockStatus> forValue(final int value) {
135
- java.util.Set<ClockStatus> types;
+ java.util.Set<ClockStatus> types = new HashSet<ClockStatus>();
136
if (value == 0) {
137
- types = new HashSet<ClockStatus>();
138
types.add(ClockStatus.OK);
139
- } else {
140
+ } else if (value != 0xFF) {
141
ClockStatus[] enums = getEnumConstants();
142
for (int pos = 0; pos != enums.length; ++pos) {
143
if (enums[pos] != ClockStatus.OK
0 commit comments