Class ReportQuery
- java.lang.Object
-
- com.oracle.bmc.http.client.internal.ExplicitlySetBmcModel
-
- com.oracle.bmc.usageapi.model.ReportQuery
-
@Generated(value="OracleSDKGenerator", comments="API Version: 20200107") public final class ReportQuery extends com.oracle.bmc.http.client.internal.ExplicitlySetBmcModelThe request of the generated Cost Analysis report.
Note: Objects should always be created or deserialized using theReportQuery.Builder. This model distinguishes fields that are null because they are unset from fields that are explicitly set to null. This is done in the setter methods of theReportQuery.Builder, which maintain a set of all explicitly set fields calledReportQuery.Builder.__explicitlySet__. ThehashCode()andequals(Object)methods are implemented to take the explicitly set fields into account. The constructor, on the other hand, does not take the explicitly set fields into account (since the constructor cannot distinguish explicit null from unset null).
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static classReportQuery.Builderstatic classReportQuery.DateRangeNameThe UI date range, for example, LAST_THREE_MONTHS.static classReportQuery.GranularityThe usage granularity.static classReportQuery.QueryTypeThe query usage type.
-
Constructor Summary
Constructors Constructor Description ReportQuery(String tenantId, Date timeUsageStarted, Date timeUsageEnded, ReportQuery.Granularity granularity, Boolean isAggregateByTime, Forecast forecast, ReportQuery.QueryType queryType, List<String> groupBy, List<Tag> groupByTag, BigDecimal compartmentDepth, Filter filter, ReportQuery.DateRangeName dateRangeName)Deprecated.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static ReportQuery.Builderbuilder()Create a new builder.booleanequals(Object o)BigDecimalgetCompartmentDepth()The compartment depth level.ReportQuery.DateRangeNamegetDateRangeName()The UI date range, for example, LAST_THREE_MONTHS.FiltergetFilter()ForecastgetForecast()ReportQuery.GranularitygetGranularity()The usage granularity.List<String>getGroupBy()Specifies what to aggregate the result by.List<Tag>getGroupByTag()GroupBy a specific tagKey.BooleangetIsAggregateByTime()Specifies whether aggregated by time.ReportQuery.QueryTypegetQueryType()The query usage type.StringgetTenantId()Tenant ID.DategetTimeUsageEnded()The usage end time.DategetTimeUsageStarted()The usage start time.inthashCode()ReportQuery.BuildertoBuilder()StringtoString()StringtoString(boolean includeByteArrayContents)Return a string representation of the object.
-
-
-
Constructor Detail
-
ReportQuery
@Deprecated @ConstructorProperties({"tenantId","timeUsageStarted","timeUsageEnded","granularity","isAggregateByTime","forecast","queryType","groupBy","groupByTag","compartmentDepth","filter","dateRangeName"}) public ReportQuery(String tenantId, Date timeUsageStarted, Date timeUsageEnded, ReportQuery.Granularity granularity, Boolean isAggregateByTime, Forecast forecast, ReportQuery.QueryType queryType, List<String> groupBy, List<Tag> groupByTag, BigDecimal compartmentDepth, Filter filter, ReportQuery.DateRangeName dateRangeName)
Deprecated.
-
-
Method Detail
-
builder
public static ReportQuery.Builder builder()
Create a new builder.
-
toBuilder
public ReportQuery.Builder toBuilder()
-
getTenantId
public String getTenantId()
Tenant ID.- Returns:
- the value
-
getTimeUsageStarted
public Date getTimeUsageStarted()
The usage start time.- Returns:
- the value
-
getTimeUsageEnded
public Date getTimeUsageEnded()
The usage end time.- Returns:
- the value
-
getGranularity
public ReportQuery.Granularity getGranularity()
The usage granularity.HOURLY - Hourly data aggregation. DAILY - Daily data aggregation. MONTHLY - Monthly data aggregation. TOTAL - Not yet supported.
- Returns:
- the value
-
getIsAggregateByTime
public Boolean getIsAggregateByTime()
Specifies whether aggregated by time.If isAggregateByTime is true, all usage or cost over the query time period will be added up.
- Returns:
- the value
-
getForecast
public Forecast getForecast()
-
getQueryType
public ReportQuery.QueryType getQueryType()
The query usage type.COST by default if it is missing. * Usage: Query the usage data. * Cost: Query the cost/billing data. * Credit: Query the credit adjustments data. * ExpiredCredit: Query the expired credits data. * AllCredit: Query the credit adjustments and expired credit.
- Returns:
- the value
-
getGroupBy
public List<String> getGroupBy()
Specifies what to aggregate the result by.For example: [“tagNamespace”, “tagKey”, “tagValue”, “service”, “skuName”, “skuPartNumber”, “unit”, “compartmentName”, “compartmentPath”, “compartmentId”, “platform”, “region”, “logicalAd”, “resourceId”, “tenantId”, “tenantName”]
- Returns:
- the value
-
getGroupByTag
public List<Tag> getGroupByTag()
GroupBy a specific tagKey.Provide the tagNamespace and tagKey in the tag object. Only supports one tag in the list. For example: {@code [{“namespace”:“oracle”, “key”:“createdBy”]}
- Returns:
- the value
-
getCompartmentDepth
public BigDecimal getCompartmentDepth()
The compartment depth level.- Returns:
- the value
-
getFilter
public Filter getFilter()
-
getDateRangeName
public ReportQuery.DateRangeName getDateRangeName()
The UI date range, for example, LAST_THREE_MONTHS.Conflicts with timeUsageStarted and timeUsageEnded.
- Returns:
- the value
-
toString
public String toString()
- Overrides:
toStringin classcom.oracle.bmc.http.client.internal.ExplicitlySetBmcModel
-
toString
public String toString(boolean includeByteArrayContents)
Return a string representation of the object.- Parameters:
includeByteArrayContents- true to include the full contents of byte arrays- Returns:
- string representation
-
equals
public boolean equals(Object o)
- Overrides:
equalsin classcom.oracle.bmc.http.client.internal.ExplicitlySetBmcModel
-
hashCode
public int hashCode()
- Overrides:
hashCodein classcom.oracle.bmc.http.client.internal.ExplicitlySetBmcModel
-
-