Skip to content

Commit

Permalink
Merge pull request #218 from catenax-ng/feature/cmp-1070/add-timeToLi…
Browse files Browse the repository at this point in the history
…ve-attribute

Feature/cmp-1070/add timeToLive attribute : added timeToLive attribute to the discoveryfinder model
  • Loading branch information
saudkhan116 authored Jan 29, 2024
2 parents a1f27e1 + da017c1 commit 566a999
Showing 1 changed file with 14 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@

package org.eclipse.tractusx.digitalproductpass.models.catenax;

import com.fasterxml.jackson.annotation.JsonIgnoreProperties;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;

Expand All @@ -34,6 +35,7 @@
* This class consists exclusively to define attributes and methods related to discovering the needed Endpoints.
**/
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonIgnoreProperties(ignoreUnknown = true)
public class Discovery {

/** ATTRIBUTES **/
Expand Down Expand Up @@ -73,14 +75,17 @@ public static class Endpoint {
String documentation;
@JsonProperty("resourceId")
String resourceId;
@JsonProperty("timeToLive")
String timeToLive;

/** CONSTRUCTOR(S) **/
public Endpoint(String type, String description, String endpointAddress, String documentation, String resourceId) {
public Endpoint(String type, String description, String endpointAddress, String documentation, String resourceId, String timeToLive) {
this.type = type;
this.description = description;
this.endpointAddress = endpointAddress;
this.documentation = documentation;
this.resourceId = resourceId;
this.timeToLive = timeToLive;
}
public Endpoint() {
}
Expand Down Expand Up @@ -121,5 +126,13 @@ public String getResourceId() {
public void setResourceId(String resourceId) {
this.resourceId = resourceId;
}
@SuppressWarnings("Unused")
public String getTimeToLive() {
return timeToLive;
}
@SuppressWarnings("Unused")
public void setTimeToLive(String timeToLive) {
this.timeToLive = timeToLive;
}
}
}

0 comments on commit 566a999

Please sign in to comment.