machine-identities/src/PSSailpoint.MachineIdentities/Model/AnomalyEvidenceTimestamp.ps1
|
# # Identity Security Cloud API - Machine Identities # Use these APIs to interact with the Identity Security Cloud platform to achieve repeatable, automated processes with greater scalability. We encourage you to join the SailPoint Developer Community forum at https://developer.sailpoint.com/discuss to connect with other developers using our APIs. # Version: v1 # Generated by OpenAPI Generator: https://openapi-generator.tech # <# .SYNOPSIS No summary available. .DESCRIPTION Timestamp block for an anomaly's evidence. .PARAMETER At Point-in-time the evidence was captured. .PARAMETER VarFrom Start of the aggregation window for time-window detections (SIEM); null for point-in-time detections (SENTINEL). .OUTPUTS AnomalyEvidenceTimestamp<PSCustomObject> #> function Initialize-AnomalyEvidenceTimestamp { [CmdletBinding()] Param ( [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[System.DateTime]] ${At}, [Parameter(ValueFromPipelineByPropertyName = $true)] [System.Nullable[System.DateTime]] ${VarFrom} ) Process { 'Creating PSCustomObject: PSSailpoint.MachineIdentities => AnomalyEvidenceTimestamp' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $PSO = [PSCustomObject]@{ "at" = ${At} "from" = ${VarFrom} } return $PSO } } <# .SYNOPSIS Convert from JSON to AnomalyEvidenceTimestamp<PSCustomObject> .DESCRIPTION Convert from JSON to AnomalyEvidenceTimestamp<PSCustomObject> .PARAMETER Json Json object .OUTPUTS AnomalyEvidenceTimestamp<PSCustomObject> #> function ConvertFrom-JsonToAnomalyEvidenceTimestamp { Param( [AllowEmptyString()] [string]$Json ) Process { 'Converting JSON to PSCustomObject: PSSailpoint.MachineIdentities => AnomalyEvidenceTimestamp' | Write-Debug $PSBoundParameters | Out-DebugParameter | Write-Debug $JsonParameters = ConvertFrom-Json -InputObject $Json # check if Json contains properties not defined in AnomalyEvidenceTimestamp $AllProperties = ("at", "from") foreach ($name in $JsonParameters.PsObject.Properties.Name) { if (!($AllProperties.Contains($name))) { throw "Error! JSON key '$name' not found in the properties: $($AllProperties)" } } if (!([bool]($JsonParameters.PSobject.Properties.name -match "at"))) { #optional property not found $At = $null } else { $At = $JsonParameters.PSobject.Properties["at"].value } if (!([bool]($JsonParameters.PSobject.Properties.name -match "from"))) { #optional property not found $VarFrom = $null } else { $VarFrom = $JsonParameters.PSobject.Properties["from"].value } $PSO = [PSCustomObject]@{ "at" = ${At} "from" = ${VarFrom} } return $PSO } } |