File tree Expand file tree Collapse file tree 1 file changed +15
-0
lines changed
app/display/model/src/main/java/org/csstudio/display/builder/model/macros Expand file tree Collapse file tree 1 file changed +15
-0
lines changed Original file line number Diff line number Diff line change 1111
1212import java .io .ByteArrayInputStream ;
1313import java .io .ByteArrayOutputStream ;
14+ import java .util .HashMap ;
15+ import java .util .Map ;
1416import java .util .logging .Level ;
1517
1618import javax .xml .stream .XMLOutputFactory ;
@@ -118,4 +120,17 @@ public static String toString(final Macros macros)
118120 }
119121 return xml .toString ();
120122 }
123+
124+ /** @deprecated Use macros.getValue("M") or macros.getNames()
125+ * @param macros Macros to represent as Map
126+ * @return Map representation for macros
127+ */
128+ public static Map <String , String > toMap (final Macros macros )
129+ {
130+ Map <String , String > readMacroMap = new HashMap <>();
131+ macros .forEach ((s , s2 ) -> {
132+ readMacroMap .put (s ,s2 );
133+ });
134+ return readMacroMap ;
135+ }
121136}
You can’t perform that action at this time.
0 commit comments