X-Git-Url: https://gerrit.onap.org/r/gitweb?a=blobdiff_plain;f=sdclient%2Fdiscovery-service%2Fsrc%2Fmain%2Fjava%2Forg%2Fonap%2Fmsb%2Fsdclient%2Fwrapper%2Fconsul%2Fmodel%2Fhealth%2FImmutableService.java;h=acf5a5bd275c3401dd0b30b015bb7d5fbd95ee14;hb=96ae3343a0623e29fc20983d4ae26dae0ce8d0f1;hp=b7167da49ade2ff5342788c44ebd4dfa0ab48887;hpb=4d6d7250c84da7e8896b0585a53ee6cbd3143925;p=msb%2Fdiscovery.git
diff --git a/sdclient/discovery-service/src/main/java/org/onap/msb/sdclient/wrapper/consul/model/health/ImmutableService.java b/sdclient/discovery-service/src/main/java/org/onap/msb/sdclient/wrapper/consul/model/health/ImmutableService.java
index b7167da..acf5a5b 100644
--- a/sdclient/discovery-service/src/main/java/org/onap/msb/sdclient/wrapper/consul/model/health/ImmutableService.java
+++ b/sdclient/discovery-service/src/main/java/org/onap/msb/sdclient/wrapper/consul/model/health/ImmutableService.java
@@ -228,101 +228,7 @@ public final class ImmutableService extends Service {
.add("address", address).add("port", port).toString();
}
- /**
- * Utility type used to correctly read immutable object from JSON representation.
- *
- * @deprecated Do not use this type directly, it exists only for the Jackson-binding
- * infrastructure
- */
- @Deprecated
- @JsonDeserialize
- static final class Json extends Service {
- String id;
- String service;
- List tags = ImmutableList.of();
- String address;
- Integer port;
-
- @JsonProperty(value = "ID")
- public void setId(String id) {
- this.id = id;
- }
-
- @JsonProperty(value = "Service")
- public void setService(String service) {
- this.service = service;
- }
-
- @JsonProperty(value = "Tags")
- @JsonDeserialize(as = ImmutableList.class, contentAs = String.class)
- public void setTags(List tags) {
- this.tags = tags;
- }
-
- @JsonProperty(value = "Address")
- public void setAddress(String address) {
- this.address = address;
- }
-
- @JsonProperty(value = "Port")
- public void setPort(int port) {
- this.port = port;
- }
-
- @Override
- public String getId() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public String getService() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public List getTags() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public String getAddress() {
- throw new UnsupportedOperationException();
- }
-
- @Override
- public int getPort() {
- throw new UnsupportedOperationException();
- }
- }
-
- /**
- * @param json A JSON-bindable data structure
- * @return An immutable value type
- * @deprecated Do not use this method directly, it exists only for the Jackson-binding
- * infrastructure
- */
- @Deprecated
- @JsonCreator
- static ImmutableService fromJson(Json json) {
- ImmutableService.Builder builder = ImmutableService.builder();
- if (json.id != null) {
- builder.id(json.id);
- }
- if (json.service != null) {
- builder.service(json.service);
- }
- if (json.tags != null) {
- builder.addAllTags(json.tags);
- }
- if (json.address != null) {
- builder.address(json.address);
- }
- if (json.port != null) {
- builder.port(json.port);
- }
- return builder.build();
- }
-
+
/**
* Creates an immutable copy of a {@link Service} value. Uses accessors to get values to
* initialize the new immutable instance. If an instance is already immutable, it is returned as