Class: GoToWebinar::Attendee
- Inherits:
-
Object
- Object
- GoToWebinar::Attendee
- Defined in:
- lib/go_to_webinar/attendee.rb
Class Method Summary collapse
Instance Method Summary collapse
- #attendance ⇒ Object
- #attendance_time_in_seconds ⇒ Object
- #email ⇒ Object
- #first_name ⇒ Object
-
#initialize(data) ⇒ Attendee
constructor
A new instance of Attendee.
- #join_time ⇒ Object
- #last_name ⇒ Object
- #leave_time ⇒ Object
- #registrant_key ⇒ Object
- #session_key ⇒ Object
Constructor Details
#initialize(data) ⇒ Attendee
Returns a new instance of Attendee.
5 6 7 |
# File 'lib/go_to_webinar/attendee.rb', line 5 def initialize(data) @data = data end |
Class Method Details
.all_for_session(webinar_key:, session_key:) ⇒ Object
45 46 47 |
# File 'lib/go_to_webinar/attendee.rb', line 45 def self.all_for_session(webinar_key:, session_key:) make(GoToWebinar.client.get("/organizers/:organizer_key:/webinars/#{webinar_key}/sessions/#{session_key}/attendees")) end |
Instance Method Details
#attendance ⇒ Object
33 34 35 |
# File 'lib/go_to_webinar/attendee.rb', line 33 def attendance @data['attendance'] end |
#attendance_time_in_seconds ⇒ Object
25 26 27 |
# File 'lib/go_to_webinar/attendee.rb', line 25 def attendance_time_in_seconds @data['attendanceTimeInSeconds'].to_s end |
#email ⇒ Object
21 22 23 |
# File 'lib/go_to_webinar/attendee.rb', line 21 def email @data['email'].to_s end |
#first_name ⇒ Object
13 14 15 |
# File 'lib/go_to_webinar/attendee.rb', line 13 def first_name @data['firstName'].to_s end |
#join_time ⇒ Object
37 38 39 |
# File 'lib/go_to_webinar/attendee.rb', line 37 def join_time attendance['joinTime'].to_datetime end |
#last_name ⇒ Object
17 18 19 |
# File 'lib/go_to_webinar/attendee.rb', line 17 def last_name @data['lastName'].to_s end |
#leave_time ⇒ Object
41 42 43 |
# File 'lib/go_to_webinar/attendee.rb', line 41 def leave_time attendance['leaveTime'].to_datetime end |
#registrant_key ⇒ Object
9 10 11 |
# File 'lib/go_to_webinar/attendee.rb', line 9 def registrant_key @data['registrantKey'].to_s end |
#session_key ⇒ Object
29 30 31 |
# File 'lib/go_to_webinar/attendee.rb', line 29 def session_key @data['sessionKey'].to_s end |