com.minlessika.membership.integration.JsService Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of membership-integration Show documentation
Show all versions of membership-integration Show documentation
It's a library to help developers to integration membership services to another project.
package com.minlessika.membership.integration;
import java.util.UUID;
import javax.json.JsonObject;
public final class JsService implements Service {
private final JsonObject json;
public JsService(final JsonObject json) {
this.json = json;
}
@Override
public UUID uid() {
return UUID.fromString(this.json.getString("id"));
}
@Override
public String name() {
return this.json.getString("name");
}
@Override
public String description() {
return this.json.getString("description", "");
}
@Override
public boolean active() {
return this.json.getBoolean("active");
}
}