Sha256: ad1add1e2943860a2d25fcfcb56afb7975275e2f2848e6f0be5978a91972e6b5
Contents?: true
Size: 908 Bytes
Versions: 9
Compression:
Stored size: 908 Bytes
Contents
package org.embulk.spi.unit; import java.util.Map; import java.util.HashMap; import java.util.Properties; import com.google.common.base.Function; import com.google.common.collect.Maps; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonValue; public class ToStringMap extends HashMap<String, String> { @JsonCreator public ToStringMap(Map<String, ToString> map) { super(Maps.transformValues(map, new Function<ToString, String>() { public String apply(ToString value) { if (value == null) { return "null"; } else { return value.toString(); } } })); } public Properties toProperties() { Properties props = new Properties(); props.putAll(this); return props; } }
Version data entries
9 entries across 9 versions & 1 rubygems