MCPcopy Create free account
hub / github.com/OpenEndedGroup/Field2 / asMap_call

Method asMap_call

src/main/java/field/graphics/FLine.java:2512–2532  ·  view source on GitHub ↗
(Object a, Object b)

Source from the content-addressed store, hash-verified

2510 .getInterfaces())));
2511 boolean success = false;
2512 try {
2513 Map<?, ?> m = (Map<?, ?>) ScriptUtils.convert(b, Map.class);
2514 for (Map.Entry<?, ?> e : m.entrySet()) {
2515 asMap_set("" + e.getKey(), e.getValue());
2516 }
2517 success = true;
2518 } catch (UnsupportedOperationException e) {
2519
2520 }
2521 if (!success) {
2522 throw new IllegalArgumentException(" can't understand parameter :" + b);
2523 }
2524 return this;
2525 }
2526
2527 @Override
2528 public Object asMap_new(Object b) {
2529 boolean success = false;
2530 try {
2531 Map<?, ?> m = (Map<?, ?>) ScriptUtils.convert(b, Map.class);
2532
2533 Node o = this.duplicate();
2534
2535 for (Map.Entry<?, ?> e : m.entrySet()) {

Callers

nothing calls this directly

Calls 5

asMap_setMethod · 0.95
asListMethod · 0.80
printlnMethod · 0.45
convertMethod · 0.45
getValueMethod · 0.45

Tested by

no test coverage detected