Class: CalendarApi::EntryPointType
- Inherits:
-
Object
- Object
- CalendarApi::EntryPointType
- Defined in:
- lib/calendar_api/models/entry_point_type.rb
Overview
The type of conference entry point.
Constant Summary collapse
- ENTRY_POINT_TYPE =
[ # TODO: Write general description for VIDEO VIDEO = 'video'.freeze, # TODO: Write general description for PHONE PHONE = 'phone'.freeze, # TODO: Write general description for SIP SIP = 'sip'.freeze, # TODO: Write general description for MORE MORE = 'more'.freeze ].freeze
Class Method Summary collapse
Class Method Details
.from_value(value, default_value = VIDEO) ⇒ Object
29 30 31 32 33 34 35 36 37 38 39 40 41 42 |
# File 'lib/calendar_api/models/entry_point_type.rb', line 29 def self.from_value(value, default_value = VIDEO) return default_value if value.nil? str = value.to_s.strip case str.downcase when 'video' then VIDEO when 'phone' then PHONE when 'sip' then SIP when 'more' then MORE else default_value end end |
.validate(value) ⇒ Object
23 24 25 26 27 |
# File 'lib/calendar_api/models/entry_point_type.rb', line 23 def self.validate(value) return false if value.nil? ENTRY_POINT_TYPE.include?(value) end |