/*
* Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved.
*
* Licensed under the Apache License, Version 2.0 (the "License").
* You may not use this file except in compliance with the License.
* A copy of the License is located at
*
* http://aws.amazon.com/apache2.0
*
* or in the "license" file accompanying this file. This file is distributed
* on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
* express or implied. See the License for the specific language governing
* permissions and limitations under the License.
*/
/*
* Do not modify this file. This file is generated from the iot-2015-05-28.normal.json service model.
*/
using System;
using System.Collections.Generic;
using System.Xml.Serialization;
using System.Text;
using System.IO;
using System.Net;
using Amazon.Runtime;
using Amazon.Runtime.Internal;
namespace Amazon.IoT.Model
{
///
/// Container for the parameters to the ListViolationEvents operation.
/// Lists the Device Defender security profile violations discovered during the given
/// time period. You can use filters to limit the results to those alerts issued for a
/// particular security profile, behavior, or thing (device).
///
///
///
/// Requires permission to access the ListViolationEvents
/// action.
///
///
public partial class ListViolationEventsRequest : AmazonIoTRequest
{
private BehaviorCriteriaType _behaviorCriteriaType;
private DateTime? _endTimeUtc;
private bool? _listSuppressedAlerts;
private int? _maxResults;
private string _nextToken;
private string _securityProfileName;
private DateTime? _startTimeUtc;
private string _thingName;
private VerificationState _verificationState;
///
/// Gets and sets the property BehaviorCriteriaType.
///
/// The criteria for a behavior.
///
///
public BehaviorCriteriaType BehaviorCriteriaType
{
get { return this._behaviorCriteriaType; }
set { this._behaviorCriteriaType = value; }
}
// Check to see if BehaviorCriteriaType property is set
internal bool IsSetBehaviorCriteriaType()
{
return this._behaviorCriteriaType != null;
}
///
/// Gets and sets the property EndTimeUtc.
///
/// The end time for the alerts to be listed.
///
///
[AWSProperty(Required=true)]
public DateTime EndTimeUtc
{
get { return this._endTimeUtc.GetValueOrDefault(); }
set { this._endTime = this._endTimeUtc = value; }
}
// Check to see if EndTimeUtc property is set
internal bool IsSetEndTimeUtc()
{
return this._endTimeUtc.HasValue;
}
///
/// Gets and sets the property ListSuppressedAlerts.
///
/// A list of all suppressed alerts.
///
///
public bool ListSuppressedAlerts
{
get { return this._listSuppressedAlerts.GetValueOrDefault(); }
set { this._listSuppressedAlerts = value; }
}
// Check to see if ListSuppressedAlerts property is set
internal bool IsSetListSuppressedAlerts()
{
return this._listSuppressedAlerts.HasValue;
}
///
/// Gets and sets the property MaxResults.
///
/// The maximum number of results to return at one time.
///
///
[AWSProperty(Min=1, Max=250)]
public int MaxResults
{
get { return this._maxResults.GetValueOrDefault(); }
set { this._maxResults = value; }
}
// Check to see if MaxResults property is set
internal bool IsSetMaxResults()
{
return this._maxResults.HasValue;
}
///
/// Gets and sets the property NextToken.
///
/// The token for the next set of results.
///
///
public string NextToken
{
get { return this._nextToken; }
set { this._nextToken = value; }
}
// Check to see if NextToken property is set
internal bool IsSetNextToken()
{
return this._nextToken != null;
}
///
/// Gets and sets the property SecurityProfileName.
///
/// A filter to limit results to those alerts generated by the specified security profile.
///
///
[AWSProperty(Min=1, Max=128)]
public string SecurityProfileName
{
get { return this._securityProfileName; }
set { this._securityProfileName = value; }
}
// Check to see if SecurityProfileName property is set
internal bool IsSetSecurityProfileName()
{
return this._securityProfileName != null;
}
///
/// Gets and sets the property StartTimeUtc.
///
/// The start time for the alerts to be listed.
///
///
[AWSProperty(Required=true)]
public DateTime StartTimeUtc
{
get { return this._startTimeUtc.GetValueOrDefault(); }
set { this._startTime = this._startTimeUtc = value; }
}
// Check to see if StartTimeUtc property is set
internal bool IsSetStartTimeUtc()
{
return this._startTimeUtc.HasValue;
}
///
/// Gets and sets the property ThingName.
///
/// A filter to limit results to those alerts caused by the specified thing.
///
///
[AWSProperty(Min=1, Max=128)]
public string ThingName
{
get { return this._thingName; }
set { this._thingName = value; }
}
// Check to see if ThingName property is set
internal bool IsSetThingName()
{
return this._thingName != null;
}
///
/// Gets and sets the property VerificationState.
///
/// The verification state of the violation (detect alarm).
///
///
public VerificationState VerificationState
{
get { return this._verificationState; }
set { this._verificationState = value; }
}
// Check to see if VerificationState property is set
internal bool IsSetVerificationState()
{
return this._verificationState != null;
}
#region Backwards compatible properties
private DateTime? _endTime;
private DateTime? _startTime;
///
/// Gets and sets the property EndTimeUtc.
///
/// This property is deprecated. Setting this property results in non-UTC DateTimes not
/// being marshalled correctly. Use EndTimeUtc instead. Setting either EndTime or EndTimeUtc
/// results in both EndTime and EndTimeUtc being assigned, the latest assignment to either
/// one of the two property is reflected in the value of both. EndTime is provided for
/// backwards compatibility only and assigning a non-Utc DateTime to it results in the
/// wrong timestamp being passed to the service.
///
///
///
/// The end time for the alerts to be listed.
///
///
[Obsolete("Setting this property results in non-UTC DateTimes not being marshalled correctly. " +
"Use EndTimeUtc instead. Setting either EndTime or EndTimeUtc results in both EndTime and " +
"EndTimeUtc being assigned, the latest assignment to either one of the two property is " +
"reflected in the value of both. EndTime is provided for backwards compatibility only and " +
"assigning a non-Utc DateTime to it results in the wrong timestamp being passed to the service.", false)]
public DateTime EndTime
{
get { return this._endTime.GetValueOrDefault(); }
set
{
this._endTime = value;
this._endTimeUtc = new DateTime(value.Ticks, DateTimeKind.Utc);
}
}
///
/// Gets and sets the property StartTimeUtc.
///
/// This property is deprecated. Setting this property results in non-UTC DateTimes not
/// being marshalled correctly. Use StartTimeUtc instead. Setting either StartTime or
/// StartTimeUtc results in both StartTime and StartTimeUtc being assigned, the latest
/// assignment to either one of the two property is reflected in the value of both. StartTime
/// is provided for backwards compatibility only and assigning a non-Utc DateTime to it
/// results in the wrong timestamp being passed to the service.
///
///
///
/// The start time for the alerts to be listed.
///
///
[Obsolete("Setting this property results in non-UTC DateTimes not being marshalled correctly. " +
"Use StartTimeUtc instead. Setting either StartTime or StartTimeUtc results in both StartTime and " +
"StartTimeUtc being assigned, the latest assignment to either one of the two property is " +
"reflected in the value of both. StartTime is provided for backwards compatibility only and " +
"assigning a non-Utc DateTime to it results in the wrong timestamp being passed to the service.", false)]
public DateTime StartTime
{
get { return this._startTime.GetValueOrDefault(); }
set
{
this._startTime = value;
this._startTimeUtc = new DateTime(value.Ticks, DateTimeKind.Utc);
}
}
#endregion
}
}