All Downloads are FREE. Search and download functionalities are using the official Maven repository.

odata.msgraph.client.identitygovernance.entity.TaskReport Maven / Gradle / Ivy

There is a newer version: 0.2.2
Show newest version
package odata.msgraph.client.identitygovernance.entity;

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.ClientException;
import com.github.davidmoten.odata.client.NameValue;
import com.github.davidmoten.odata.client.ODataEntityType;
import com.github.davidmoten.odata.client.RequestOptions;
import com.github.davidmoten.odata.client.UnmappedFields;
import com.github.davidmoten.odata.client.Util;
import com.github.davidmoten.odata.client.annotation.NavigationProperty;
import com.github.davidmoten.odata.client.annotation.Property;
import com.github.davidmoten.odata.client.internal.ChangedFields;
import com.github.davidmoten.odata.client.internal.RequestHelper;
import com.github.davidmoten.odata.client.internal.UnmappedFieldsImpl;

import java.lang.Integer;
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.entity.Entity;
import odata.msgraph.client.identitygovernance.entity.collection.request.TaskProcessingResultCollectionRequest;
import odata.msgraph.client.identitygovernance.entity.request.TaskDefinitionRequest;
import odata.msgraph.client.identitygovernance.entity.request.TaskRequest;
import odata.msgraph.client.identitygovernance.enums.LifecycleWorkflowProcessingStatus;


/**
 * 

* Org.OData.Capabilities.V1.CountRestrictions *

* Countable = true *

* Org.OData.Capabilities.V1.ExpandRestrictions *

* Expandable = true *

* Org.OData.Capabilities.V1.FilterRestrictions *

* Filterable = true *

* Org.OData.Capabilities.V1.SearchRestrictions *

* Searchable = false *

* Org.OData.Capabilities.V1.SelectRestrictions *

* Selectable = false *

* Org.OData.Capabilities.V1.SkipSupported *

* false *

* Org.OData.Capabilities.V1.SortRestrictions *

* Sortable = true *

* Org.OData.Capabilities.V1.TopSupported *

* false */@JsonPropertyOrder({ "@odata.type", "completedDateTime", "failedUsersCount", "lastUpdatedDateTime", "processingStatus", "runId", "startedDateTime", "successfulUsersCount", "totalUsersCount", "unprocessedUsersCount", "taskProcessingResults"}) @JsonInclude(Include.NON_NULL) public class TaskReport extends Entity implements ODataEntityType { @Override public String odataTypeName() { return "microsoft.graph.identityGovernance.taskReport"; } @JsonProperty("completedDateTime") protected OffsetDateTime completedDateTime; @JsonProperty("failedUsersCount") protected Integer failedUsersCount; @JsonProperty("lastUpdatedDateTime") protected OffsetDateTime lastUpdatedDateTime; @JsonProperty("processingStatus") protected LifecycleWorkflowProcessingStatus processingStatus; @JsonProperty("runId") protected String runId; @JsonProperty("startedDateTime") protected OffsetDateTime startedDateTime; @JsonProperty("successfulUsersCount") protected Integer successfulUsersCount; @JsonProperty("totalUsersCount") protected Integer totalUsersCount; @JsonProperty("unprocessedUsersCount") protected Integer unprocessedUsersCount; @JsonProperty("taskProcessingResults") protected List taskProcessingResults; protected TaskReport() { super(); } /** * 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 builderTaskReport() { return new Builder(); } public static final class Builder { private String id; private OffsetDateTime completedDateTime; private Integer failedUsersCount; private OffsetDateTime lastUpdatedDateTime; private LifecycleWorkflowProcessingStatus processingStatus; private String runId; private OffsetDateTime startedDateTime; private Integer successfulUsersCount; private Integer totalUsersCount; private Integer unprocessedUsersCount; private List taskProcessingResults; private ChangedFields changedFields = ChangedFields.EMPTY; Builder() { // prevent instantiation } public Builder id(String id) { this.id = id; this.changedFields = changedFields.add("id"); return this; } public Builder completedDateTime(OffsetDateTime completedDateTime) { this.completedDateTime = completedDateTime; this.changedFields = changedFields.add("completedDateTime"); return this; } public Builder failedUsersCount(Integer failedUsersCount) { this.failedUsersCount = failedUsersCount; this.changedFields = changedFields.add("failedUsersCount"); return this; } public Builder lastUpdatedDateTime(OffsetDateTime lastUpdatedDateTime) { this.lastUpdatedDateTime = lastUpdatedDateTime; this.changedFields = changedFields.add("lastUpdatedDateTime"); return this; } public Builder processingStatus(LifecycleWorkflowProcessingStatus processingStatus) { this.processingStatus = processingStatus; this.changedFields = changedFields.add("processingStatus"); return this; } public Builder runId(String runId) { this.runId = runId; this.changedFields = changedFields.add("runId"); return this; } public Builder startedDateTime(OffsetDateTime startedDateTime) { this.startedDateTime = startedDateTime; this.changedFields = changedFields.add("startedDateTime"); return this; } public Builder successfulUsersCount(Integer successfulUsersCount) { this.successfulUsersCount = successfulUsersCount; this.changedFields = changedFields.add("successfulUsersCount"); return this; } public Builder totalUsersCount(Integer totalUsersCount) { this.totalUsersCount = totalUsersCount; this.changedFields = changedFields.add("totalUsersCount"); return this; } public Builder unprocessedUsersCount(Integer unprocessedUsersCount) { this.unprocessedUsersCount = unprocessedUsersCount; this.changedFields = changedFields.add("unprocessedUsersCount"); return this; } /** *

* Org.OData.Capabilities.V1.DeleteRestrictions *

* Deletable = false *

* Org.OData.Capabilities.V1.InsertRestrictions *

* Insertable = false *

* Org.OData.Capabilities.V1.UpdateRestrictions *

* Updatable = false * * @param taskProcessingResults * value of {@code taskProcessingResults} property (as defined in service metadata) * @return {@code this} (for method chaining) */ public Builder taskProcessingResults(List taskProcessingResults) { this.taskProcessingResults = taskProcessingResults; this.changedFields = changedFields.add("taskProcessingResults"); return this; } /** *

* Org.OData.Capabilities.V1.DeleteRestrictions *

* Deletable = false *

* Org.OData.Capabilities.V1.InsertRestrictions *

* Insertable = false *

* Org.OData.Capabilities.V1.UpdateRestrictions *

* Updatable = false * * @param taskProcessingResults * value of {@code taskProcessingResults} property (as defined in service metadata) * @return {@code this} (for method chaining) */ public Builder taskProcessingResults(TaskProcessingResult... taskProcessingResults) { return taskProcessingResults(Arrays.asList(taskProcessingResults)); } public TaskReport build() { TaskReport _x = new TaskReport(); _x.contextPath = null; _x.changedFields = changedFields; _x.unmappedFields = new UnmappedFieldsImpl(); _x.odataType = "microsoft.graph.identityGovernance.taskReport"; _x.id = id; _x.completedDateTime = completedDateTime; _x.failedUsersCount = failedUsersCount; _x.lastUpdatedDateTime = lastUpdatedDateTime; _x.processingStatus = processingStatus; _x.runId = runId; _x.startedDateTime = startedDateTime; _x.successfulUsersCount = successfulUsersCount; _x.totalUsersCount = totalUsersCount; _x.unprocessedUsersCount = unprocessedUsersCount; _x.taskProcessingResults = taskProcessingResults; return _x; } } @Override @JsonIgnore public ChangedFields getChangedFields() { return changedFields; } @Override public void postInject(boolean addKeysToContextPath) { if (addKeysToContextPath && id != null) { contextPath = contextPath.clearQueries().addKeys(new NameValue(id, String.class)); } } @Property(name="completedDateTime") @JsonIgnore public Optional getCompletedDateTime() { return Optional.ofNullable(completedDateTime); } public TaskReport withCompletedDateTime(OffsetDateTime completedDateTime) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("completedDateTime"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.completedDateTime = completedDateTime; return _x; } @Property(name="failedUsersCount") @JsonIgnore public Optional getFailedUsersCount() { return Optional.ofNullable(failedUsersCount); } public TaskReport withFailedUsersCount(Integer failedUsersCount) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("failedUsersCount"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.failedUsersCount = failedUsersCount; return _x; } @Property(name="lastUpdatedDateTime") @JsonIgnore public Optional getLastUpdatedDateTime() { return Optional.ofNullable(lastUpdatedDateTime); } public TaskReport withLastUpdatedDateTime(OffsetDateTime lastUpdatedDateTime) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("lastUpdatedDateTime"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.lastUpdatedDateTime = lastUpdatedDateTime; return _x; } @Property(name="processingStatus") @JsonIgnore public Optional getProcessingStatus() { return Optional.ofNullable(processingStatus); } public TaskReport withProcessingStatus(LifecycleWorkflowProcessingStatus processingStatus) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("processingStatus"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.processingStatus = processingStatus; return _x; } @Property(name="runId") @JsonIgnore public Optional getRunId() { return Optional.ofNullable(runId); } public TaskReport withRunId(String runId) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("runId"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.runId = runId; return _x; } @Property(name="startedDateTime") @JsonIgnore public Optional getStartedDateTime() { return Optional.ofNullable(startedDateTime); } public TaskReport withStartedDateTime(OffsetDateTime startedDateTime) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("startedDateTime"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.startedDateTime = startedDateTime; return _x; } @Property(name="successfulUsersCount") @JsonIgnore public Optional getSuccessfulUsersCount() { return Optional.ofNullable(successfulUsersCount); } public TaskReport withSuccessfulUsersCount(Integer successfulUsersCount) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("successfulUsersCount"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.successfulUsersCount = successfulUsersCount; return _x; } @Property(name="totalUsersCount") @JsonIgnore public Optional getTotalUsersCount() { return Optional.ofNullable(totalUsersCount); } public TaskReport withTotalUsersCount(Integer totalUsersCount) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("totalUsersCount"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.totalUsersCount = totalUsersCount; return _x; } @Property(name="unprocessedUsersCount") @JsonIgnore public Optional getUnprocessedUsersCount() { return Optional.ofNullable(unprocessedUsersCount); } public TaskReport withUnprocessedUsersCount(Integer unprocessedUsersCount) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("unprocessedUsersCount"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.unprocessedUsersCount = unprocessedUsersCount; return _x; } public TaskReport withUnmappedField(String name, Object value) { TaskReport _x = _copy(); _x.setUnmappedField(name, value); return _x; } @NavigationProperty(name="task") @JsonIgnore public TaskRequest getTask() { return new TaskRequest(contextPath.addSegment("task"), RequestHelper.getValue(unmappedFields, "task")); } /** *

* Org.OData.Capabilities.V1.InsertRestrictions *

* Insertable = false *

* Org.OData.Capabilities.V1.UpdateRestrictions *

* Updatable = false * * @return navigational property taskDefinition */ @NavigationProperty(name="taskDefinition") @JsonIgnore public TaskDefinitionRequest getTaskDefinition() { return new TaskDefinitionRequest(contextPath.addSegment("taskDefinition"), RequestHelper.getValue(unmappedFields, "taskDefinition")); } /** *

* Org.OData.Capabilities.V1.DeleteRestrictions *

* Deletable = false *

* Org.OData.Capabilities.V1.InsertRestrictions *

* Insertable = false *

* Org.OData.Capabilities.V1.UpdateRestrictions *

* Updatable = false * * @return navigational property taskProcessingResults */ @NavigationProperty(name="taskProcessingResults") @JsonIgnore public TaskProcessingResultCollectionRequest getTaskProcessingResults() { return new TaskProcessingResultCollectionRequest( contextPath.addSegment("taskProcessingResults"), Optional.ofNullable(taskProcessingResults)); } /** * Returns an immutable copy of {@code this} with just the {@code * taskProcessingResults} field changed. Field description below. The field name is * also added to an internal map of changed fields in the returned object so that * when {@code this.patch()} is called (if available)on the returned object only * the changed fields are submitted. *

* Org.OData.Capabilities.V1.DeleteRestrictions *

* Deletable = false *

* Org.OData.Capabilities.V1.InsertRestrictions *

* Insertable = false *

* Org.OData.Capabilities.V1.UpdateRestrictions *

* Updatable = false * * @param taskProcessingResults * new value of {@code taskProcessingResults} field (as defined in service metadata) * @return immutable copy of {@code this} with just the {@code taskProcessingResults} field changed */ public TaskReport withTaskProcessingResults(List taskProcessingResults) { TaskReport _x = _copy(); _x.changedFields = changedFields.add("taskProcessingResults"); _x.odataType = Util.nvl(odataType, "microsoft.graph.identityGovernance.taskReport"); _x.taskProcessingResults = taskProcessingResults; 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(); } /** * Submits only changed fields for update and returns an * immutable copy of {@code this} with changed fields reset. * * @return a copy of {@code this} with changed fields reset * @throws ClientException if HTTP response is not as expected */ public TaskReport patch() { RequestHelper.patch(this, contextPath, RequestOptions.EMPTY); TaskReport _x = _copy(); _x.changedFields = null; return _x; } /** * Submits all fields for update and returns an immutable copy of {@code this} * with changed fields reset (they were ignored anyway). * * @return a copy of {@code this} with changed fields reset * @throws ClientException if HTTP response is not as expected */ public TaskReport put() { RequestHelper.put(this, contextPath, RequestOptions.EMPTY); TaskReport _x = _copy(); _x.changedFields = null; return _x; } private TaskReport _copy() { TaskReport _x = new TaskReport(); _x.contextPath = contextPath; _x.changedFields = changedFields; _x.unmappedFields = unmappedFields.copy(); _x.odataType = odataType; _x.id = id; _x.completedDateTime = completedDateTime; _x.failedUsersCount = failedUsersCount; _x.lastUpdatedDateTime = lastUpdatedDateTime; _x.processingStatus = processingStatus; _x.runId = runId; _x.startedDateTime = startedDateTime; _x.successfulUsersCount = successfulUsersCount; _x.totalUsersCount = totalUsersCount; _x.unprocessedUsersCount = unprocessedUsersCount; _x.taskProcessingResults = taskProcessingResults; return _x; } @Override public String toString() { StringBuilder b = new StringBuilder(); b.append("TaskReport["); b.append("id="); b.append(this.id); b.append(", "); b.append("completedDateTime="); b.append(this.completedDateTime); b.append(", "); b.append("failedUsersCount="); b.append(this.failedUsersCount); b.append(", "); b.append("lastUpdatedDateTime="); b.append(this.lastUpdatedDateTime); b.append(", "); b.append("processingStatus="); b.append(this.processingStatus); b.append(", "); b.append("runId="); b.append(this.runId); b.append(", "); b.append("startedDateTime="); b.append(this.startedDateTime); b.append(", "); b.append("successfulUsersCount="); b.append(this.successfulUsersCount); b.append(", "); b.append("totalUsersCount="); b.append(this.totalUsersCount); b.append(", "); b.append("unprocessedUsersCount="); b.append(this.unprocessedUsersCount); b.append(", "); b.append("taskProcessingResults="); b.append(this.taskProcessingResults); b.append("]"); b.append(",unmappedFields="); b.append(unmappedFields); b.append(",odataType="); b.append(odataType); return b.toString(); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy