com.oracle.bmc.announcementsservice.model.NotificationsSummary Maven / Gradle / Ivy
/**
* Copyright (c) 2016, 2024, Oracle and/or its affiliates. All rights reserved.
* This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license.
*/
package com.oracle.bmc.announcementsservice.model;
/**
* Summary of notification object, return by List API
* Note: Objects should always be created or deserialized using the {@link Builder}. This model
* distinguishes fields that are {@code null} because they are unset from fields that are explicitly
* set to {@code null}. This is done in the setter methods of the {@link Builder}, which maintain a
* set of all explicitly set fields called {@link Builder#__explicitlySet__}. The {@link
* #hashCode()} and {@link #equals(Object)} methods are implemented to take the explicitly set
* fields into account. The constructor, on the other hand, does not take the explicitly set fields
* into account (since the constructor cannot distinguish explicit {@code null} from unset {@code
* null}).
*/
@jakarta.annotation.Generated(value = "OracleSDKGenerator", comments = "API Version: 0.0.1")
@com.fasterxml.jackson.databind.annotation.JsonDeserialize(
builder = NotificationsSummary.Builder.class)
@com.fasterxml.jackson.annotation.JsonTypeInfo(
use = com.fasterxml.jackson.annotation.JsonTypeInfo.Id.NAME,
include = com.fasterxml.jackson.annotation.JsonTypeInfo.As.PROPERTY,
property = "type")
@com.fasterxml.jackson.annotation.JsonFilter(
com.oracle.bmc.http.client.internal.ExplicitlySetBmcModel.EXPLICITLY_SET_FILTER_NAME)
public final class NotificationsSummary extends BaseService {
@com.fasterxml.jackson.databind.annotation.JsonPOJOBuilder(withPrefix = "")
public static class Builder {
@com.fasterxml.jackson.annotation.JsonProperty("id")
private String id;
public Builder id(String id) {
this.id = id;
this.__explicitlySet__.add("id");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("serviceName")
private String serviceName;
public Builder serviceName(String serviceName) {
this.serviceName = serviceName;
this.__explicitlySet__.add("serviceName");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("shortName")
private String shortName;
public Builder shortName(String shortName) {
this.shortName = shortName;
this.__explicitlySet__.add("shortName");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("teamName")
private String teamName;
public Builder teamName(String teamName) {
this.teamName = teamName;
this.__explicitlySet__.add("teamName");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("platformType")
private PlatformType platformType;
public Builder platformType(PlatformType platformType) {
this.platformType = platformType;
this.__explicitlySet__.add("platformType");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("commsManagerName")
private CommsManagerName commsManagerName;
public Builder commsManagerName(CommsManagerName commsManagerName) {
this.commsManagerName = commsManagerName;
this.__explicitlySet__.add("commsManagerName");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("excludedRealms")
private java.util.List excludedRealms;
public Builder excludedRealms(java.util.List excludedRealms) {
this.excludedRealms = excludedRealms;
this.__explicitlySet__.add("excludedRealms");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("previousServiceNames")
private java.util.List previousServiceNames;
public Builder previousServiceNames(java.util.List previousServiceNames) {
this.previousServiceNames = previousServiceNames;
this.__explicitlySet__.add("previousServiceNames");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("timeCreated")
private java.util.Date timeCreated;
public Builder timeCreated(java.util.Date timeCreated) {
this.timeCreated = timeCreated;
this.__explicitlySet__.add("timeCreated");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("timeUpdated")
private java.util.Date timeUpdated;
public Builder timeUpdated(java.util.Date timeUpdated) {
this.timeUpdated = timeUpdated;
this.__explicitlySet__.add("timeUpdated");
return this;
}
@com.fasterxml.jackson.annotation.JsonProperty("lifecycleState")
private LifecycleState lifecycleState;
public Builder lifecycleState(LifecycleState lifecycleState) {
this.lifecycleState = lifecycleState;
this.__explicitlySet__.add("lifecycleState");
return this;
}
@com.fasterxml.jackson.annotation.JsonIgnore
private final java.util.Set __explicitlySet__ = new java.util.HashSet();
public NotificationsSummary build() {
NotificationsSummary model =
new NotificationsSummary(
this.id,
this.serviceName,
this.shortName,
this.teamName,
this.platformType,
this.commsManagerName,
this.excludedRealms,
this.previousServiceNames,
this.timeCreated,
this.timeUpdated,
this.lifecycleState);
for (String explicitlySetProperty : this.__explicitlySet__) {
model.markPropertyAsExplicitlySet(explicitlySetProperty);
}
return model;
}
@com.fasterxml.jackson.annotation.JsonIgnore
public Builder copy(NotificationsSummary model) {
if (model.wasPropertyExplicitlySet("id")) {
this.id(model.getId());
}
if (model.wasPropertyExplicitlySet("serviceName")) {
this.serviceName(model.getServiceName());
}
if (model.wasPropertyExplicitlySet("shortName")) {
this.shortName(model.getShortName());
}
if (model.wasPropertyExplicitlySet("teamName")) {
this.teamName(model.getTeamName());
}
if (model.wasPropertyExplicitlySet("platformType")) {
this.platformType(model.getPlatformType());
}
if (model.wasPropertyExplicitlySet("commsManagerName")) {
this.commsManagerName(model.getCommsManagerName());
}
if (model.wasPropertyExplicitlySet("excludedRealms")) {
this.excludedRealms(model.getExcludedRealms());
}
if (model.wasPropertyExplicitlySet("previousServiceNames")) {
this.previousServiceNames(model.getPreviousServiceNames());
}
if (model.wasPropertyExplicitlySet("timeCreated")) {
this.timeCreated(model.getTimeCreated());
}
if (model.wasPropertyExplicitlySet("timeUpdated")) {
this.timeUpdated(model.getTimeUpdated());
}
if (model.wasPropertyExplicitlySet("lifecycleState")) {
this.lifecycleState(model.getLifecycleState());
}
return this;
}
}
/** Create a new builder. */
public static Builder builder() {
return new Builder();
}
public Builder toBuilder() {
return new Builder().copy(this);
}
@Deprecated
public NotificationsSummary(
String id,
String serviceName,
String shortName,
String teamName,
PlatformType platformType,
CommsManagerName commsManagerName,
java.util.List excludedRealms,
java.util.List previousServiceNames,
java.util.Date timeCreated,
java.util.Date timeUpdated,
LifecycleState lifecycleState) {
super(
id,
serviceName,
shortName,
teamName,
platformType,
commsManagerName,
excludedRealms,
previousServiceNames,
timeCreated,
timeUpdated,
lifecycleState);
}
@Override
public String toString() {
return this.toString(true);
}
/**
* Return a string representation of the object.
*
* @param includeByteArrayContents true to include the full contents of byte arrays
* @return string representation
*/
public String toString(boolean includeByteArrayContents) {
java.lang.StringBuilder sb = new java.lang.StringBuilder();
sb.append("NotificationsSummary(");
sb.append("super=").append(super.toString(includeByteArrayContents));
sb.append(")");
return sb.toString();
}
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (!(o instanceof NotificationsSummary)) {
return false;
}
NotificationsSummary other = (NotificationsSummary) o;
return super.equals(other);
}
@Override
public int hashCode() {
final int PRIME = 59;
int result = super.hashCode();
return result;
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy