odata.msgraph.client.security.complex.MailboxEvidence Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of odata-client-msgraph Show documentation
Show all versions of odata-client-msgraph Show documentation
Java client for use with the Microsoft Graph v1.0 endpoint
package odata.msgraph.client.security.complex;
import com.fasterxml.jackson.annotation.JsonAnyGetter;
import com.fasterxml.jackson.annotation.JsonAnySetter;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonInclude.Include;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.github.davidmoten.odata.client.ODataType;
import com.github.davidmoten.odata.client.UnmappedFields;
import com.github.davidmoten.odata.client.Util;
import com.github.davidmoten.odata.client.annotation.Property;
import com.github.davidmoten.odata.client.internal.ChangedFields;
import com.github.davidmoten.odata.client.internal.UnmappedFieldsImpl;
import java.lang.Object;
import java.lang.Override;
import java.lang.String;
import java.lang.StringBuilder;
import java.time.OffsetDateTime;
import java.util.Arrays;
import java.util.List;
import java.util.Optional;
import odata.msgraph.client.security.enums.EvidenceRemediationStatus;
import odata.msgraph.client.security.enums.EvidenceRole;
import odata.msgraph.client.security.enums.EvidenceVerdict;
@JsonPropertyOrder({
"@odata.type",
"displayName",
"primaryAddress",
"userAccount"})
@JsonInclude(Include.NON_NULL)
public class MailboxEvidence extends AlertEvidence implements ODataType {
@JsonProperty("displayName")
protected String displayName;
@JsonProperty("primaryAddress")
protected String primaryAddress;
@JsonProperty("userAccount")
protected UserAccount userAccount;
protected MailboxEvidence() {
super();
}
@Override
public String odataTypeName() {
return "microsoft.graph.security.mailboxEvidence";
}
@Property(name="displayName")
@JsonIgnore
public Optional getDisplayName() {
return Optional.ofNullable(displayName);
}
public MailboxEvidence withDisplayName(String displayName) {
MailboxEvidence _x = _copy();
_x.odataType = Util.nvl(odataType, "microsoft.graph.security.mailboxEvidence");
_x.displayName = displayName;
return _x;
}
@Property(name="primaryAddress")
@JsonIgnore
public Optional getPrimaryAddress() {
return Optional.ofNullable(primaryAddress);
}
public MailboxEvidence withPrimaryAddress(String primaryAddress) {
MailboxEvidence _x = _copy();
_x.odataType = Util.nvl(odataType, "microsoft.graph.security.mailboxEvidence");
_x.primaryAddress = primaryAddress;
return _x;
}
@Property(name="userAccount")
@JsonIgnore
public Optional getUserAccount() {
return Optional.ofNullable(userAccount);
}
public MailboxEvidence withUserAccount(UserAccount userAccount) {
MailboxEvidence _x = _copy();
_x.odataType = Util.nvl(odataType, "microsoft.graph.security.mailboxEvidence");
_x.userAccount = userAccount;
return _x;
}
public MailboxEvidence withUnmappedField(String name, Object value) {
MailboxEvidence _x = _copy();
_x.setUnmappedField(name, value);
return _x;
}
@JsonAnySetter
private void setUnmappedField(String name, Object value) {
if (unmappedFields == null) {
unmappedFields = new UnmappedFieldsImpl();
}
unmappedFields.put(name, value);
}
@JsonAnyGetter
private UnmappedFieldsImpl unmappedFields() {
return unmappedFields == null ? UnmappedFieldsImpl.EMPTY : unmappedFields;
}
@Override
public UnmappedFields getUnmappedFields() {
return unmappedFields();
}
@Override
public void postInject(boolean addKeysToContextPath) {
// do nothing;
}
/**
* Returns a builder which is used to create a new
* instance of this class (given that this class is immutable).
*
* @return a new Builder for this class
*/
// Suffix used on builder factory method to differentiate the method
// from static builder methods on superclasses
public static Builder builderMailboxEvidence() {
return new Builder();
}
public static final class Builder {
private OffsetDateTime createdDateTime;
private List detailedRoles;
private String detailedRolesNextLink;
private EvidenceRemediationStatus remediationStatus;
private String remediationStatusDetails;
private List roles;
private String rolesNextLink;
private List tags;
private String tagsNextLink;
private EvidenceVerdict verdict;
private String displayName;
private String primaryAddress;
private UserAccount userAccount;
private ChangedFields changedFields = ChangedFields.EMPTY;
Builder() {
// prevent instantiation
}
public Builder createdDateTime(OffsetDateTime createdDateTime) {
this.createdDateTime = createdDateTime;
this.changedFields = changedFields.add("createdDateTime");
return this;
}
public Builder detailedRoles(List detailedRoles) {
this.detailedRoles = detailedRoles;
this.changedFields = changedFields.add("detailedRoles");
return this;
}
public Builder detailedRoles(String... detailedRoles) {
return detailedRoles(Arrays.asList(detailedRoles));
}
public Builder detailedRolesNextLink(String detailedRolesNextLink) {
this.detailedRolesNextLink = detailedRolesNextLink;
this.changedFields = changedFields.add("detailedRoles");
return this;
}
public Builder remediationStatus(EvidenceRemediationStatus remediationStatus) {
this.remediationStatus = remediationStatus;
this.changedFields = changedFields.add("remediationStatus");
return this;
}
public Builder remediationStatusDetails(String remediationStatusDetails) {
this.remediationStatusDetails = remediationStatusDetails;
this.changedFields = changedFields.add("remediationStatusDetails");
return this;
}
public Builder roles(List roles) {
this.roles = roles;
this.changedFields = changedFields.add("roles");
return this;
}
public Builder roles(EvidenceRole... roles) {
return roles(Arrays.asList(roles));
}
public Builder rolesNextLink(String rolesNextLink) {
this.rolesNextLink = rolesNextLink;
this.changedFields = changedFields.add("roles");
return this;
}
public Builder tags(List tags) {
this.tags = tags;
this.changedFields = changedFields.add("tags");
return this;
}
public Builder tags(String... tags) {
return tags(Arrays.asList(tags));
}
public Builder tagsNextLink(String tagsNextLink) {
this.tagsNextLink = tagsNextLink;
this.changedFields = changedFields.add("tags");
return this;
}
public Builder verdict(EvidenceVerdict verdict) {
this.verdict = verdict;
this.changedFields = changedFields.add("verdict");
return this;
}
public Builder displayName(String displayName) {
this.displayName = displayName;
this.changedFields = changedFields.add("displayName");
return this;
}
public Builder primaryAddress(String primaryAddress) {
this.primaryAddress = primaryAddress;
this.changedFields = changedFields.add("primaryAddress");
return this;
}
public Builder userAccount(UserAccount userAccount) {
this.userAccount = userAccount;
this.changedFields = changedFields.add("userAccount");
return this;
}
public MailboxEvidence build() {
MailboxEvidence _x = new MailboxEvidence();
_x.contextPath = null;
_x.unmappedFields = new UnmappedFieldsImpl();
_x.odataType = "microsoft.graph.security.mailboxEvidence";
_x.createdDateTime = createdDateTime;
_x.detailedRoles = detailedRoles;
_x.detailedRolesNextLink = detailedRolesNextLink;
_x.remediationStatus = remediationStatus;
_x.remediationStatusDetails = remediationStatusDetails;
_x.roles = roles;
_x.rolesNextLink = rolesNextLink;
_x.tags = tags;
_x.tagsNextLink = tagsNextLink;
_x.verdict = verdict;
_x.displayName = displayName;
_x.primaryAddress = primaryAddress;
_x.userAccount = userAccount;
return _x;
}
}
private MailboxEvidence _copy() {
MailboxEvidence _x = new MailboxEvidence();
_x.contextPath = contextPath;
_x.unmappedFields = unmappedFields.copy();
_x.odataType = odataType;
_x.createdDateTime = createdDateTime;
_x.detailedRoles = detailedRoles;
_x.remediationStatus = remediationStatus;
_x.remediationStatusDetails = remediationStatusDetails;
_x.roles = roles;
_x.tags = tags;
_x.verdict = verdict;
_x.displayName = displayName;
_x.primaryAddress = primaryAddress;
_x.userAccount = userAccount;
return _x;
}
@Override
public String toString() {
StringBuilder b = new StringBuilder();
b.append("MailboxEvidence[");
b.append("createdDateTime=");
b.append(this.createdDateTime);
b.append(", ");
b.append("detailedRoles=");
b.append(this.detailedRoles);
b.append(", ");
b.append("remediationStatus=");
b.append(this.remediationStatus);
b.append(", ");
b.append("remediationStatusDetails=");
b.append(this.remediationStatusDetails);
b.append(", ");
b.append("roles=");
b.append(this.roles);
b.append(", ");
b.append("tags=");
b.append(this.tags);
b.append(", ");
b.append("verdict=");
b.append(this.verdict);
b.append(", ");
b.append("displayName=");
b.append(this.displayName);
b.append(", ");
b.append("primaryAddress=");
b.append(this.primaryAddress);
b.append(", ");
b.append("userAccount=");
b.append(this.userAccount);
b.append("]");
b.append(",unmappedFields=");
b.append(unmappedFields);
b.append(",odataType=");
b.append(odataType);
return b.toString();
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy