Class: Registrar::ExtendedAttributeDescriptor

Inherits:
Object
  • Object
show all
Defined in:
lib/registrar/extended_attribute_descriptor.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeExtendedAttributeDescriptor

Returns a new instance of ExtendedAttributeDescriptor.



17
18
19
# File 'lib/registrar/extended_attribute_descriptor.rb', line 17

def initialize
  @options = []
end

Instance Attribute Details

#applicationObject

Returns the value of attribute application.



7
8
9
# File 'lib/registrar/extended_attribute_descriptor.rb', line 7

def application
  @application
end

#apply_to_registrarObject Also known as: apply_to_registrar?

Returns the value of attribute apply_to_registrar.



10
11
12
# File 'lib/registrar/extended_attribute_descriptor.rb', line 10

def apply_to_registrar
  @apply_to_registrar
end

#childObject Also known as: child?

Returns the value of attribute child.



6
7
8
# File 'lib/registrar/extended_attribute_descriptor.rb', line 6

def child
  @child
end

#descriptionObject

Returns the value of attribute description.



4
5
6
# File 'lib/registrar/extended_attribute_descriptor.rb', line 4

def description
  @description
end

#nameObject

Returns the value of attribute name.



3
4
5
# File 'lib/registrar/extended_attribute_descriptor.rb', line 3

def name
  @name
end

#optionsObject

Returns the value of attribute options.



9
10
11
# File 'lib/registrar/extended_attribute_descriptor.rb', line 9

def options
  @options
end

#requiredObject Also known as: required?

Returns the value of attribute required.



5
6
7
# File 'lib/registrar/extended_attribute_descriptor.rb', line 5

def required
  @required
end

#user_definedObject Also known as: user_defined?

Returns the value of attribute user_defined.



8
9
10
# File 'lib/registrar/extended_attribute_descriptor.rb', line 8

def user_defined
  @user_defined
end

Instance Method Details

#serializable_hashObject



21
22
23
24
25
26
27
28
# File 'lib/registrar/extended_attribute_descriptor.rb', line 21

def serializable_hash 
  {
    'name' => name, 
    'description' => description,
    'required' => required,
    'options' => options
  }
end