Class: Telephone
- Inherits:
-
ContactAttribute
- Object
- LogicalModel
- ContactAttribute
- Telephone
- Includes:
- ActiveModel::Validations::Callbacks
- Defined in:
- app/models/telephone.rb
Constant Summary
Constants inherited from ContactAttribute
ContactAttribute::AVAILABLE_TYPES
Instance Attribute Summary collapse
-
#category ⇒ Object
Returns the value of attribute category.
-
#primary ⇒ Object
Returns the value of attribute primary.
-
#public ⇒ Object
Returns the value of attribute public.
-
#value ⇒ Object
Returns the value of attribute value.
Instance Method Summary collapse
Methods inherited from ContactAttribute
#_create, #always_public?, #id, #id=, #json_root, #new_record?, #to_key
Methods included from ContactAttribute::CustomKeys
#async_custom_keys, #custom_keys
Instance Attribute Details
#category ⇒ Object
Returns the value of attribute category.
13 14 15 |
# File 'app/models/telephone.rb', line 13 def category @category end |
#primary ⇒ Object
Returns the value of attribute primary.
13 14 15 |
# File 'app/models/telephone.rb', line 13 def primary @primary end |
#public ⇒ Object
Returns the value of attribute public.
13 14 15 |
# File 'app/models/telephone.rb', line 13 def public @public end |
#value ⇒ Object
Returns the value of attribute value.
13 14 15 |
# File 'app/models/telephone.rb', line 13 def value @value end |
Instance Method Details
#_type ⇒ Object
22 23 24 |
# File 'app/models/telephone.rb', line 22 def _type self.class.name end |
#masked? ⇒ Boolean
18 19 20 |
# File 'app/models/telephone.rb', line 18 def masked? value.present? && value.last == '#' end |