Class: Todoist::Label
- Inherits:
-
Struct
- Object
- Struct
- Todoist::Label
- Includes:
- StructCleanup
- Defined in:
- lib/todoist/label.rb
Instance Attribute Summary collapse
-
#color ⇒ Object
Returns the value of attribute color.
-
#id ⇒ Object
Returns the value of attribute id.
-
#is_deleted ⇒ Object
Returns the value of attribute is_deleted.
-
#is_favorite ⇒ Object
Returns the value of attribute is_favorite.
-
#jsw_ignored_keys ⇒ Object
Returns the value of attribute jsw_ignored_keys.
-
#name ⇒ Object
Returns the value of attribute name.
-
#order ⇒ Object
Returns the value of attribute order.
Instance Method Summary collapse
- #deleted? ⇒ Boolean
- #favorite? ⇒ Boolean
-
#initialize(*arg_hashes) ⇒ Label
constructor
A new instance of Label.
Methods included from StructCleanup
#fields_to_date_time, #ignore_undefined_keys, #properties_to_desc, #replace_keys
Constructor Details
#initialize(*arg_hashes) ⇒ Label
Returns a new instance of Label.
14 15 16 17 18 19 |
# File 'lib/todoist/label.rb', line 14 def initialize(*arg_hashes) args = arg_hashes.first ignore_undefined_keys(args) replace_keys(args, {item_order: :order}) super end |
Instance Attribute Details
#color ⇒ Object
Returns the value of attribute color
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def color @color end |
#id ⇒ Object
Returns the value of attribute id
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def id @id end |
#is_deleted ⇒ Object
Returns the value of attribute is_deleted
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def is_deleted @is_deleted end |
#is_favorite ⇒ Object
Returns the value of attribute is_favorite
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def is_favorite @is_favorite end |
#jsw_ignored_keys ⇒ Object
Returns the value of attribute jsw_ignored_keys
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def jsw_ignored_keys @jsw_ignored_keys end |
#name ⇒ Object
Returns the value of attribute name
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def name @name end |
#order ⇒ Object
Returns the value of attribute order
2 3 4 |
# File 'lib/todoist/label.rb', line 2 def order @order end |
Instance Method Details
#deleted? ⇒ Boolean
21 22 23 |
# File 'lib/todoist/label.rb', line 21 def deleted? is_deleted.present? end |
#favorite? ⇒ Boolean
25 26 27 |
# File 'lib/todoist/label.rb', line 25 def favorite? is_favorite.present? end |