Class: Kameleoon::TargetedSegment
- Inherits:
-
DuplicationUnsafeData
- Object
- Data
- DuplicationUnsafeData
- Kameleoon::TargetedSegment
- Defined in:
- lib/kameleoon/data/targeted_segment.rb
Constant Summary collapse
- EVENT_TYPE =
'targetingSegment'
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
Attributes inherited from Data
Instance Method Summary collapse
-
#initialize(id) ⇒ TargetedSegment
constructor
A new instance of TargetedSegment.
- #obtain_full_post_text_line ⇒ Object
- #to_s ⇒ Object
Methods inherited from Data
#mark_as_sent, #mark_as_transmitting, #mark_as_unsent, #sent, #transmitting, #unsent
Constructor Details
#initialize(id) ⇒ TargetedSegment
Returns a new instance of TargetedSegment.
12 13 14 15 |
# File 'lib/kameleoon/data/targeted_segment.rb', line 12 def initialize(id) super(DataType::TARGETED_SEGMENT) @id = id end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
10 11 12 |
# File 'lib/kameleoon/data/targeted_segment.rb', line 10 def id @id end |
Instance Method Details
#obtain_full_post_text_line ⇒ Object
17 18 19 20 21 22 23 24 |
# File 'lib/kameleoon/data/targeted_segment.rb', line 17 def obtain_full_post_text_line params = { eventType: EVENT_TYPE, id: @id, nonce: nonce } Network::UriHelper.encode_query(params) end |
#to_s ⇒ Object
26 27 28 |
# File 'lib/kameleoon/data/targeted_segment.rb', line 26 def to_s "TargetedSegment{id:#{@id}}" end |