Class: Optimizely::ConversionEvent

Inherits:
UserEvent
  • Object
show all
Defined in:
lib/optimizely/event/entity/conversion_event.rb

Instance Attribute Summary collapse

Attributes inherited from UserEvent

#event_context, #timestamp, #uuid

Instance Method Summary collapse

Constructor Details

#initialize(event_context:, event:, user_id:, visitor_attributes:, tags:, bot_filtering:) ⇒ ConversionEvent

Returns a new instance of ConversionEvent.



25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
# File 'lib/optimizely/event/entity/conversion_event.rb', line 25

def initialize(
  event_context:,
  event:,
  user_id:,
  visitor_attributes:,
  tags:,
  bot_filtering:
)
  super()
  @event_context = event_context
  @uuid = SecureRandom.uuid
  @timestamp = Helpers::DateTimeUtils.create_timestamp
  @event = event
  @user_id = user_id
  @visitor_attributes = visitor_attributes
  @tags = tags
  @bot_filtering = bot_filtering
end

Instance Attribute Details

#bot_filteringObject (readonly)

Represents conversion event



23
24
25
# File 'lib/optimizely/event/entity/conversion_event.rb', line 23

def bot_filtering
  @bot_filtering
end

#eventObject (readonly)

Represents conversion event



23
24
25
# File 'lib/optimizely/event/entity/conversion_event.rb', line 23

def event
  @event
end

#tagsObject (readonly)

Represents conversion event



23
24
25
# File 'lib/optimizely/event/entity/conversion_event.rb', line 23

def tags
  @tags
end

#user_idObject (readonly)

Represents conversion event



23
24
25
# File 'lib/optimizely/event/entity/conversion_event.rb', line 23

def user_id
  @user_id
end

#visitor_attributesObject (readonly)

Represents conversion event



23
24
25
# File 'lib/optimizely/event/entity/conversion_event.rb', line 23

def visitor_attributes
  @visitor_attributes
end