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

Method newOutput

src/main/java/fielded/RemoteEditor.java:1090–1102  ·  view source on GitHub ↗
(Box inside, String returnAddress, Function<T, String> toJson)

Source from the content-addressed store, hash-verified

1088 };
1089 }
1090
1091 protected <T> Consumer<T> newOutput(Box inside, String returnAddress, Function<T, String> toJson) {
1092 Consumer<T> c = x -> {
1093 String json = toJson.apply(x)
1094 .trim();
1095
1096 if (json.endsWith("}"))
1097 json = json.substring(0, json.length() - 1) + ",box:'" + inside.properties.get(IO.id) + "'}";
1098
1099 rater.add(new Pair<>(returnAddress, json));
1100 };
1101
1102 return c;
1103 }
1104
1105 protected Optional<Box> findBoxByID(String uid) {

Callers 1

RemoteEditorMethod · 0.95

Calls 4

applyMethod · 0.65
getMethod · 0.65
lengthMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected