Exception: Blather::SASLError
- Inherits:
-
BlatherError
- Object
- StandardError
- BlatherError
- Blather::SASLError
- Defined in:
- lib/blather/errors/sasl_error.rb
Overview
General SASL Errors Check #name for the error name
Constant Summary collapse
- SASL_ERR_NS =
'urn:ietf:params:xml:ns:xmpp-sasl'
- @@registrations =
{}
Class Method Summary collapse
-
.import(node) ⇒ Blather::SASLError
Import the stanza.
Instance Method Summary collapse
-
#initialize(node) ⇒ SASLError
constructor
Create a new SASLError.
-
#name ⇒ Symbol
The actual error name.
Methods inherited from BlatherError
Constructor Details
#initialize(node) ⇒ SASLError
Create a new SASLError
28 29 30 31 |
# File 'lib/blather/errors/sasl_error.rb', line 28 def initialize(node) super() @node = node end |
Class Method Details
.import(node) ⇒ Blather::SASLError
Import the stanza
21 22 23 |
# File 'lib/blather/errors/sasl_error.rb', line 21 def self.import(node) self.new node end |
Instance Method Details
#name ⇒ Symbol
The actual error name
36 37 38 39 40 41 |
# File 'lib/blather/errors/sasl_error.rb', line 36 def name if @node name = @node.find_first('ns:*', :ns => SASL_ERR_NS).element_name name.gsub('-', '_').to_sym end end |