Class: AnalyticsOps::Connection::Verification
- Inherits:
-
Object
- Object
- AnalyticsOps::Connection::Verification
- Defined in:
- lib/analytics_ops/connection.rb,
sig/analytics_ops.rbs
Overview
Immutable proof that both APIs can read the selected property.
Instance Attribute Summary collapse
-
#property ⇒ Resources::Property
readonly
Returns the value of attribute property.
Instance Method Summary collapse
-
#initialize(property:) ⇒ Verification
constructor
A new instance of Verification.
- #to_h ⇒ record
Constructor Details
#initialize(property:) ⇒ Verification
Returns a new instance of Verification.
12 13 14 15 16 17 18 19 |
# File 'lib/analytics_ops/connection.rb', line 12 def initialize(property:) unless property.is_a?(Resources::Property) raise ArgumentError, "property must be an AnalyticsOps::Resources::Property" end @property = property freeze end |
Instance Attribute Details
#property ⇒ Resources::Property (readonly)
Returns the value of attribute property.
10 11 12 |
# File 'lib/analytics_ops/connection.rb', line 10 def property @property end |
Instance Method Details
#to_h ⇒ record
21 22 23 |
# File 'lib/analytics_ops/connection.rb', line 21 def to_h { "property" => property.to_h, "admin_api" => true, "data_api" => true } end |