Google Ads Ad Manager V1 Client - Class Sort (0.1.0)

Reference documentation and code samples for the Google Ads Ad Manager V1 Client class Sort.

Represents a sorting in a report.

Generated from protobuf message google.ads.admanager.v1.Report.Sort

Namespace

Google \ Ads \ AdManager \ V1 \ Report

Methods

__construct

Constructor.

Parameters
Name Description
data array

Optional. Data for populating the Message object.

↳ field Google\Ads\AdManager\V1\Report\Field

Required. A field (dimension or metric) to sort by.

↳ descending bool

Optional. The sort order. If true the sort will be descending.

↳ slice Google\Ads\AdManager\V1\Report\Slice

Optional. Use to sort on a specific slice of data.

↳ time_period_index int

Optional. When using time period columns, use this to sort on a specific column.

↳ metric_value_type int

Optional. Use to specify which metric value type to sort on. Defaults to PRIMARY.

getField

Required. A field (dimension or metric) to sort by.

Returns
Type Description
Google\Ads\AdManager\V1\Report\Field|null

hasField

clearField

setField

Required. A field (dimension or metric) to sort by.

Parameter
Name Description
var Google\Ads\AdManager\V1\Report\Field
Returns
Type Description
$this

getDescending

Optional. The sort order. If true the sort will be descending.

Returns
Type Description
bool

setDescending

Optional. The sort order. If true the sort will be descending.

Parameter
Name Description
var bool
Returns
Type Description
$this

getSlice

Optional. Use to sort on a specific slice of data.

Returns
Type Description
Google\Ads\AdManager\V1\Report\Slice|null

hasSlice

clearSlice

setSlice

Optional. Use to sort on a specific slice of data.

Parameter
Name Description
var Google\Ads\AdManager\V1\Report\Slice
Returns
Type Description
$this

getTimePeriodIndex

Optional. When using time period columns, use this to sort on a specific column.

Returns
Type Description
int

hasTimePeriodIndex

clearTimePeriodIndex

setTimePeriodIndex

Optional. When using time period columns, use this to sort on a specific column.

Parameter
Name Description
var int
Returns
Type Description
$this

getMetricValueType

Optional. Use to specify which metric value type to sort on. Defaults to PRIMARY.

Returns
Type Description
int

hasMetricValueType

clearMetricValueType

setMetricValueType

Optional. Use to specify which metric value type to sort on. Defaults to PRIMARY.

Parameter
Name Description
var int
Returns
Type Description
$this