Class: Google::Apis::AnalyticsdataV1beta::MetricMetadata
- Inherits:
-
Object
- Object
- Google::Apis::AnalyticsdataV1beta::MetricMetadata
- 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
Explains a metric.
Instance Attribute Summary collapse
-
#api_name ⇒ String
A metric name.
-
#blocked_reasons ⇒ Array<String>
If reasons are specified, your access is blocked to this metric for this property.
-
#category ⇒ String
The display name of the category that this metrics belongs to.
-
#custom_definition ⇒ Boolean
(also: #custom_definition?)
True if the metric is a custom metric for this property.
-
#deprecated_api_names ⇒ Array<String>
Still usable but deprecated names for this metric.
-
#description ⇒ String
Description of how this metric is used and calculated.
-
#expression ⇒ String
The mathematical expression for this derived metric.
-
#type ⇒ String
The type of this metric.
-
#ui_name ⇒ String
This metric's name within the Google Analytics user interface.
Instance Method Summary collapse
-
#initialize(**args) ⇒ MetricMetadata
constructor
A new instance of MetricMetadata.
-
#update!(**args) ⇒ Object
Update properties of this object.
Constructor Details
#initialize(**args) ⇒ MetricMetadata
Returns a new instance of MetricMetadata.
1026 1027 1028 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1026 def initialize(**args) update!(**args) end |
Instance Attribute Details
#api_name ⇒ String
A metric name. Useable in Metric's name. For example, eventCount
.
Corresponds to the JSON property apiName
971 972 973 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 971 def api_name @api_name end |
#blocked_reasons ⇒ Array<String>
If reasons are specified, your access is blocked to this metric for this
property. API requests from you to this property for this metric will succeed;
however, the report will contain only zeros for this metric. API requests with
metric filters on blocked metrics will fail. If reasons are empty, you have
access to this metric. To learn more, see Access and data-restriction
management.
Corresponds to the JSON property blockedReasons
981 982 983 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 981 def blocked_reasons @blocked_reasons end |
#category ⇒ String
The display name of the category that this metrics belongs to. Similar
dimensions and metrics are categorized together.
Corresponds to the JSON property category
987 988 989 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 987 def category @category end |
#custom_definition ⇒ Boolean Also known as: custom_definition?
True if the metric is a custom metric for this property.
Corresponds to the JSON property customDefinition
992 993 994 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 992 def custom_definition @custom_definition end |
#deprecated_api_names ⇒ Array<String>
Still usable but deprecated names for this metric. If populated, this metric
is available by either apiName or one of deprecatedApiNames for a period
of time. After the deprecation period, the metric will be available only by
apiName.
Corresponds to the JSON property deprecatedApiNames
1001 1002 1003 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1001 def deprecated_api_names @deprecated_api_names end |
#description ⇒ String
Description of how this metric is used and calculated.
Corresponds to the JSON property description
1006 1007 1008 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1006 def description @description end |
#expression ⇒ String
The mathematical expression for this derived metric. Can be used in Metric's expression field for equivalent reports. Most metrics are not
expressions, and for non-expressions, this field is empty.
Corresponds to the JSON property expression
1013 1014 1015 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1013 def expression @expression end |
#type ⇒ String
The type of this metric.
Corresponds to the JSON property type
1018 1019 1020 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1018 def type @type end |
#ui_name ⇒ String
This metric's name within the Google Analytics user interface. For example,
Event count.
Corresponds to the JSON property uiName
1024 1025 1026 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1024 def ui_name @ui_name end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 |
# File 'lib/google/apis/analyticsdata_v1beta/classes.rb', line 1031 def update!(**args) @api_name = args[:api_name] if args.key?(:api_name) @blocked_reasons = args[:blocked_reasons] if args.key?(:blocked_reasons) @category = args[:category] if args.key?(:category) @custom_definition = args[:custom_definition] if args.key?(:custom_definition) @deprecated_api_names = args[:deprecated_api_names] if args.key?(:deprecated_api_names) @description = args[:description] if args.key?(:description) @expression = args[:expression] if args.key?(:expression) @type = args[:type] if args.key?(:type) @ui_name = args[:ui_name] if args.key?(:ui_name) end |