Class: Google::Apis::ChromeuxreportV1::HistoryRecord

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

Overview

HistoryRecord is a timeseries of Chrome UX Report data. It contains user experience statistics for a single url pattern and a set of dimensions.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(**args) ⇒ HistoryRecord

Returns a new instance of HistoryRecord.



209
210
211
# File 'lib/google/apis/chromeuxreport_v1/classes.rb', line 209

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

Instance Attribute Details

#collection_periodsArray<Google::Apis::ChromeuxreportV1::CollectionPeriod>

The collection periods indicate when each of the data points reflected in the time series data in metrics was collected. Note that all the time series share the same collection periods, and it is enforced in the CrUX pipeline that every time series has the same number of data points. Corresponds to the JSON property collectionPeriods



193
194
195
# File 'lib/google/apis/chromeuxreport_v1/classes.rb', line 193

def collection_periods
  @collection_periods
end

#keyGoogle::Apis::ChromeuxreportV1::HistoryKey

Key defines all the dimensions that identify this record as unique. Corresponds to the JSON property key



198
199
200
# File 'lib/google/apis/chromeuxreport_v1/classes.rb', line 198

def key
  @key
end

#metricsHash<String,Google::Apis::ChromeuxreportV1::MetricTimeseries>

Metrics is the map of user experience time series data available for the record defined in the key field. Metrics are keyed on the metric name. Allowed key values: ["first_contentful_paint", "first_input_delay", " largest_contentful_paint", "cumulative_layout_shift", " experimental_time_to_first_byte", "experimental_interaction_to_next_paint"] Corresponds to the JSON property metrics



207
208
209
# File 'lib/google/apis/chromeuxreport_v1/classes.rb', line 207

def metrics
  @metrics
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



214
215
216
217
218
# File 'lib/google/apis/chromeuxreport_v1/classes.rb', line 214

def update!(**args)
  @collection_periods = args[:collection_periods] if args.key?(:collection_periods)
  @key = args[:key] if args.key?(:key)
  @metrics = args[:metrics] if args.key?(:metrics)
end