Class: Author
- Inherits:
-
Object
- Object
- Author
- Defined in:
- lib/stanzas/notification_stanza.rb
Instance Method Summary collapse
- #email ⇒ Object
-
#initialize(node) ⇒ Author
constructor
A new instance of Author.
- #name ⇒ Object
- #uri ⇒ Object
Constructor Details
#initialize(node) ⇒ Author
Returns a new instance of Author.
46 47 48 |
# File 'lib/stanzas/notification_stanza.rb', line 46 def initialize(node) @node = node end |
Instance Method Details
#email ⇒ Object
66 67 68 69 70 71 72 |
# File 'lib/stanzas/notification_stanza.rb', line 66 def email if !@email if email = @node.at_xpath("./atom:email", {"atom" => "http://www.w3.org/2005/Atom"}) @email = email.text end end end |
#name ⇒ Object
50 51 52 53 54 55 56 |
# File 'lib/stanzas/notification_stanza.rb', line 50 def name if !@name if name = @node.at_xpath("./atom:name", {"atom" => "http://www.w3.org/2005/Atom"}) @name = name.text end end end |
#uri ⇒ Object
58 59 60 61 62 63 64 |
# File 'lib/stanzas/notification_stanza.rb', line 58 def uri if !@uri if uri = @node.at_xpath("./atom:uri", {"atom" => "http://www.w3.org/2005/Atom"}) @uri = uri.text end end end |