File tree Expand file tree Collapse file tree 3 files changed +7
-13
lines changed
dslink-v2/src/main/java/org/iot/dsa Expand file tree Collapse file tree 3 files changed +7
-13
lines changed Original file line number Diff line number Diff line change @@ -5,7 +5,7 @@ subprojects {
5
5
apply plugin : ' maven'
6
6
7
7
group ' org.iot-dsa'
8
- version ' 0.50 .0'
8
+ version ' 0.51 .0'
9
9
10
10
sourceCompatibility = 1.8
11
11
targetCompatibility = 1.8
Original file line number Diff line number Diff line change 11
11
public class DSMainNode extends DSNode {
12
12
13
13
/**
14
- * The parent link or null.
14
+ * The ancestral DSLink, or null.
15
15
*/
16
16
public DSLink getLink () {
17
- return (DSLink ) getParent ( );
17
+ return (DSLink ) getAncestor ( DSLink . class );
18
18
}
19
19
20
20
/**
@@ -31,14 +31,4 @@ public boolean isResponder() {
31
31
return true ;
32
32
}
33
33
34
- /**
35
- * The parent must be a DSLink instance.
36
- */
37
- public void validateParent (DSNode node ) {
38
- if (node instanceof DSLink ) {
39
- return ;
40
- }
41
- throw new IllegalArgumentException ("Must be a child of DSLink" );
42
- }
43
-
44
34
}
Original file line number Diff line number Diff line change @@ -132,6 +132,10 @@ public DSFlexEnum valueOf(DSElement arg) {
132
132
if ((arg == null ) || arg .isNull ()) {
133
133
return NULL ;
134
134
}
135
+ if (arg .isList ()) {
136
+ DSList list = arg .toList ();
137
+ return valueOf (list .first ().toString (), list );
138
+ }
135
139
return valueOf (arg .toString ());
136
140
}
137
141
You can’t perform that action at this time.
0 commit comments