List of usage examples for io.vertx.core.json JsonObject remove
public Object remove(String key)
From source file:org.hawkular.apm.examples.vertx.opentracing.common.VertxMessageExtractAdapter.java
License:Apache License
public VertxMessageExtractAdapter(final JsonObject obj) { // Convert to single valued map this.map = new HashMap<>(); JsonObject header = obj.getJsonObject("_apmHeader"); if (header != null) { header.forEach(entry -> map.put(entry.getKey(), entry.getValue().toString())); // Remove header obj.remove("_apmHeader"); }/*w w w . ja va2 s. c o m*/ }
From source file:org.hawkular.apm.examples.vertx.opentracing.common.VertxMessageInjectAdapter.java
License:Apache License
public static void cleanup(JsonObject obj) { obj.remove("_apmHeader"); }