Class: Glosbe::Author
- Inherits:
-
Object
- Object
- Glosbe::Author
- Defined in:
- lib/glosbe/author.rb
Instance Attribute Summary collapse
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#source ⇒ Object
readonly
Returns the value of attribute source.
-
#url ⇒ Object
readonly
Returns the value of attribute url.
Instance Method Summary collapse
-
#initialize(data) ⇒ Author
constructor
A new instance of Author.
Constructor Details
#initialize(data) ⇒ Author
Returns a new instance of Author.
5 6 7 8 9 10 |
# File 'lib/glosbe/author.rb', line 5 def initialize(data) @id = data["id"] @name = data["N"] @source = data["U"] @url = data["url"] end |
Instance Attribute Details
#id ⇒ Object (readonly)
Returns the value of attribute id.
3 4 5 |
# File 'lib/glosbe/author.rb', line 3 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
3 4 5 |
# File 'lib/glosbe/author.rb', line 3 def name @name end |
#source ⇒ Object (readonly)
Returns the value of attribute source.
3 4 5 |
# File 'lib/glosbe/author.rb', line 3 def source @source end |
#url ⇒ Object (readonly)
Returns the value of attribute url.
3 4 5 |
# File 'lib/glosbe/author.rb', line 3 def url @url end |