lib/submodules/ably-ruby/lib/ably/models/protocol_message.rb in ably-rest-1.1.7 vs lib/submodules/ably-ruby/lib/ably/models/protocol_message.rb in ably-rest-1.1.8
- old
+ new
@@ -17,12 +17,10 @@
# @!attribute [r] channel
# @return [String] Channel name for messages
# @!attribute [r] channel_serial
# @return [String] Contains a serial number for a message on the current channel
# @!attribute [r] connection_id
- # @return [String] Contains a string public identifier for the connection
- # @!attribute [r] connection_key
# @return [String] Contains a string private connection key used to recover this connection
# @!attribute [r] connection_serial
# @return [Bignum] Contains a serial number for a message sent from the server to the client
# @!attribute [r] message_serial
# @return [Bignum] Contains a serial number for a message sent from the client to the server
@@ -96,16 +94,10 @@
define_method attribute do
attributes[attribute.to_sym]
end
end
- def connection_key
- # connection_key in connection details takes precedence over connection_key on the ProtocolMessage
- # connection_key in the ProtocolMessage will be deprecated in future protocol versions > 0.8
- connection_details.connection_key || attributes[:connection_key]
- end
-
def id!
raise RuntimeError, 'ProtocolMessage #id is nil' unless id
id
end
@@ -220,9 +212,14 @@
end
# @api private
def has_transient_flag?
flags & 16 == 16 # 2^4
+ end
+
+ # @api private
+ def has_attach_resume_flag?
+ flags & 32 == 32 # 2^5
end
# @api private
def has_attach_presence_flag?
flags & 65536 == 65536 # 2^16