Class DeviceHealthScript

  • All Implemented Interfaces:
    com.github.davidmoten.odata.client.ODataEntityType, com.github.davidmoten.odata.client.ODataType

    public class DeviceHealthScript
    extends Entity
    implements com.github.davidmoten.odata.client.ODataEntityType
    “Intune will provide customer the ability to run their Powershell Health scripts (remediation + detection) on the enrolled windows 10 Azure Active Directory joined devices.”
    • Field Detail

      • description

        protected String description
      • detectionScriptContent

        protected byte[] detectionScriptContent
      • detectionScriptParametersNextLink

        protected String detectionScriptParametersNextLink
      • displayName

        protected String displayName
      • enforceSignatureCheck

        protected Boolean enforceSignatureCheck
      • highestAvailableVersion

        protected String highestAvailableVersion
      • isGlobalScript

        protected Boolean isGlobalScript
      • publisher

        protected String publisher
      • remediationScriptContent

        protected byte[] remediationScriptContent
      • remediationScriptParametersNextLink

        protected String remediationScriptParametersNextLink
      • roleScopeTagIds

        protected List<String> roleScopeTagIds
      • roleScopeTagIdsNextLink

        protected String roleScopeTagIdsNextLink
      • runAs32Bit

        protected Boolean runAs32Bit
      • version

        protected String version
    • Constructor Detail

      • DeviceHealthScript

        protected DeviceHealthScript()
    • Method Detail

      • odataTypeName

        public String odataTypeName()
        Specified by:
        odataTypeName in interface com.github.davidmoten.odata.client.ODataType
        Overrides:
        odataTypeName in class Entity
      • builderDeviceHealthScript

        public static DeviceHealthScript.Builder builderDeviceHealthScript()
        Returns a builder which is used to create a new instance of this class (given that this class is immutable).
        Returns:
        a new Builder for this class
      • getChangedFields

        public com.github.davidmoten.odata.client.internal.ChangedFields getChangedFields()
        Specified by:
        getChangedFields in interface com.github.davidmoten.odata.client.ODataEntityType
        Overrides:
        getChangedFields in class Entity
      • postInject

        public void postInject​(boolean addKeysToContextPath)
        Specified by:
        postInject in interface com.github.davidmoten.odata.client.ODataType
        Overrides:
        postInject in class Entity
      • getCreatedDateTime

        public Optional<OffsetDateTime> getCreatedDateTime()
        “The timestamp of when the device health script was created. This property is read-only.”

        Org.OData.Core.V1.Computed

        true

        Org.OData.Core.V1.Permissions

        Returns:
        property createdDateTime
      • withCreatedDateTime

        public DeviceHealthScript withCreatedDateTime​(OffsetDateTime createdDateTime)
        Returns an immutable copy of this with just the createdDateTime 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “The timestamp of when the device health script was created. This property is read-only.”

        Org.OData.Core.V1.Computed

        true

        Org.OData.Core.V1.Permissions

        Parameters:
        createdDateTime - new value of createdDateTime field (as defined in service metadata)
        Returns:
        immutable copy of this with just the createdDateTime field changed
      • getDescription

        public Optional<String> getDescription()
        “Description of the device health script”
        Returns:
        property description
      • withDescription

        public DeviceHealthScript withDescription​(String description)
        Returns an immutable copy of this with just the description 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “Description of the device health script”

        Parameters:
        description - new value of description field (as defined in service metadata)
        Returns:
        immutable copy of this with just the description field changed
      • getDetectionScriptContent

        public Optional<byte[]> getDetectionScriptContent()
        “The entire content of the detection powershell script”
        Returns:
        property detectionScriptContent
      • withDetectionScriptContent

        public DeviceHealthScript withDetectionScriptContent​(byte[] detectionScriptContent)
        Returns an immutable copy of this with just the detectionScriptContent 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “The entire content of the detection powershell script”

        Parameters:
        detectionScriptContent - new value of detectionScriptContent field (as defined in service metadata)
        Returns:
        immutable copy of this with just the detectionScriptContent field changed
      • getDetectionScriptParameters

        public com.github.davidmoten.odata.client.CollectionPage<DeviceHealthScriptParameter> getDetectionScriptParameters()
        “List of ComplexType DetectionScriptParameters objects.”
        Returns:
        property detectionScriptParameters
      • withDetectionScriptParameters

        public DeviceHealthScript withDetectionScriptParameters​(List<DeviceHealthScriptParameter> detectionScriptParameters)
        Returns an immutable copy of this with just the detectionScriptParameters 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “List of ComplexType DetectionScriptParameters objects.”

        Parameters:
        detectionScriptParameters - new value of detectionScriptParameters field (as defined in service metadata)
        Returns:
        immutable copy of this with just the detectionScriptParameters field changed
      • getDetectionScriptParameters

        public com.github.davidmoten.odata.client.CollectionPage<DeviceHealthScriptParameter> getDetectionScriptParameters​(com.github.davidmoten.odata.client.HttpRequestOptions options)
        “List of ComplexType DetectionScriptParameters objects.”
        Parameters:
        options - specify connect and read timeouts
        Returns:
        property detectionScriptParameters
      • getDisplayName

        public Optional<String> getDisplayName()
        “Name of the device health script”
        Returns:
        property displayName
      • withDisplayName

        public DeviceHealthScript withDisplayName​(String displayName)
        Returns an immutable copy of this with just the displayName 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “Name of the device health script”

        Parameters:
        displayName - new value of displayName field (as defined in service metadata)
        Returns:
        immutable copy of this with just the displayName field changed
      • getEnforceSignatureCheck

        public Optional<Boolean> getEnforceSignatureCheck()
        “Indicate whether the script signature needs be checked”
        Returns:
        property enforceSignatureCheck
      • withEnforceSignatureCheck

        public DeviceHealthScript withEnforceSignatureCheck​(Boolean enforceSignatureCheck)
        Returns an immutable copy of this with just the enforceSignatureCheck 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “Indicate whether the script signature needs be checked”

        Parameters:
        enforceSignatureCheck - new value of enforceSignatureCheck field (as defined in service metadata)
        Returns:
        immutable copy of this with just the enforceSignatureCheck field changed
      • getHighestAvailableVersion

        public Optional<String> getHighestAvailableVersion()
        “Highest available version for a Microsoft Proprietary script”
        Returns:
        property highestAvailableVersion
      • withHighestAvailableVersion

        public DeviceHealthScript withHighestAvailableVersion​(String highestAvailableVersion)
        Returns an immutable copy of this with just the highestAvailableVersion 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “Highest available version for a Microsoft Proprietary script”

        Parameters:
        highestAvailableVersion - new value of highestAvailableVersion field (as defined in service metadata)
        Returns:
        immutable copy of this with just the highestAvailableVersion field changed
      • getIsGlobalScript

        public Optional<Boolean> getIsGlobalScript()
        “Determines if this is Microsoft Proprietary Script. Proprietary scripts are read -only”
        Returns:
        property isGlobalScript
      • withIsGlobalScript

        public DeviceHealthScript withIsGlobalScript​(Boolean isGlobalScript)
        Returns an immutable copy of this with just the isGlobalScript 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “Determines if this is Microsoft Proprietary Script. Proprietary scripts are read -only”

        Parameters:
        isGlobalScript - new value of isGlobalScript field (as defined in service metadata)
        Returns:
        immutable copy of this with just the isGlobalScript field changed
      • getLastModifiedDateTime

        public Optional<OffsetDateTime> getLastModifiedDateTime()
        “The timestamp of when the device health script was modified. This property is read-only.”

        Org.OData.Core.V1.Computed

        true

        Org.OData.Core.V1.Permissions

        Returns:
        property lastModifiedDateTime
      • withLastModifiedDateTime

        public DeviceHealthScript withLastModifiedDateTime​(OffsetDateTime lastModifiedDateTime)
        Returns an immutable copy of this with just the lastModifiedDateTime 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “The timestamp of when the device health script was modified. This property is read-only.”

        Org.OData.Core.V1.Computed

        true

        Org.OData.Core.V1.Permissions

        Parameters:
        lastModifiedDateTime - new value of lastModifiedDateTime field (as defined in service metadata)
        Returns:
        immutable copy of this with just the lastModifiedDateTime field changed
      • getPublisher

        public Optional<String> getPublisher()
        “Name of the device health script publisher”
        Returns:
        property publisher
      • withPublisher

        public DeviceHealthScript withPublisher​(String publisher)
        Returns an immutable copy of this with just the publisher 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “Name of the device health script publisher”

        Parameters:
        publisher - new value of publisher field (as defined in service metadata)
        Returns:
        immutable copy of this with just the publisher field changed
      • getRemediationScriptContent

        public Optional<byte[]> getRemediationScriptContent()
        “The entire content of the remediation powershell script”
        Returns:
        property remediationScriptContent
      • withRemediationScriptContent

        public DeviceHealthScript withRemediationScriptContent​(byte[] remediationScriptContent)
        Returns an immutable copy of this with just the remediationScriptContent 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “The entire content of the remediation powershell script”

        Parameters:
        remediationScriptContent - new value of remediationScriptContent field (as defined in service metadata)
        Returns:
        immutable copy of this with just the remediationScriptContent field changed
      • getRemediationScriptParameters

        public com.github.davidmoten.odata.client.CollectionPage<DeviceHealthScriptParameter> getRemediationScriptParameters()
        “List of ComplexType RemediationScriptParameters objects.”
        Returns:
        property remediationScriptParameters
      • withRemediationScriptParameters

        public DeviceHealthScript withRemediationScriptParameters​(List<DeviceHealthScriptParameter> remediationScriptParameters)
        Returns an immutable copy of this with just the remediationScriptParameters 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “List of ComplexType RemediationScriptParameters objects.”

        Parameters:
        remediationScriptParameters - new value of remediationScriptParameters field (as defined in service metadata)
        Returns:
        immutable copy of this with just the remediationScriptParameters field changed
      • getRemediationScriptParameters

        public com.github.davidmoten.odata.client.CollectionPage<DeviceHealthScriptParameter> getRemediationScriptParameters​(com.github.davidmoten.odata.client.HttpRequestOptions options)
        “List of ComplexType RemediationScriptParameters objects.”
        Parameters:
        options - specify connect and read timeouts
        Returns:
        property remediationScriptParameters
      • getRoleScopeTagIds

        public com.github.davidmoten.odata.client.CollectionPage<String> getRoleScopeTagIds()
        “List of Scope Tag IDs for the device health script”
        Returns:
        property roleScopeTagIds
      • withRoleScopeTagIds

        public DeviceHealthScript withRoleScopeTagIds​(List<String> roleScopeTagIds)
        Returns an immutable copy of this with just the roleScopeTagIds 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “List of Scope Tag IDs for the device health script”

        Parameters:
        roleScopeTagIds - new value of roleScopeTagIds field (as defined in service metadata)
        Returns:
        immutable copy of this with just the roleScopeTagIds field changed
      • getRoleScopeTagIds

        public com.github.davidmoten.odata.client.CollectionPage<String> getRoleScopeTagIds​(com.github.davidmoten.odata.client.HttpRequestOptions options)
        “List of Scope Tag IDs for the device health script”
        Parameters:
        options - specify connect and read timeouts
        Returns:
        property roleScopeTagIds
      • getRunAs32Bit

        public Optional<Boolean> getRunAs32Bit()
        “Indicate whether PowerShell script(s) should run as 32-bit”
        Returns:
        property runAs32Bit
      • withRunAs32Bit

        public DeviceHealthScript withRunAs32Bit​(Boolean runAs32Bit)
        Returns an immutable copy of this with just the runAs32Bit 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “Indicate whether PowerShell script(s) should run as 32-bit”

        Parameters:
        runAs32Bit - new value of runAs32Bit field (as defined in service metadata)
        Returns:
        immutable copy of this with just the runAs32Bit field changed
      • getRunAsAccount

        public Optional<RunAsAccountType> getRunAsAccount()
        “Indicates the type of execution context”
        Returns:
        property runAsAccount
      • withRunAsAccount

        public DeviceHealthScript withRunAsAccount​(RunAsAccountType runAsAccount)
        Returns an immutable copy of this with just the runAsAccount 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 this. patch() is called (if available)on the returned object only the changed fields are submitted.

        “Indicates the type of execution context”

        Parameters:
        runAsAccount - new value of runAsAccount field (as defined in service metadata)
        Returns:
        immutable copy of this with just the runAsAccount field changed
      • getVersion

        public Optional<String> getVersion()
        “Version of the device health script”
        Returns:
        property version
      • withVersion

        public DeviceHealthScript withVersion​(String version)
        Returns an immutable copy of this with just the version 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 this.patch() is called (if available)on the returned object only the changed fields are submitted.

        “Version of the device health script”

        Parameters:
        version - new value of version field (as defined in service metadata)
        Returns:
        immutable copy of this with just the version field changed
      • getUnmappedFields

        public com.github.davidmoten.odata.client.UnmappedFields getUnmappedFields()
        Specified by:
        getUnmappedFields in interface com.github.davidmoten.odata.client.ODataType
        Overrides:
        getUnmappedFields in class Entity
      • patch

        public DeviceHealthScript patch()
        Submits only changed fields for update and returns an immutable copy of this with changed fields reset.
        Overrides:
        patch in class Entity
        Returns:
        a copy of this with changed fields reset
        Throws:
        com.github.davidmoten.odata.client.ClientException - if HTTP response is not as expected
      • put

        public DeviceHealthScript put()
        Submits all fields for update and returns an immutable copy of this with changed fields reset (they were ignored anyway).
        Overrides:
        put in class Entity
        Returns:
        a copy of this with changed fields reset
        Throws:
        com.github.davidmoten.odata.client.ClientException - if HTTP response is not as expected
      • getGlobalScriptHighestAvailableVersion

        public com.github.davidmoten.odata.client.ActionRequestReturningNonCollection<String> getGlobalScriptHighestAvailableVersion()
      • updateGlobalScript

        public com.github.davidmoten.odata.client.ActionRequestReturningNonCollection<String> updateGlobalScript​(String version)