Module: Ably::Models
- Defined in:
- lib/ably-rest/modules/eventmachine_deferrable.rb,
lib/ably-rest/modules/eventmachine_deferrable.rb,
lib/submodules/ably-ruby/lib/ably/models/stats.rb,
lib/submodules/ably-ruby/lib/ably/models/message.rb,
lib/submodules/ably-ruby/lib/ably/models/error_info.rb,
lib/submodules/ably-ruby/lib/ably/models/nil_logger.rb,
lib/submodules/ably-ruby/lib/ably/models/stats_types.rb,
lib/submodules/ably-ruby/lib/ably/models/auth_details.rb,
lib/submodules/ably-ruby/lib/ably/models/delta_extras.rb,
lib/submodules/ably-ruby/lib/ably/models/cipher_params.rb,
lib/submodules/ably-ruby/lib/ably/models/token_details.rb,
lib/submodules/ably-ruby/lib/ably/models/token_request.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_status.rb,
lib/submodules/ably-ruby/lib/ably/models/device_details.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_details.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_metrics.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_options.rb,
lib/submodules/ably-ruby/lib/ably/models/paginated_result.rb,
lib/submodules/ably-ruby/lib/ably/models/presence_message.rb,
lib/submodules/ably-ruby/lib/ably/models/protocol_message.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_occupancy.rb,
lib/submodules/ably-ruby/lib/ably/models/connection_details.rb,
lib/submodules/ably-ruby/lib/ably/models/device_push_details.rb,
lib/submodules/ably-ruby/lib/ably/models/channel_state_change.rb,
lib/submodules/ably-ruby/lib/ably/models/message_encoders/base.rb,
lib/submodules/ably-ruby/lib/ably/models/idiomatic_ruby_wrapper.rb,
lib/submodules/ably-ruby/lib/ably/models/connection_state_change.rb,
lib/submodules/ably-ruby/lib/ably/models/http_paginated_response.rb,
lib/submodules/ably-ruby/lib/ably/models/push_channel_subscription.rb
Defined Under Namespace
Modules: MessageEncoders Classes: AuthDetails, ChannelDetails, ChannelMetrics, ChannelOccupancy, ChannelOptions, ChannelStateChange, ChannelStatus, CipherParams, ConnectionDetails, ConnectionStateChange, DeltaExtras, DeviceDetails, DevicePushDetails, ErrorInfo, HttpPaginatedResponse, IdiomaticRubyWrapper, Message, NilLogger, PaginatedResult, PresenceMessage, ProtocolMessage, PushChannelSubscription, Stats, TokenDetails, TokenRequest
Class Method Summary collapse
-
.AuthDetails(attributes) ⇒ AuthDetails
Convert auth details attributes to a AuthDetails object.
-
.ChannelDetails(attributes) ⇒ ChannelDetails
Convert token details argument to a ChannelDetails object.
-
.ChannelMetrics(attributes) ⇒ ChannelMetrics
Convert token details argument to a ChannelMetrics object.
-
.ChannelOccupancy(attributes) ⇒ ChannelOccupancy
Convert token details argument to a ChannelOccupancy object.
-
.ChannelOptions(attributes) ⇒ ChannelOptions
Convert token details argument to a ChannelOptions object.
-
.ChannelStatus(attributes) ⇒ ChannelStatus
Convert token details argument to a ChannelStatus object.
-
.CipherParams(attributes) ⇒ CipherParams
Convert cipher param attributes to a CipherParams object.
-
.ConnectionDetails(attributes) ⇒ ConnectionDetails
Convert connection details attributes to a ConnectionDetails object.
-
.Message(message, options = {}) ⇒ Message
Convert messsage argument to a Message object and associate with a protocol message if provided.
-
.PresenceMessage(presence_message, options = {}) ⇒ PresenceMessage
Convert presence_messsage argument to a PresenceMessage object and associate with a protocol message if provided.
-
.Stats(stat) ⇒ Stats
Convert stat argument to a Stats object.
-
.TokenDetails(attributes) ⇒ TokenDetails
Convert token details argument to a TokenDetails object.
-
.TokenRequest(attributes) ⇒ TokenRequest
Convert token request argument to a TokenRequest object.
Class Method Details
.AuthDetails(attributes) ⇒ AuthDetails
Convert auth details attributes to a AuthDetails object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/auth_details.rb', line 8 def self.AuthDetails(attributes) case attributes when AuthDetails return attributes else AuthDetails.new(attributes || {}) end end |
.ChannelDetails(attributes) ⇒ ChannelDetails
Convert token details argument to a ChannelDetails object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/channel_details.rb', line 8 def self.ChannelDetails(attributes) case attributes when ChannelDetails return attributes else ChannelDetails.new(attributes) end end |
.ChannelMetrics(attributes) ⇒ ChannelMetrics
Convert token details argument to a ChannelMetrics object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/channel_metrics.rb', line 8 def self.ChannelMetrics(attributes) case attributes when ChannelMetrics return attributes else ChannelMetrics.new(attributes) end end |
.ChannelOccupancy(attributes) ⇒ ChannelOccupancy
Convert token details argument to a ChannelOccupancy object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/channel_occupancy.rb', line 8 def self.ChannelOccupancy(attributes) case attributes when ChannelOccupancy return attributes else ChannelOccupancy.new(attributes) end end |
.ChannelOptions(attributes) ⇒ ChannelOptions
Convert token details argument to a ChannelOptions object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/channel_options.rb', line 8 def self.ChannelOptions(attributes) case attributes when ChannelOptions return attributes else ChannelOptions.new(attributes) end end |
.ChannelStatus(attributes) ⇒ ChannelStatus
Convert token details argument to a ChannelStatus object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/channel_status.rb', line 8 def self.ChannelStatus(attributes) case attributes when ChannelStatus return attributes else ChannelStatus.new(attributes) end end |
.CipherParams(attributes) ⇒ CipherParams
Convert cipher param attributes to a CipherParams object
11 12 13 14 15 16 17 18 |
# File 'lib/submodules/ably-ruby/lib/ably/models/cipher_params.rb', line 11 def self.CipherParams(attributes) case attributes when CipherParams return attributes else CipherParams.new(attributes || {}) end end |
.ConnectionDetails(attributes) ⇒ ConnectionDetails
Convert connection details attributes to a ConnectionDetails object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/connection_details.rb', line 8 def self.ConnectionDetails(attributes) case attributes when ConnectionDetails return attributes else ConnectionDetails.new(attributes || {}) end end |
.Message(message, options = {}) ⇒ Message
Convert messsage argument to a Message object and associate with a protocol message if provided
11 12 13 14 15 16 17 18 19 20 |
# File 'lib/submodules/ably-ruby/lib/ably/models/message.rb', line 11 def self.Message(, = {}) case when Message .tap do . [:protocol_message] if [:protocol_message] end else Message.new(, ) end end |
.PresenceMessage(presence_message, options = {}) ⇒ PresenceMessage
Convert presence_messsage argument to a PresenceMessage object and associate with a protocol message if provided
9 10 11 12 13 14 15 16 17 18 |
# File 'lib/submodules/ably-ruby/lib/ably/models/presence_message.rb', line 9 def self.PresenceMessage(, = {}) case when PresenceMessage .tap do . [:protocol_message] if [:protocol_message] end else PresenceMessage.new(, ) end end |
.Stats(stat) ⇒ Stats
Convert stat argument to a Stats object
9 10 11 12 13 14 15 16 |
# File 'lib/submodules/ably-ruby/lib/ably/models/stats.rb', line 9 def self.Stats(stat) case stat when Stats stat else Stats.new(stat) end end |
.TokenDetails(attributes) ⇒ TokenDetails
Convert token details argument to a TokenDetails object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/token_details.rb', line 8 def self.TokenDetails(attributes) case attributes when TokenDetails return attributes else TokenDetails.new(attributes) end end |
.TokenRequest(attributes) ⇒ TokenRequest
Convert token request argument to a TokenRequest object
8 9 10 11 12 13 14 15 |
# File 'lib/submodules/ably-ruby/lib/ably/models/token_request.rb', line 8 def self.TokenRequest(attributes) case attributes when TokenRequest return attributes else TokenRequest.new(attributes) end end |