Class | Jabber::Caps::C |
In: |
lib/xmpp4r/caps/c.rb
|
Parent: | XMPPElement |
The <c/> XMPP element, used to advertise entity capabilities.
See www.xmpp.org/extensions/xep-0115.html#protocol.
You should not need to construct this element directly, see Jabber::Caps::Helper.
# File lib/xmpp4r/caps/c.rb, line 22 22: def initialize(node = nil, ver = nil) 23: super() 24: add_attribute('node', node) if node 25: if ver 26: add_attribute('ver', ver) 27: add_attribute('hash', 'sha-1') 28: end 29: end
Is this a legacy caps response, as defined by version 1.3 of the XEP-0115 specification?
# File lib/xmpp4r/caps/c.rb, line 62 62: def legacy? 63: hash.nil? || hash.empty? 64: end