Class: Kahuna::Event

Inherits:
Object
  • Object
show all
Defined in:
lib/kahuna/event.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ Event

Returns a new instance of Event.



5
6
7
8
9
10
11
12
# File 'lib/kahuna/event.rb', line 5

def initialize(data)
  @raw_data = data
  @type = ENV['SERF_EVENT']
  @name = ENV['SERF_SELF_NAME']
  @role = ENV['SERF_SELF_ROLE']
  @user_event = ENV['SERF_USER_EVENT']
  @user_ltime = ENV['SERF_USER_LTIME']
end

Instance Attribute Details

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def name
  @name
end

#raw_dataObject (readonly)

Returns the value of attribute raw_data.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def raw_data
  @raw_data
end

#roleObject (readonly)

Returns the value of attribute role.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def role
  @role
end

#typeObject (readonly)

Returns the value of attribute type.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def type
  @type
end

#user_eventObject (readonly)

Returns the value of attribute user_event.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def user_event
  @user_event
end

#user_ltimeObject (readonly)

Returns the value of attribute user_ltime.



3
4
5
# File 'lib/kahuna/event.rb', line 3

def user_ltime
  @user_ltime
end