Representation of Income data.

Sections
Namespace
Methods
I
N
T
Class Public methods
new(fields)
# File lib/plaid/income.rb, line 82
def initialize(fields)
  @income_streams = fields['income_streams'].map { |is| Stream.new(is) }

  %w(last_year_income last_year_income_before_tax projected_yearly_income
     projected_yearly_income_before_tax number_of_income_streams
     max_number_of_overlapping_income_streams).each do |field|
    instance_variable_set "@#{field}", fields[field]
  end
end
Public
Attributes
[R] income_streams

The Array of Stream.

[R] last_year_income

The Numeric sum of user's income over the past 365 days. If Plaid has less than 365 days of data this will be less than a full year income. E.g. 67000.

[R] last_year_income_before_tax

The #last_year_income interpolated to value before taxes. This is the minimum pre-tax salary that assumes a filing status of single with zero dependents. E.g. 73700.

[R] max_number_of_overlapping_income_streams

The Integer max number of income streams present at the same time over the past 365 days. E.g. 314.

[R] number_of_income_streams

The Integer total number of distinct income streams received over the past 365 days. E.g. 2.

[R] projected_yearly_income

The Numeric user's income extrapolated over a year based on current, active income streams. Income streams become inactive if they have not recurred for more than two cycles. For example, if a weekly paycheck hasn't been seen for the past two weeks, it is no longer active. E.g. 69800.

[R] projected_yearly_income_before_tax

The #projected_yearly_income interpolated to value before taxes. This is the minimum pre-tax salary that assumes a filing status of single with zero dependents. E.g. 75600.

Instance Public methods
inspect()

Get a String representation of Income.

Returns

Returns a String.

Also aliased as: to_s
# File lib/plaid/income.rb, line 95
def inspect
  "#<Plaid::Income last_year_income=#{last_year_income.inspect}, "          "projected_yearly_income=#{projected_yearly_income.inspect}, "          "number_of_income_streams=#{number_of_income_streams.inspect}, ...>"
end
to_s()

Get a String representation of Income.

Returns

Returns a String.

Alias for: inspect