plus.jdk.etcd.common.DefaultConfigAdaptor Maven / Gradle / Ivy
package plus.jdk.etcd.common;
import com.google.gson.Gson;
import java.lang.reflect.Type;
public class DefaultConfigAdaptor implements IConfigAdaptor {
private final Gson gson = new Gson();
@Override
public String serialize(T data) {
return gson.toJson(data);
}
@Override
public T deserialize(String data, Type type) {
return gson.fromJson(data, type);
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy