/*
* 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 monitoring-2010-08-01.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.CloudWatch.Model
{
///
/// Container for the parameters to the ListMetrics operation.
/// List the specified metrics. You can use the returned metrics with GetMetricData
/// or GetMetricStatistics
/// to get statistical data.
///
///
///
/// Up to 500 results are returned for any one call. To retrieve additional results, use
/// the returned token with subsequent calls.
///
///
///
/// After you create a metric, allow up to 15 minutes for the metric to appear. To see
/// metric statistics sooner, use GetMetricData
/// or GetMetricStatistics.
///
///
///
/// If you are using CloudWatch cross-account observability, you can use this operation
/// in a monitoring account and view metrics from the linked source accounts. For more
/// information, see CloudWatch
/// cross-account observability.
///
///
///
/// ListMetrics
doesn't return information about metrics if those metrics
/// haven't reported data in the past two weeks. To retrieve those metrics, use GetMetricData
/// or GetMetricStatistics.
///
///
public partial class ListMetricsRequest : AmazonCloudWatchRequest
{
private List _dimensions = new List();
private bool? _includeLinkedAccounts;
private string _metricName;
private string _awsNamespace;
private string _nextToken;
private string _owningAccount;
private RecentlyActive _recentlyActive;
///
/// Gets and sets the property Dimensions.
///
/// The dimensions to filter against. Only the dimensions that match exactly will be returned.
///
///
[AWSProperty(Max=10)]
public List Dimensions
{
get { return this._dimensions; }
set { this._dimensions = value; }
}
// Check to see if Dimensions property is set
internal bool IsSetDimensions()
{
return this._dimensions != null && this._dimensions.Count > 0;
}
///
/// Gets and sets the property IncludeLinkedAccounts.
///
/// If you are using this operation in a monitoring account, specify true
/// to include metrics from source accounts in the returned data.
///
///
///
/// The default is false
.
///
///
public bool IncludeLinkedAccounts
{
get { return this._includeLinkedAccounts.GetValueOrDefault(); }
set { this._includeLinkedAccounts = value; }
}
// Check to see if IncludeLinkedAccounts property is set
internal bool IsSetIncludeLinkedAccounts()
{
return this._includeLinkedAccounts.HasValue;
}
///
/// Gets and sets the property MetricName.
///
/// The name of the metric to filter against. Only the metrics with names that match exactly
/// will be returned.
///
///
[AWSProperty(Min=1, Max=255)]
public string MetricName
{
get { return this._metricName; }
set { this._metricName = value; }
}
// Check to see if MetricName property is set
internal bool IsSetMetricName()
{
return this._metricName != null;
}
///
/// Gets and sets the property Namespace.
///
/// The metric namespace to filter against. Only the namespace that matches exactly will
/// be returned.
///
///
[AWSProperty(Min=1, Max=255)]
public string Namespace
{
get { return this._awsNamespace; }
set { this._awsNamespace = value; }
}
// Check to see if Namespace property is set
internal bool IsSetNamespace()
{
return this._awsNamespace != null;
}
///
/// Gets and sets the property NextToken.
///
/// The token returned by a previous call to indicate that there is more data available.
///
///
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 OwningAccount.
///
/// When you use this operation in a monitoring account, use this field to return metrics
/// only from one source account. To do so, specify that source account ID in this field,
/// and also specify true
for IncludeLinkedAccounts
.
///
///
[AWSProperty(Min=1, Max=255)]
public string OwningAccount
{
get { return this._owningAccount; }
set { this._owningAccount = value; }
}
// Check to see if OwningAccount property is set
internal bool IsSetOwningAccount()
{
return this._owningAccount != null;
}
///
/// Gets and sets the property RecentlyActive.
///
/// To filter the results to show only metrics that have had data points published in
/// the past three hours, specify this parameter with a value of PT3H
. This
/// is the only valid value for this parameter.
///
///
///
/// The results that are returned are an approximation of the value you specify. There
/// is a low probability that the returned results include metrics with last published
/// data as much as 40 minutes more than the specified time interval.
///
///
public RecentlyActive RecentlyActive
{
get { return this._recentlyActive; }
set { this._recentlyActive = value; }
}
// Check to see if RecentlyActive property is set
internal bool IsSetRecentlyActive()
{
return this._recentlyActive != null;
}
}
}