Class: GetStream::Generated::Models::SharedLocationResponse
- Defined in:
- lib/getstream_ruby/generated/models/shared_location_response.rb
Instance Attribute Summary collapse
- #channel ⇒ ChannelResponse
-
#channel_cid ⇒ String
Channel CID.
-
#created_at ⇒ DateTime
Date/time of creation.
-
#created_by_device_id ⇒ String
Device ID that created the live location.
- #duration ⇒ String
-
#end_at ⇒ DateTime
Time when the live location expires.
-
#latitude ⇒ Float
Latitude coordinate.
-
#longitude ⇒ Float
Longitude coordinate.
- #message ⇒ MessageResponse
-
#message_id ⇒ String
Message ID.
-
#updated_at ⇒ DateTime
Date/time of the last update.
-
#user_id ⇒ String
User ID.
Class Method Summary collapse
-
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization.
Instance Method Summary collapse
-
#initialize(attributes = {}) ⇒ SharedLocationResponse
constructor
Initialize with attributes.
Methods inherited from BaseModel
#==, #inspect, omit_empty_fields, #to_h, #to_json
Constructor Details
#initialize(attributes = {}) ⇒ SharedLocationResponse
Initialize with attributes
50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 50 def initialize(attributes = {}) super(attributes) @channel_cid = attributes[:channel_cid] || attributes['channel_cid'] @created_at = attributes[:created_at] || attributes['created_at'] @created_by_device_id = attributes[:created_by_device_id] || attributes['created_by_device_id'] @duration = attributes[:duration] || attributes['duration'] @latitude = attributes[:latitude] || attributes['latitude'] @longitude = attributes[:longitude] || attributes['longitude'] @message_id = attributes[:message_id] || attributes['message_id'] @updated_at = attributes[:updated_at] || attributes['updated_at'] @user_id = attributes[:user_id] || attributes['user_id'] @end_at = attributes[:end_at] || attributes['end_at'] || nil @channel = attributes[:channel] || attributes['channel'] || nil @message = attributes[:message] || attributes['message'] || nil end |
Instance Attribute Details
#channel ⇒ ChannelResponse
44 45 46 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 44 def channel @channel end |
#channel_cid ⇒ String
Returns Channel CID.
14 15 16 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 14 def channel_cid @channel_cid end |
#created_at ⇒ DateTime
Returns Date/time of creation.
17 18 19 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 17 def created_at @created_at end |
#created_by_device_id ⇒ String
Returns Device ID that created the live location.
20 21 22 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 20 def created_by_device_id @created_by_device_id end |
#duration ⇒ String
23 24 25 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 23 def duration @duration end |
#end_at ⇒ DateTime
Returns Time when the live location expires.
41 42 43 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 41 def end_at @end_at end |
#latitude ⇒ Float
Returns Latitude coordinate.
26 27 28 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 26 def latitude @latitude end |
#longitude ⇒ Float
Returns Longitude coordinate.
29 30 31 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 29 def longitude @longitude end |
#message ⇒ MessageResponse
47 48 49 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 47 def @message end |
#message_id ⇒ String
Returns Message ID.
32 33 34 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 32 def @message_id end |
#updated_at ⇒ DateTime
Returns Date/time of the last update.
35 36 37 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 35 def updated_at @updated_at end |
#user_id ⇒ String
Returns User ID.
38 39 40 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 38 def user_id @user_id end |
Class Method Details
.json_field_mappings ⇒ Object
Override field mappings for JSON serialization
67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 |
# File 'lib/getstream_ruby/generated/models/shared_location_response.rb', line 67 def self.json_field_mappings { channel_cid: 'channel_cid', created_at: 'created_at', created_by_device_id: 'created_by_device_id', duration: 'duration', latitude: 'latitude', longitude: 'longitude', message_id: 'message_id', updated_at: 'updated_at', user_id: 'user_id', end_at: 'end_at', channel: 'channel', message: 'message' } end |