Class: Google::Apis::AnalyticsdataV1beta::OrderBy

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
lib/google/apis/analyticsdata_v1beta/classes.rb,
lib/google/apis/analyticsdata_v1beta/representations.rb,
lib/google/apis/analyticsdata_v1beta/representations.rb

Overview

Order bys define how rows will be sorted in the response. For example, ordering rows by descending event count is one ordering, and ordering rows by the event name string is a different ordering.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ OrderBy

Returns a new instance of OrderBy.



1409
1410
1411
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1409

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#descBoolean Also known as: desc?

If true, sorts by descending order. Corresponds to the JSON property desc

Returns:

  • (Boolean)


1391
1392
1393
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1391

def desc
  @desc
end

#dimensionGoogle::Apis::AnalyticsdataV1beta::DimensionOrderBy

Sorts by dimension values. Corresponds to the JSON property dimension



1397
1398
1399
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1397

def dimension
  @dimension
end

#metricGoogle::Apis::AnalyticsdataV1beta::MetricOrderBy

Sorts by metric values. Corresponds to the JSON property metric



1402
1403
1404
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1402

def metric
  @metric
end

#pivotGoogle::Apis::AnalyticsdataV1beta::PivotOrderBy

Sorts by a pivot column group. Corresponds to the JSON property pivot



1407
1408
1409
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1407

def pivot
  @pivot
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



1414
1415
1416
1417
1418
1419
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1414

def update!(**args)
  @desc = args[:desc] if args.key?(:desc)
  @dimension = args[:dimension] if args.key?(:dimension)
  @metric = args[:metric] if args.key?(:metric)
  @pivot = args[:pivot] if args.key?(:pivot)
end