Class: WhatsappSdk::Resource::TemplateAnalytic
- Inherits:
-
Object
- Object
- WhatsappSdk::Resource::TemplateAnalytic
- Defined in:
- lib/whatsapp_sdk/resource/template_analytic.rb
Defined Under Namespace
Modules: Granularity, MetricType
Instance Attribute Summary collapse
-
#data_points ⇒ Object
Returns the value of attribute data_points.
-
#granularity ⇒ Object
Returns the value of attribute granularity.
-
#product_type ⇒ Object
Returns the value of attribute product_type.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(granularity:, product_type:, data_points:) ⇒ TemplateAnalytic
constructor
A new instance of TemplateAnalytic.
Constructor Details
#initialize(granularity:, product_type:, data_points:) ⇒ TemplateAnalytic
Returns a new instance of TemplateAnalytic.
39 40 41 42 43 |
# File 'lib/whatsapp_sdk/resource/template_analytic.rb', line 39 def initialize(granularity:, product_type:, data_points:) @granularity = granularity @product_type = product_type @data_points = data_points end |
Instance Attribute Details
#data_points ⇒ Object
Returns the value of attribute data_points.
37 38 39 |
# File 'lib/whatsapp_sdk/resource/template_analytic.rb', line 37 def data_points @data_points end |
#granularity ⇒ Object
Returns the value of attribute granularity.
37 38 39 |
# File 'lib/whatsapp_sdk/resource/template_analytic.rb', line 37 def granularity @granularity end |
#product_type ⇒ Object
Returns the value of attribute product_type.
37 38 39 |
# File 'lib/whatsapp_sdk/resource/template_analytic.rb', line 37 def product_type @product_type end |
Class Method Details
.from_hash(hash) ⇒ Object
45 46 47 48 49 50 51 |
# File 'lib/whatsapp_sdk/resource/template_analytic.rb', line 45 def self.from_hash(hash) new( granularity: hash["granularity"], product_type: hash["product_type"], data_points: hash["data_points"] ) end |