Class: CalendarApi::ConferenceData
- Defined in:
- lib/calendar_api/models/conference_data.rb
Overview
Information about a conference (e.g. Google Meet).
Instance Attribute Summary collapse
-
#conference_id ⇒ String
The ID of the conference.
-
#conference_solution ⇒ ConferenceSolution
Conference solution information, such as Google Meet.
-
#create_request ⇒ ConferenceCreateRequest
A request to generate a new conference and attach it to the event.
-
#entry_points ⇒ Array[ConferenceEntryPoint]
Information about individual conference entry points.
-
#notes ⇒ String
Additional notes to display to the user.
-
#signature ⇒ String
Server-generated signature of the conference data.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(create_request: SKIP, entry_points: SKIP, conference_solution: SKIP, conference_id: SKIP, notes: SKIP, signature: SKIP, additional_properties: nil) ⇒ ConferenceData
constructor
A new instance of ConferenceData.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(create_request: SKIP, entry_points: SKIP, conference_solution: SKIP, conference_id: SKIP, notes: SKIP, signature: SKIP, additional_properties: nil) ⇒ ConferenceData
Returns a new instance of ConferenceData.
65 66 67 68 69 70 71 72 73 74 75 76 77 78 |
# File 'lib/calendar_api/models/conference_data.rb', line 65 def initialize(create_request: SKIP, entry_points: SKIP, conference_solution: SKIP, conference_id: SKIP, notes: SKIP, signature: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @create_request = create_request unless create_request == SKIP @entry_points = entry_points unless entry_points == SKIP @conference_solution = conference_solution unless conference_solution == SKIP @conference_id = conference_id unless conference_id == SKIP @notes = notes unless notes == SKIP @signature = signature unless signature == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#conference_id ⇒ String
The ID of the conference.
26 27 28 |
# File 'lib/calendar_api/models/conference_data.rb', line 26 def conference_id @conference_id end |
#conference_solution ⇒ ConferenceSolution
Conference solution information, such as Google Meet.
22 23 24 |
# File 'lib/calendar_api/models/conference_data.rb', line 22 def conference_solution @conference_solution end |
#create_request ⇒ ConferenceCreateRequest
A request to generate a new conference and attach it to the event.
14 15 16 |
# File 'lib/calendar_api/models/conference_data.rb', line 14 def create_request @create_request end |
#entry_points ⇒ Array[ConferenceEntryPoint]
Information about individual conference entry points.
18 19 20 |
# File 'lib/calendar_api/models/conference_data.rb', line 18 def entry_points @entry_points end |
#notes ⇒ String
Additional notes to display to the user. May contain HTML.
30 31 32 |
# File 'lib/calendar_api/models/conference_data.rb', line 30 def notes @notes end |
#signature ⇒ String
Server-generated signature of the conference data.
34 35 36 |
# File 'lib/calendar_api/models/conference_data.rb', line 34 def signature @signature end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 |
# File 'lib/calendar_api/models/conference_data.rb', line 81 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. create_request = ConferenceCreateRequest.from_hash(hash['createRequest']) if hash['createRequest'] # Parameter is an array, so we need to iterate through it entry_points = nil unless hash['entryPoints'].nil? entry_points = [] hash['entryPoints'].each do |structure| entry_points << (ConferenceEntryPoint.from_hash(structure) if structure) end end entry_points = SKIP unless hash.key?('entryPoints') conference_solution = ConferenceSolution.from_hash(hash['conferenceSolution']) if hash['conferenceSolution'] conference_id = hash.key?('conferenceId') ? hash['conferenceId'] : SKIP notes = hash.key?('notes') ? hash['notes'] : SKIP signature = hash.key?('signature') ? hash['signature'] : SKIP # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. ConferenceData.new(create_request: create_request, entry_points: entry_points, conference_solution: conference_solution, conference_id: conference_id, notes: notes, signature: signature, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
37 38 39 40 41 42 43 44 45 46 |
# File 'lib/calendar_api/models/conference_data.rb', line 37 def self.names @_hash = {} if @_hash.nil? @_hash['create_request'] = 'createRequest' @_hash['entry_points'] = 'entryPoints' @_hash['conference_solution'] = 'conferenceSolution' @_hash['conference_id'] = 'conferenceId' @_hash['notes'] = 'notes' @_hash['signature'] = 'signature' @_hash end |
.nullables ⇒ Object
An array for nullable fields
61 62 63 |
# File 'lib/calendar_api/models/conference_data.rb', line 61 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
49 50 51 52 53 54 55 56 57 58 |
# File 'lib/calendar_api/models/conference_data.rb', line 49 def self.optionals %w[ create_request entry_points conference_solution conference_id notes signature ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
129 130 131 132 133 134 135 |
# File 'lib/calendar_api/models/conference_data.rb', line 129 def inspect class_name = self.class.name.split('::').last "<#{class_name} create_request: #{@create_request.inspect}, entry_points:"\ " #{@entry_points.inspect}, conference_solution: #{@conference_solution.inspect},"\ " conference_id: #{@conference_id.inspect}, notes: #{@notes.inspect}, signature:"\ " #{@signature.inspect}, additional_properties: #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
121 122 123 124 125 126 |
# File 'lib/calendar_api/models/conference_data.rb', line 121 def to_s class_name = self.class.name.split('::').last "<#{class_name} create_request: #{@create_request}, entry_points: #{@entry_points},"\ " conference_solution: #{@conference_solution}, conference_id: #{@conference_id}, notes:"\ " #{@notes}, signature: #{@signature}, additional_properties: #{@additional_properties}>" end |