Class QueryDefinition

java.lang.Object
com.azure.resourcemanager.costmanagement.models.QueryDefinition

public final class QueryDefinition extends Object
The definition of a query.
  • Constructor Details

    • QueryDefinition

      public QueryDefinition()
      Creates an instance of QueryDefinition class.
  • Method Details

    • type

      public ExportType type()
      Get the type property: The type of the query.
      Returns:
      the type value.
    • withType

      public QueryDefinition withType(ExportType type)
      Set the type property: The type of the query.
      Parameters:
      type - the type value to set.
      Returns:
      the QueryDefinition object itself.
    • timeframe

      public TimeframeType timeframe()
      Get the timeframe property: The time frame for pulling data for the query. If custom, then a specific time period must be provided.
      Returns:
      the timeframe value.
    • withTimeframe

      public QueryDefinition withTimeframe(TimeframeType timeframe)
      Set the timeframe property: The time frame for pulling data for the query. If custom, then a specific time period must be provided.
      Parameters:
      timeframe - the timeframe value to set.
      Returns:
      the QueryDefinition object itself.
    • timePeriod

      public QueryTimePeriod timePeriod()
      Get the timePeriod property: Has time period for pulling data for the query.
      Returns:
      the timePeriod value.
    • withTimePeriod

      public QueryDefinition withTimePeriod(QueryTimePeriod timePeriod)
      Set the timePeriod property: Has time period for pulling data for the query.
      Parameters:
      timePeriod - the timePeriod value to set.
      Returns:
      the QueryDefinition object itself.
    • dataset

      public QueryDataset dataset()
      Get the dataset property: Has definition for data in this query.
      Returns:
      the dataset value.
    • withDataset

      public QueryDefinition withDataset(QueryDataset dataset)
      Set the dataset property: Has definition for data in this query.
      Parameters:
      dataset - the dataset value to set.
      Returns:
      the QueryDefinition object itself.
    • validate

      public void validate()
      Validates the instance.
      Throws:
      IllegalArgumentException - thrown if the instance is not valid.