com.clinia.model.common.V1Meta Maven / Gradle / Ivy
// Code generated by OpenAPI Generator (https://openapi-generator.tech), manual changes will be lost
// - read more on https://github.com/clinia/api-clients-generation. DO NOT EDIT.
package com.clinia.model.common;
import com.fasterxml.jackson.annotation.*;
import com.fasterxml.jackson.databind.annotation.*;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
/** V1Meta */
public class V1Meta {
@JsonProperty("createdAt")
private OffsetDateTime createdAt;
@JsonProperty("identifier")
private List identifier;
@JsonProperty("source")
private String source;
@JsonProperty("updatedAt")
private OffsetDateTime updatedAt;
public V1Meta setCreatedAt(OffsetDateTime createdAt) {
this.createdAt = createdAt;
return this;
}
/** Instant of creation of the resource. */
@javax.annotation.Nullable
public OffsetDateTime getCreatedAt() {
return createdAt;
}
public V1Meta setIdentifier(List identifier) {
this.identifier = identifier;
return this;
}
public V1Meta addIdentifier(V1Identifier identifierItem) {
if (this.identifier == null) {
this.identifier = new ArrayList<>();
}
this.identifier.add(identifierItem);
return this;
}
/**
* Identifiers of the resource. Note: Combination of `source`, `value` and `use` must be unique.
*/
@javax.annotation.Nullable
public List getIdentifier() {
return identifier;
}
/** The source of the resource. */
@javax.annotation.Nullable
public String getSource() {
return source;
}
public V1Meta setUpdatedAt(OffsetDateTime updatedAt) {
this.updatedAt = updatedAt;
return this;
}
/** Last update of the resource. */
@javax.annotation.Nullable
public OffsetDateTime getUpdatedAt() {
return updatedAt;
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
V1Meta v1Meta = (V1Meta) o;
return (
Objects.equals(this.createdAt, v1Meta.createdAt) &&
Objects.equals(this.identifier, v1Meta.identifier) &&
Objects.equals(this.source, v1Meta.source) &&
Objects.equals(this.updatedAt, v1Meta.updatedAt)
);
}
@Override
public int hashCode() {
return Objects.hash(createdAt, identifier, source, updatedAt);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class V1Meta {\n");
sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n");
sb.append(" identifier: ").append(toIndentedString(identifier)).append("\n");
sb.append(" source: ").append(toIndentedString(source)).append("\n");
sb.append(" updatedAt: ").append(toIndentedString(updatedAt)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces (except the first line).
*/
private String toIndentedString(Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}