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

odata.msgraph.client.complex.WindowsMalwareExecutionStateCount Maven / Gradle / Ivy

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

import com.fasterxml.jackson.annotation.JacksonInject;
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.ContextPath;
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.Integer;
import java.lang.Object;
import java.lang.Override;
import java.lang.String;
import java.lang.StringBuilder;
import java.time.OffsetDateTime;
import java.util.Optional;

import odata.msgraph.client.enums.WindowsMalwareExecutionState;


/**
 * “Windows malware execution state summary.”
 */@JsonPropertyOrder({
    "@odata.type", 
    "deviceCount", 
    "executionState", 
    "lastUpdateDateTime"})
@JsonInclude(Include.NON_NULL)
public class WindowsMalwareExecutionStateCount implements ODataType {

    @JacksonInject
    @JsonIgnore
    protected ContextPath contextPath;

    @JacksonInject
    @JsonIgnore
    protected UnmappedFieldsImpl unmappedFields;

    @JsonProperty("@odata.type")
    protected String odataType;

    @JsonProperty("deviceCount")
    protected Integer deviceCount;

    @JsonProperty("executionState")
    protected WindowsMalwareExecutionState executionState;

    @JsonProperty("lastUpdateDateTime")
    protected OffsetDateTime lastUpdateDateTime;

    protected WindowsMalwareExecutionStateCount() {
    }

    @Override
    public String odataTypeName() {
        return "microsoft.graph.windowsMalwareExecutionStateCount";
    }

    /**
     * “Count of devices with malware detections for this malware execution state”
     * 
     * @return property deviceCount
     */
    @Property(name="deviceCount")
    @JsonIgnore
    public Optional getDeviceCount() {
        return Optional.ofNullable(deviceCount);
    }

    /**
     * Returns an immutable copy of {@code this} with just the {@code deviceCount}
     * 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.
     * 

* “Count of devices with malware detections for this malware execution state” * * @param deviceCount * new value of {@code deviceCount} field (as defined in service metadata) * @return immutable copy of {@code this} with just the {@code deviceCount} field changed */ public WindowsMalwareExecutionStateCount withDeviceCount(Integer deviceCount) { WindowsMalwareExecutionStateCount _x = _copy(); _x.odataType = Util.nvl(odataType, "microsoft.graph.windowsMalwareExecutionStateCount"); _x.deviceCount = deviceCount; return _x; } /** * “Malware execution state. Possible values are: unknown, blocked, allowed, running * , notRunning. Defaults to unkonwn. Computed.” * * @return property executionState */ @Property(name="executionState") @JsonIgnore public Optional getExecutionState() { return Optional.ofNullable(executionState); } /** * Returns an immutable copy of {@code this} with just the {@code executionState} * 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. *

* “Malware execution state. Possible values are: unknown, blocked, allowed, running * , notRunning. Defaults to unkonwn. Computed.” * * @param executionState * new value of {@code executionState} field (as defined in service metadata) * @return immutable copy of {@code this} with just the {@code executionState} field changed */ public WindowsMalwareExecutionStateCount withExecutionState(WindowsMalwareExecutionState executionState) { WindowsMalwareExecutionStateCount _x = _copy(); _x.odataType = Util.nvl(odataType, "microsoft.graph.windowsMalwareExecutionStateCount"); _x.executionState = executionState; return _x; } /** * “The Timestamp of the last update for the device count in UTC” * * @return property lastUpdateDateTime */ @Property(name="lastUpdateDateTime") @JsonIgnore public Optional getLastUpdateDateTime() { return Optional.ofNullable(lastUpdateDateTime); } /** * Returns an immutable copy of {@code this} with just the {@code * lastUpdateDateTime} 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. *

* “The Timestamp of the last update for the device count in UTC” * * @param lastUpdateDateTime * new value of {@code lastUpdateDateTime} field (as defined in service metadata) * @return immutable copy of {@code this} with just the {@code lastUpdateDateTime} field changed */ public WindowsMalwareExecutionStateCount withLastUpdateDateTime(OffsetDateTime lastUpdateDateTime) { WindowsMalwareExecutionStateCount _x = _copy(); _x.odataType = Util.nvl(odataType, "microsoft.graph.windowsMalwareExecutionStateCount"); _x.lastUpdateDateTime = lastUpdateDateTime; return _x; } public WindowsMalwareExecutionStateCount withUnmappedField(String name, Object value) { WindowsMalwareExecutionStateCount _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 builder() { return new Builder(); } public static final class Builder { private Integer deviceCount; private WindowsMalwareExecutionState executionState; private OffsetDateTime lastUpdateDateTime; private ChangedFields changedFields = ChangedFields.EMPTY; Builder() { // prevent instantiation } /** * “Count of devices with malware detections for this malware execution state” * * @param deviceCount * value of {@code deviceCount} property (as defined in service metadata) * @return {@code this} (for method chaining) */ public Builder deviceCount(Integer deviceCount) { this.deviceCount = deviceCount; this.changedFields = changedFields.add("deviceCount"); return this; } /** * “Malware execution state. Possible values are: unknown, blocked, allowed, running * , notRunning. Defaults to unkonwn. Computed.” * * @param executionState * value of {@code executionState} property (as defined in service metadata) * @return {@code this} (for method chaining) */ public Builder executionState(WindowsMalwareExecutionState executionState) { this.executionState = executionState; this.changedFields = changedFields.add("executionState"); return this; } /** * “The Timestamp of the last update for the device count in UTC” * * @param lastUpdateDateTime * value of {@code lastUpdateDateTime} property (as defined in service metadata) * @return {@code this} (for method chaining) */ public Builder lastUpdateDateTime(OffsetDateTime lastUpdateDateTime) { this.lastUpdateDateTime = lastUpdateDateTime; this.changedFields = changedFields.add("lastUpdateDateTime"); return this; } public WindowsMalwareExecutionStateCount build() { WindowsMalwareExecutionStateCount _x = new WindowsMalwareExecutionStateCount(); _x.contextPath = null; _x.unmappedFields = new UnmappedFieldsImpl(); _x.odataType = "microsoft.graph.windowsMalwareExecutionStateCount"; _x.deviceCount = deviceCount; _x.executionState = executionState; _x.lastUpdateDateTime = lastUpdateDateTime; return _x; } } private WindowsMalwareExecutionStateCount _copy() { WindowsMalwareExecutionStateCount _x = new WindowsMalwareExecutionStateCount(); _x.contextPath = contextPath; _x.unmappedFields = unmappedFields.copy(); _x.odataType = odataType; _x.deviceCount = deviceCount; _x.executionState = executionState; _x.lastUpdateDateTime = lastUpdateDateTime; return _x; } @Override public String toString() { StringBuilder b = new StringBuilder(); b.append("WindowsMalwareExecutionStateCount["); b.append("deviceCount="); b.append(this.deviceCount); b.append(", "); b.append("executionState="); b.append(this.executionState); b.append(", "); b.append("lastUpdateDateTime="); b.append(this.lastUpdateDateTime); b.append("]"); b.append(",unmappedFields="); b.append(unmappedFields); b.append(",odataType="); b.append(odataType); return b.toString(); } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy