/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include #include #include namespace Aws { namespace EC2 { namespace Model { /** */ class DescribeHostReservationsRequest : public EC2Request { public: AWS_EC2_API DescribeHostReservationsRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "DescribeHostReservations"; } AWS_EC2_API Aws::String SerializePayload() const override; protected: AWS_EC2_API void DumpBodyToUrl(Aws::Http::URI& uri ) const override; public: /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline const Aws::Vector& GetFilter() const{ return m_filter; } /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline bool FilterHasBeenSet() const { return m_filterHasBeenSet; } /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline void SetFilter(const Aws::Vector& value) { m_filterHasBeenSet = true; m_filter = value; } /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline void SetFilter(Aws::Vector&& value) { m_filterHasBeenSet = true; m_filter = std::move(value); } /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline DescribeHostReservationsRequest& WithFilter(const Aws::Vector& value) { SetFilter(value); return *this;} /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline DescribeHostReservationsRequest& WithFilter(Aws::Vector&& value) { SetFilter(std::move(value)); return *this;} /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline DescribeHostReservationsRequest& AddFilter(const Filter& value) { m_filterHasBeenSet = true; m_filter.push_back(value); return *this; } /** *

The filters.

  • instance-family - The instance * family (for example, m4).

  • * payment-option - The payment option (NoUpfront | * PartialUpfront | AllUpfront).

  • * state - The state of the reservation (payment-pending * | payment-failed | active | retired).

    *
  • tag:<key> - The key/value combination of a tag * assigned to the resource. Use the tag key in the filter name and the tag value * as the filter value. For example, to find all resources that have a tag with the * key Owner and the value TeamA, specify * tag:Owner for the filter name and TeamA for the filter * value.

  • tag-key - The key of a tag assigned to * the resource. Use this filter to find all resources assigned a tag with a * specific key, regardless of the tag value.

*/ inline DescribeHostReservationsRequest& AddFilter(Filter&& value) { m_filterHasBeenSet = true; m_filter.push_back(std::move(value)); return *this; } /** *

The host reservation IDs.

*/ inline const Aws::Vector& GetHostReservationIdSet() const{ return m_hostReservationIdSet; } /** *

The host reservation IDs.

*/ inline bool HostReservationIdSetHasBeenSet() const { return m_hostReservationIdSetHasBeenSet; } /** *

The host reservation IDs.

*/ inline void SetHostReservationIdSet(const Aws::Vector& value) { m_hostReservationIdSetHasBeenSet = true; m_hostReservationIdSet = value; } /** *

The host reservation IDs.

*/ inline void SetHostReservationIdSet(Aws::Vector&& value) { m_hostReservationIdSetHasBeenSet = true; m_hostReservationIdSet = std::move(value); } /** *

The host reservation IDs.

*/ inline DescribeHostReservationsRequest& WithHostReservationIdSet(const Aws::Vector& value) { SetHostReservationIdSet(value); return *this;} /** *

The host reservation IDs.

*/ inline DescribeHostReservationsRequest& WithHostReservationIdSet(Aws::Vector&& value) { SetHostReservationIdSet(std::move(value)); return *this;} /** *

The host reservation IDs.

*/ inline DescribeHostReservationsRequest& AddHostReservationIdSet(const Aws::String& value) { m_hostReservationIdSetHasBeenSet = true; m_hostReservationIdSet.push_back(value); return *this; } /** *

The host reservation IDs.

*/ inline DescribeHostReservationsRequest& AddHostReservationIdSet(Aws::String&& value) { m_hostReservationIdSetHasBeenSet = true; m_hostReservationIdSet.push_back(std::move(value)); return *this; } /** *

The host reservation IDs.

*/ inline DescribeHostReservationsRequest& AddHostReservationIdSet(const char* value) { m_hostReservationIdSetHasBeenSet = true; m_hostReservationIdSet.push_back(value); return *this; } /** *

The maximum number of results to return for the request in a single page. The * remaining results can be seen by sending another request with the returned * nextToken value. This value can be between 5 and 500. If * maxResults is given a larger value than 500, you receive an * error.

*/ inline int GetMaxResults() const{ return m_maxResults; } /** *

The maximum number of results to return for the request in a single page. The * remaining results can be seen by sending another request with the returned * nextToken value. This value can be between 5 and 500. If * maxResults is given a larger value than 500, you receive an * error.

*/ inline bool MaxResultsHasBeenSet() const { return m_maxResultsHasBeenSet; } /** *

The maximum number of results to return for the request in a single page. The * remaining results can be seen by sending another request with the returned * nextToken value. This value can be between 5 and 500. If * maxResults is given a larger value than 500, you receive an * error.

*/ inline void SetMaxResults(int value) { m_maxResultsHasBeenSet = true; m_maxResults = value; } /** *

The maximum number of results to return for the request in a single page. The * remaining results can be seen by sending another request with the returned * nextToken value. This value can be between 5 and 500. If * maxResults is given a larger value than 500, you receive an * error.

*/ inline DescribeHostReservationsRequest& WithMaxResults(int value) { SetMaxResults(value); return *this;} /** *

The token to use to retrieve the next page of results.

*/ inline const Aws::String& GetNextToken() const{ return m_nextToken; } /** *

The token to use to retrieve the next page of results.

*/ inline bool NextTokenHasBeenSet() const { return m_nextTokenHasBeenSet; } /** *

The token to use to retrieve the next page of results.

*/ inline void SetNextToken(const Aws::String& value) { m_nextTokenHasBeenSet = true; m_nextToken = value; } /** *

The token to use to retrieve the next page of results.

*/ inline void SetNextToken(Aws::String&& value) { m_nextTokenHasBeenSet = true; m_nextToken = std::move(value); } /** *

The token to use to retrieve the next page of results.

*/ inline void SetNextToken(const char* value) { m_nextTokenHasBeenSet = true; m_nextToken.assign(value); } /** *

The token to use to retrieve the next page of results.

*/ inline DescribeHostReservationsRequest& WithNextToken(const Aws::String& value) { SetNextToken(value); return *this;} /** *

The token to use to retrieve the next page of results.

*/ inline DescribeHostReservationsRequest& WithNextToken(Aws::String&& value) { SetNextToken(std::move(value)); return *this;} /** *

The token to use to retrieve the next page of results.

*/ inline DescribeHostReservationsRequest& WithNextToken(const char* value) { SetNextToken(value); return *this;} private: Aws::Vector m_filter; bool m_filterHasBeenSet = false; Aws::Vector m_hostReservationIdSet; bool m_hostReservationIdSetHasBeenSet = false; int m_maxResults; bool m_maxResultsHasBeenSet = false; Aws::String m_nextToken; bool m_nextTokenHasBeenSet = false; }; } // namespace Model } // namespace EC2 } // namespace Aws