net.leanix.mtm.api.models.Notification Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of leanix-mtm-sdk-java Show documentation
Show all versions of leanix-mtm-sdk-java Show documentation
SDK for Java to access leanIX MTM REST API
/*
* MTM
* Multi-tenancy-manager for LeanIX. Manages accounts, contracts, users, workspaces, permissions, and more.
*
* OpenAPI spec version: 1.6.348
*
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package net.leanix.mtm.api.models;
import java.util.Objects;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.time.OffsetDateTime;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
import net.leanix.mtm.api.models.NotificationTemplate;
import net.leanix.mtm.api.models.User;
/**
* Notification
*/
public class Notification {
@JsonProperty("id")
private String id = null;
@JsonProperty("subject")
private String subject = null;
@JsonProperty("i18NSubjects")
private Map i18NSubjects = null;
@JsonProperty("subjectAggregated")
private String subjectAggregated = null;
@JsonProperty("i18NSubjectsAggregated")
private Map i18NSubjectsAggregated = null;
/**
* Gets or Sets status
*/
public enum StatusEnum {
READ("READ"),
UNREAD("UNREAD");
private String value;
StatusEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static StatusEnum fromValue(String text) {
for (StatusEnum b : StatusEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("status")
private StatusEnum status = null;
@JsonProperty("createdAt")
private OffsetDateTime createdAt = null;
@JsonProperty("workspaceId")
private String workspaceId = null;
@JsonProperty("recipient")
private User recipient = null;
@JsonProperty("recipientCc")
private User recipientCc = null;
@JsonProperty("type")
private String type = null;
@JsonProperty("templates")
private String templates = null;
@JsonProperty("i18NTemplates")
private Map> i18NTemplates = null;
@JsonProperty("payload")
private String payload = null;
/**
* Gets or Sets priority
*/
public enum PriorityEnum {
HIGH("HIGH"),
MEDIUM("MEDIUM"),
LOW("LOW");
private String value;
PriorityEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static PriorityEnum fromValue(String text) {
for (PriorityEnum b : PriorityEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("priority")
private PriorityEnum priority = null;
/**
* Gets or Sets transmissionStatus
*/
public enum TransmissionStatusEnum {
UNSENT("UNSENT"),
SENT("SENT"),
RESENT("RESENT"),
FAILED("FAILED"),
REJECTED("REJECTED"),
IGNORED("IGNORED");
private String value;
TransmissionStatusEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static TransmissionStatusEnum fromValue(String text) {
for (TransmissionStatusEnum b : TransmissionStatusEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("transmissionStatus")
private TransmissionStatusEnum transmissionStatus = null;
@JsonProperty("failCount")
private Integer failCount = null;
/**
* Gets or Sets origin
*/
public enum OriginEnum {
MTM("MTM"),
EXTERNAL("EXTERNAL");
private String value;
OriginEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static OriginEnum fromValue(String text) {
for (OriginEnum b : OriginEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("origin")
private OriginEnum origin = null;
@JsonProperty("fromAddress")
private String fromAddress = null;
/**
* Gets or Sets rules
*/
public enum RulesEnum {
CONTACTS("ACCEPT_CONTACTS"),
INVITED("ACCEPT_INVITED");
private String value;
RulesEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static RulesEnum fromValue(String text) {
for (RulesEnum b : RulesEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("rules")
private List rules = null;
@JsonProperty("sentAt")
private Long sentAt = null;
/**
* Gets or Sets emailChannelType
*/
public enum EmailChannelTypeEnum {
POSTFIX_MAILJET("POSTFIX_MAILJET"),
CUSTOM_SMTP("CUSTOM_SMTP"),
MAILGUN("MAILGUN");
private String value;
EmailChannelTypeEnum(String value) {
this.value = value;
}
@JsonValue
public String getValue() {
return value;
}
@Override
public String toString() {
return String.valueOf(value);
}
@JsonCreator
public static EmailChannelTypeEnum fromValue(String text) {
for (EmailChannelTypeEnum b : EmailChannelTypeEnum.values()) {
if (String.valueOf(b.value).equals(text)) {
return b;
}
}
return null;
}
}
@JsonProperty("emailChannelType")
private EmailChannelTypeEnum emailChannelType = null;
@JsonProperty("mailgunId")
private String mailgunId = null;
public Notification id(String id) {
this.id = id;
return this;
}
/**
* Get id
* @return id
**/
@ApiModelProperty(value = "")
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public Notification subject(String subject) {
this.subject = subject;
return this;
}
/**
* Get subject
* @return subject
**/
@ApiModelProperty(value = "")
public String getSubject() {
return subject;
}
public void setSubject(String subject) {
this.subject = subject;
}
public Notification i18NSubjects(Map i18NSubjects) {
this.i18NSubjects = i18NSubjects;
return this;
}
public Notification putI18NSubjectsItem(String key, String i18NSubjectsItem) {
if (this.i18NSubjects == null) {
this.i18NSubjects = new HashMap();
}
this.i18NSubjects.put(key, i18NSubjectsItem);
return this;
}
/**
* Get i18NSubjects
* @return i18NSubjects
**/
@ApiModelProperty(value = "")
public Map getI18NSubjects() {
return i18NSubjects;
}
public void setI18NSubjects(Map i18NSubjects) {
this.i18NSubjects = i18NSubjects;
}
public Notification subjectAggregated(String subjectAggregated) {
this.subjectAggregated = subjectAggregated;
return this;
}
/**
* Get subjectAggregated
* @return subjectAggregated
**/
@ApiModelProperty(value = "")
public String getSubjectAggregated() {
return subjectAggregated;
}
public void setSubjectAggregated(String subjectAggregated) {
this.subjectAggregated = subjectAggregated;
}
public Notification i18NSubjectsAggregated(Map i18NSubjectsAggregated) {
this.i18NSubjectsAggregated = i18NSubjectsAggregated;
return this;
}
public Notification putI18NSubjectsAggregatedItem(String key, String i18NSubjectsAggregatedItem) {
if (this.i18NSubjectsAggregated == null) {
this.i18NSubjectsAggregated = new HashMap();
}
this.i18NSubjectsAggregated.put(key, i18NSubjectsAggregatedItem);
return this;
}
/**
* Get i18NSubjectsAggregated
* @return i18NSubjectsAggregated
**/
@ApiModelProperty(value = "")
public Map getI18NSubjectsAggregated() {
return i18NSubjectsAggregated;
}
public void setI18NSubjectsAggregated(Map i18NSubjectsAggregated) {
this.i18NSubjectsAggregated = i18NSubjectsAggregated;
}
public Notification status(StatusEnum status) {
this.status = status;
return this;
}
/**
* Get status
* @return status
**/
@ApiModelProperty(value = "")
public StatusEnum getStatus() {
return status;
}
public void setStatus(StatusEnum status) {
this.status = status;
}
public Notification createdAt(OffsetDateTime createdAt) {
this.createdAt = createdAt;
return this;
}
/**
* Get createdAt
* @return createdAt
**/
@ApiModelProperty(value = "")
public OffsetDateTime getCreatedAt() {
return createdAt;
}
public void setCreatedAt(OffsetDateTime createdAt) {
this.createdAt = createdAt;
}
public Notification workspaceId(String workspaceId) {
this.workspaceId = workspaceId;
return this;
}
/**
* Get workspaceId
* @return workspaceId
**/
@ApiModelProperty(value = "")
public String getWorkspaceId() {
return workspaceId;
}
public void setWorkspaceId(String workspaceId) {
this.workspaceId = workspaceId;
}
public Notification recipient(User recipient) {
this.recipient = recipient;
return this;
}
/**
* Get recipient
* @return recipient
**/
@ApiModelProperty(required = true, value = "")
public User getRecipient() {
return recipient;
}
public void setRecipient(User recipient) {
this.recipient = recipient;
}
public Notification recipientCc(User recipientCc) {
this.recipientCc = recipientCc;
return this;
}
/**
* Get recipientCc
* @return recipientCc
**/
@ApiModelProperty(value = "")
public User getRecipientCc() {
return recipientCc;
}
public void setRecipientCc(User recipientCc) {
this.recipientCc = recipientCc;
}
public Notification type(String type) {
this.type = type;
return this;
}
/**
* Get type
* @return type
**/
@ApiModelProperty(value = "")
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public Notification templates(String templates) {
this.templates = templates;
return this;
}
/**
* Get templates
* @return templates
**/
@ApiModelProperty(value = "")
public String getTemplates() {
return templates;
}
public void setTemplates(String templates) {
this.templates = templates;
}
public Notification i18NTemplates(Map> i18NTemplates) {
this.i18NTemplates = i18NTemplates;
return this;
}
public Notification putI18NTemplatesItem(String key, Map i18NTemplatesItem) {
if (this.i18NTemplates == null) {
this.i18NTemplates = new HashMap>();
}
this.i18NTemplates.put(key, i18NTemplatesItem);
return this;
}
/**
* Get i18NTemplates
* @return i18NTemplates
**/
@ApiModelProperty(value = "")
public Map> getI18NTemplates() {
return i18NTemplates;
}
public void setI18NTemplates(Map> i18NTemplates) {
this.i18NTemplates = i18NTemplates;
}
public Notification payload(String payload) {
this.payload = payload;
return this;
}
/**
* Get payload
* @return payload
**/
@ApiModelProperty(value = "")
public String getPayload() {
return payload;
}
public void setPayload(String payload) {
this.payload = payload;
}
public Notification priority(PriorityEnum priority) {
this.priority = priority;
return this;
}
/**
* Get priority
* @return priority
**/
@ApiModelProperty(value = "")
public PriorityEnum getPriority() {
return priority;
}
public void setPriority(PriorityEnum priority) {
this.priority = priority;
}
public Notification transmissionStatus(TransmissionStatusEnum transmissionStatus) {
this.transmissionStatus = transmissionStatus;
return this;
}
/**
* Get transmissionStatus
* @return transmissionStatus
**/
@ApiModelProperty(value = "")
public TransmissionStatusEnum getTransmissionStatus() {
return transmissionStatus;
}
public void setTransmissionStatus(TransmissionStatusEnum transmissionStatus) {
this.transmissionStatus = transmissionStatus;
}
public Notification failCount(Integer failCount) {
this.failCount = failCount;
return this;
}
/**
* Get failCount
* @return failCount
**/
@ApiModelProperty(value = "")
public Integer getFailCount() {
return failCount;
}
public void setFailCount(Integer failCount) {
this.failCount = failCount;
}
public Notification origin(OriginEnum origin) {
this.origin = origin;
return this;
}
/**
* Get origin
* @return origin
**/
@ApiModelProperty(value = "")
public OriginEnum getOrigin() {
return origin;
}
public void setOrigin(OriginEnum origin) {
this.origin = origin;
}
public Notification fromAddress(String fromAddress) {
this.fromAddress = fromAddress;
return this;
}
/**
* Get fromAddress
* @return fromAddress
**/
@ApiModelProperty(value = "")
public String getFromAddress() {
return fromAddress;
}
public void setFromAddress(String fromAddress) {
this.fromAddress = fromAddress;
}
public Notification rules(List rules) {
this.rules = rules;
return this;
}
public Notification addRulesItem(RulesEnum rulesItem) {
if (this.rules == null) {
this.rules = new ArrayList();
}
this.rules.add(rulesItem);
return this;
}
/**
* Get rules
* @return rules
**/
@ApiModelProperty(value = "")
public List getRules() {
return rules;
}
public void setRules(List rules) {
this.rules = rules;
}
public Notification sentAt(Long sentAt) {
this.sentAt = sentAt;
return this;
}
/**
* Get sentAt
* @return sentAt
**/
@ApiModelProperty(value = "")
public Long getSentAt() {
return sentAt;
}
public void setSentAt(Long sentAt) {
this.sentAt = sentAt;
}
public Notification emailChannelType(EmailChannelTypeEnum emailChannelType) {
this.emailChannelType = emailChannelType;
return this;
}
/**
* Get emailChannelType
* @return emailChannelType
**/
@ApiModelProperty(value = "")
public EmailChannelTypeEnum getEmailChannelType() {
return emailChannelType;
}
public void setEmailChannelType(EmailChannelTypeEnum emailChannelType) {
this.emailChannelType = emailChannelType;
}
public Notification mailgunId(String mailgunId) {
this.mailgunId = mailgunId;
return this;
}
/**
* Get mailgunId
* @return mailgunId
**/
@ApiModelProperty(value = "")
public String getMailgunId() {
return mailgunId;
}
public void setMailgunId(String mailgunId) {
this.mailgunId = mailgunId;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Notification notification = (Notification) o;
return Objects.equals(this.id, notification.id) &&
Objects.equals(this.subject, notification.subject) &&
Objects.equals(this.i18NSubjects, notification.i18NSubjects) &&
Objects.equals(this.subjectAggregated, notification.subjectAggregated) &&
Objects.equals(this.i18NSubjectsAggregated, notification.i18NSubjectsAggregated) &&
Objects.equals(this.status, notification.status) &&
Objects.equals(this.createdAt, notification.createdAt) &&
Objects.equals(this.workspaceId, notification.workspaceId) &&
Objects.equals(this.recipient, notification.recipient) &&
Objects.equals(this.recipientCc, notification.recipientCc) &&
Objects.equals(this.type, notification.type) &&
Objects.equals(this.templates, notification.templates) &&
Objects.equals(this.i18NTemplates, notification.i18NTemplates) &&
Objects.equals(this.payload, notification.payload) &&
Objects.equals(this.priority, notification.priority) &&
Objects.equals(this.transmissionStatus, notification.transmissionStatus) &&
Objects.equals(this.failCount, notification.failCount) &&
Objects.equals(this.origin, notification.origin) &&
Objects.equals(this.fromAddress, notification.fromAddress) &&
Objects.equals(this.rules, notification.rules) &&
Objects.equals(this.sentAt, notification.sentAt) &&
Objects.equals(this.emailChannelType, notification.emailChannelType) &&
Objects.equals(this.mailgunId, notification.mailgunId);
}
@Override
public int hashCode() {
return Objects.hash(id, subject, i18NSubjects, subjectAggregated, i18NSubjectsAggregated, status, createdAt, workspaceId, recipient, recipientCc, type, templates, i18NTemplates, payload, priority, transmissionStatus, failCount, origin, fromAddress, rules, sentAt, emailChannelType, mailgunId);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Notification {\n");
sb.append(" id: ").append(toIndentedString(id)).append("\n");
sb.append(" subject: ").append(toIndentedString(subject)).append("\n");
sb.append(" i18NSubjects: ").append(toIndentedString(i18NSubjects)).append("\n");
sb.append(" subjectAggregated: ").append(toIndentedString(subjectAggregated)).append("\n");
sb.append(" i18NSubjectsAggregated: ").append(toIndentedString(i18NSubjectsAggregated)).append("\n");
sb.append(" status: ").append(toIndentedString(status)).append("\n");
sb.append(" createdAt: ").append(toIndentedString(createdAt)).append("\n");
sb.append(" workspaceId: ").append(toIndentedString(workspaceId)).append("\n");
sb.append(" recipient: ").append(toIndentedString(recipient)).append("\n");
sb.append(" recipientCc: ").append(toIndentedString(recipientCc)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" templates: ").append(toIndentedString(templates)).append("\n");
sb.append(" i18NTemplates: ").append(toIndentedString(i18NTemplates)).append("\n");
sb.append(" payload: ").append(toIndentedString(payload)).append("\n");
sb.append(" priority: ").append(toIndentedString(priority)).append("\n");
sb.append(" transmissionStatus: ").append(toIndentedString(transmissionStatus)).append("\n");
sb.append(" failCount: ").append(toIndentedString(failCount)).append("\n");
sb.append(" origin: ").append(toIndentedString(origin)).append("\n");
sb.append(" fromAddress: ").append(toIndentedString(fromAddress)).append("\n");
sb.append(" rules: ").append(toIndentedString(rules)).append("\n");
sb.append(" sentAt: ").append(toIndentedString(sentAt)).append("\n");
sb.append(" emailChannelType: ").append(toIndentedString(emailChannelType)).append("\n");
sb.append(" mailgunId: ").append(toIndentedString(mailgunId)).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(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy