Class: Unit::Types::Officer
- Inherits:
-
Object
- Object
- Unit::Types::Officer
- Defined in:
- lib/unit/types/officer.rb
Instance Attribute Summary collapse
-
#address ⇒ Object
readonly
Returns the value of attribute address.
-
#annual_income ⇒ Object
readonly
Returns the value of attribute annual_income.
-
#date_of_birth ⇒ Object
readonly
Returns the value of attribute date_of_birth.
-
#email ⇒ Object
readonly
Returns the value of attribute email.
-
#evaluation_params ⇒ Object
readonly
Returns the value of attribute evaluation_params.
-
#full_name ⇒ Object
readonly
Returns the value of attribute full_name.
-
#id_theft_score ⇒ Object
readonly
Returns the value of attribute id_theft_score.
-
#nationality ⇒ Object
readonly
Returns the value of attribute nationality.
-
#occupation ⇒ Object
readonly
Returns the value of attribute occupation.
-
#passport ⇒ Object
readonly
Returns the value of attribute passport.
-
#phone ⇒ Object
readonly
Returns the value of attribute phone.
-
#source_of_income ⇒ Object
readonly
Returns the value of attribute source_of_income.
-
#ssn ⇒ Object
readonly
Returns the value of attribute ssn.
-
#status ⇒ Object
readonly
Returns the value of attribute status.
-
#title ⇒ Object
readonly
Returns the value of attribute title.
Instance Method Summary collapse
-
#initialize(full_name, date_of_birth, address, phone, email, ssn, status = nil, title = nil, passport = nil, nationality = nil, evaluation_params = nil, id_theft_score = nil, occupation = nil, annual_income = nil, source_of_income = nil) ⇒ Officer
constructor
A new instance of Officer.
- #represent ⇒ Object
Constructor Details
#initialize(full_name, date_of_birth, address, phone, email, ssn, status = nil, title = nil, passport = nil, nationality = nil, evaluation_params = nil, id_theft_score = nil, occupation = nil, annual_income = nil, source_of_income = nil) ⇒ Officer
Returns a new instance of Officer.
21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 |
# File 'lib/unit/types/officer.rb', line 21 def initialize(full_name, date_of_birth, address, phone, email, ssn, status = nil, title = nil, passport = nil, nationality = nil, evaluation_params = nil, id_theft_score = nil, occupation = nil, annual_income = nil, source_of_income = nil) @full_name = full_name @date_of_birth = date_of_birth @address = address @phone = phone @email = email @status = status @title = title @ssn = ssn @passport = passport @nationality = nationality @evaluation_params = evaluation_params @id_theft_score = id_theft_score @occupation = occupation @annual_income = annual_income @source_of_income = source_of_income end |
Instance Attribute Details
#address ⇒ Object (readonly)
Returns the value of attribute address.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def address @address end |
#annual_income ⇒ Object (readonly)
Returns the value of attribute annual_income.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def annual_income @annual_income end |
#date_of_birth ⇒ Object (readonly)
Returns the value of attribute date_of_birth.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def date_of_birth @date_of_birth end |
#email ⇒ Object (readonly)
Returns the value of attribute email.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def email @email end |
#evaluation_params ⇒ Object (readonly)
Returns the value of attribute evaluation_params.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def evaluation_params @evaluation_params end |
#full_name ⇒ Object (readonly)
Returns the value of attribute full_name.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def full_name @full_name end |
#id_theft_score ⇒ Object (readonly)
Returns the value of attribute id_theft_score.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def id_theft_score @id_theft_score end |
#nationality ⇒ Object (readonly)
Returns the value of attribute nationality.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def nationality @nationality end |
#occupation ⇒ Object (readonly)
Returns the value of attribute occupation.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def occupation @occupation end |
#passport ⇒ Object (readonly)
Returns the value of attribute passport.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def passport @passport end |
#phone ⇒ Object (readonly)
Returns the value of attribute phone.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def phone @phone end |
#source_of_income ⇒ Object (readonly)
Returns the value of attribute source_of_income.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def source_of_income @source_of_income end |
#ssn ⇒ Object (readonly)
Returns the value of attribute ssn.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def ssn @ssn end |
#status ⇒ Object (readonly)
Returns the value of attribute status.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def status @status end |
#title ⇒ Object (readonly)
Returns the value of attribute title.
6 7 8 |
# File 'lib/unit/types/officer.rb', line 6 def title @title end |
Instance Method Details
#represent ⇒ Object
42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'lib/unit/types/officer.rb', line 42 def represent payload = { fullName: full_name.represent, dateOfBirth: date_of_birth, address: address.represent, phone: phone.represent, email: email, ssn: ssn, status: status, title: title, passport: passport, nationality: nationality, evaluation_params: evaluation_params, id_theft_score: id_theft_score, occupation: occupation, annual_income: annual_income, source_of_income: source_of_income } payload.compact end |