Class: GustoEmbedded::Models::Shared::TimeOffPolicy
- Inherits:
-
Object
- Object
- GustoEmbedded::Models::Shared::TimeOffPolicy
- Extended by:
- T::Sig
- Includes:
- Crystalline::MetadataFields
- Defined in:
- lib/gusto_embedded/models/shared/time_off_policy.rb
Overview
Representation of a Time Off Policy
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(uuid:, company_uuid:, name:, policy_type:, accrual_method:, is_active:, employees:, paid_out_on_termination: nil, complete: nil, accrual_rate: nil, accrual_rate_unit: nil, accrual_waiting_period_days: nil, carryover_limit_hours: nil, max_accrual_hours_per_year: nil, max_hours: nil, policy_reset_date: nil, version: nil) ⇒ TimeOffPolicy
constructor
A new instance of TimeOffPolicy.
Methods included from Crystalline::MetadataFields
#field, #fields, included, #marshal_single, #to_dict, #to_json
Constructor Details
#initialize(uuid:, company_uuid:, name:, policy_type:, accrual_method:, is_active:, employees:, paid_out_on_termination: nil, complete: nil, accrual_rate: nil, accrual_rate_unit: nil, accrual_waiting_period_days: nil, carryover_limit_hours: nil, max_accrual_hours_per_year: nil, max_hours: nil, policy_reset_date: nil, version: nil) ⇒ TimeOffPolicy
Returns a new instance of TimeOffPolicy.
51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 |
# File 'lib/gusto_embedded/models/shared/time_off_policy.rb', line 51 def initialize(uuid:, company_uuid:, name:, policy_type:, accrual_method:, is_active:, employees:, paid_out_on_termination: nil, complete: nil, accrual_rate: nil, accrual_rate_unit: nil, accrual_waiting_period_days: nil, carryover_limit_hours: nil, max_accrual_hours_per_year: nil, max_hours: nil, policy_reset_date: nil, version: nil) @uuid = uuid @company_uuid = company_uuid @name = name @policy_type = policy_type @accrual_method = accrual_method @is_active = is_active @employees = employees @paid_out_on_termination = paid_out_on_termination @complete = complete @accrual_rate = accrual_rate @accrual_rate_unit = accrual_rate_unit @accrual_waiting_period_days = accrual_waiting_period_days @carryover_limit_hours = carryover_limit_hours @max_accrual_hours_per_year = max_accrual_hours_per_year @max_hours = max_hours @policy_reset_date = policy_reset_date @version = version end |
Instance Method Details
#==(other) ⇒ Object
72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 |
# File 'lib/gusto_embedded/models/shared/time_off_policy.rb', line 72 def ==(other) return false unless other.is_a? self.class return false unless @uuid == other.uuid return false unless @company_uuid == other.company_uuid return false unless @name == other.name return false unless @policy_type == other.policy_type return false unless @accrual_method == other.accrual_method return false unless @is_active == other.is_active return false unless @employees == other.employees return false unless @paid_out_on_termination == other.paid_out_on_termination return false unless @complete == other.complete return false unless @accrual_rate == other.accrual_rate return false unless @accrual_rate_unit == other.accrual_rate_unit return false unless @accrual_waiting_period_days == other.accrual_waiting_period_days return false unless @carryover_limit_hours == other.carryover_limit_hours return false unless @max_accrual_hours_per_year == other.max_accrual_hours_per_year return false unless @max_hours == other.max_hours return false unless @policy_reset_date == other.policy_reset_date return false unless @version == other.version true end |