class Vines::Stream::Http::Bind

Constants

FEATURES

Public Class Methods

new(stream, success=Ready) click to toggle source
Calls superclass method Vines::Stream::Client::Bind::new
# File lib/vines/stream/http/bind.rb, line 9
def initialize(stream, success=Ready)
  super
end

Public Instance Methods

node(node) click to toggle source
Calls superclass method Vines::Stream::Client::Bind#node
# File lib/vines/stream/http/bind.rb, line 13
def node(node)
  unless stream.valid_session?(node['sid']) && body?(node) && node['rid']
    raise StreamErrors::NotAuthorized
  end
  nodes = stream.parse_body(node)
  raise StreamErrors::NotAuthorized unless nodes.size == 1
  super(nodes.first)
end

Private Instance Methods

send_empty_features() click to toggle source

Override Client::Bind#send_empty_features to properly namespace the empty features element.

# File lib/vines/stream/http/bind.rb, line 26
def send_empty_features
  stream.write(FEATURES)
end