Class: Google::Apis::AnalyticsreportingV4::UserActivitySession

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

Overview

This represents a user session performed on a specific device at a certain time over a period of time.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ UserActivitySession

Returns a new instance of UserActivitySession.



2107
2108
2109
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2107

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

Instance Attribute Details

#activitiesArray<Google::Apis::AnalyticsreportingV4::Activity>

Represents a detailed view into each of the activity in this session. Corresponds to the JSON property activities



2078
2079
2080
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2078

def activities
  @activities
end

#data_sourceString

The data source of a hit. By default, hits sent from analytics.js are reported as "web" and hits sent from the mobile SDKs are reported as "app". These values can be overridden in the Measurement Protocol. Corresponds to the JSON property dataSource

Returns:

  • (String)


2085
2086
2087
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2085

def data_source
  @data_source
end

#device_categoryString

The type of device used: "mobile", "tablet" etc. Corresponds to the JSON property deviceCategory

Returns:

  • (String)


2090
2091
2092
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2090

def device_category
  @device_category
end

#platformString

Platform on which the activity happened: "android", "ios" etc. Corresponds to the JSON property platform

Returns:

  • (String)


2095
2096
2097
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2095

def platform
  @platform
end

#session_dateString

Date of this session in ISO-8601 format. Corresponds to the JSON property sessionDate

Returns:

  • (String)


2100
2101
2102
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2100

def session_date
  @session_date
end

#session_idString

Unique ID of the session. Corresponds to the JSON property sessionId

Returns:

  • (String)


2105
2106
2107
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2105

def session_id
  @session_id
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



2112
2113
2114
2115
2116
2117
2118
2119
# File 'generated/google/apis/analyticsreporting_v4/classes.rb', line 2112

def update!(**args)
  @activities = args[:activities] if args.key?(:activities)
  @data_source = args[:data_source] if args.key?(:data_source)
  @device_category = args[:device_category] if args.key?(:device_category)
  @platform = args[:platform] if args.key?(:platform)
  @session_date = args[:session_date] if args.key?(:session_date)
  @session_id = args[:session_id] if args.key?(:session_id)
end