Class: FdxV660Api::Form1041ScheduleK11
- Inherits:
-
BaseModel
- Object
- CoreLibrary::BaseModel
- BaseModel
- FdxV660Api::Form1041ScheduleK11
- Defined in:
- lib/fdx_v660_api/models/form1041_schedule_k11.rb
Overview
Beneficiary's Share of Income, Deductions, Credits, etc.
Instance Attribute Summary collapse
-
#account_id ⇒ String
Long-term persistent identity of the source account.
-
#additional_information ⇒ String
Additional explanation text or content about this tax form.
-
#amended_k1 ⇒ TrueClass | FalseClass
Amended K-1.
-
#amt_adjustments ⇒ Array[CodeAndAmount]
Box 12, Alternative minimum tax adjustment.
-
#attributes ⇒ Array[TaxFormAttribute]
Additional attributes for this tax form when defined fields are not available.
-
#corrected ⇒ TrueClass | FalseClass
True to indicate this is a corrected tax form.
-
#credits ⇒ Array[CodeAndAmount]
Box 13, Credits and credit recapture.
-
#date1041_t ⇒ Date
Box D, and enter the date it was filed.
-
#directly_apportioned_deductions ⇒ Array[CodeAndAmount]
Box 9, Directly apportioned deductions.
-
#domestic ⇒ TrueClass | FalseClass
Box H, Domestic beneficiary.
-
#error ⇒ Error2
Present if an error was encountered while retrieving this form.
-
#estate_tax_deduction ⇒ Float
Box 10, Estate tax deduction.
-
#fiduciary ⇒ TaxParty2
Box C, Fiduciary's name and address.
-
#final1041 ⇒ TrueClass | FalseClass
Box E, Check if this is the final Form 1041 for the estate or trust.
-
#final_k1 ⇒ TrueClass | FalseClass
Final K-1.
-
#final_year_deductions ⇒ Array[CodeAndAmount]
Box 11, Final year deductions.
-
#fiscal_year_begin ⇒ Date
Fiscal year begin date.
-
#fiscal_year_end ⇒ Date
Fiscal year end date.
-
#foreign ⇒ TrueClass | FalseClass
Box H, Foreign beneficiary.
-
#form1041_t ⇒ TrueClass | FalseClass
Box D, Check if Form 1041-T was filed.
-
#gain28_rate ⇒ Float
Box 4b, 28% rate gain.
-
#interest_income ⇒ Float
Box 1, Interest income.
-
#issuer ⇒ TaxParty8
Issuer's name, address, phone, and TIN.
-
#links ⇒ Array[HateoasLink]
Links to retrieve this form as data or image, or to invoke other APIs.
-
#net_long_term_gain ⇒ Float
Box 4a, Net long-term capital gain.
-
#net_rental_real_estate_income ⇒ Float
Box 7, Net rental real estate income.
-
#net_short_term_gain ⇒ Float
Box 3, Net short-term capital gain.
-
#ordinary_business_income ⇒ Float
Box 6, Ordinary business income.
-
#ordinary_dividends ⇒ Float
Box 2a, Ordinary dividends.
-
#other_info ⇒ Array[CodeAndAmount]
Box 14, Other information.
-
#other_portfolio_income ⇒ Float
Box 5, Other portfolio and nonbusiness income.
-
#other_rental_income ⇒ Float
Box 8, Other rental income.
-
#qualified_dividends ⇒ Float
Box 2b, Qualified dividends.
-
#recipient ⇒ TaxParty1
Recipient's name, address, phone, and TIN.
-
#tax_form_date ⇒ Date
Date of production or delivery of the tax form.
-
#tax_form_id ⇒ String
Long-term persistent id for this tax form.
-
#tax_form_type ⇒ TypeFormType1
Enumerated name of the tax form entity e.g.
-
#tax_year ⇒ Integer
Year for which taxes are being paid.
-
#unrecaptured1250_gain ⇒ Float
Box 4c, Unrecaptured section 1250 gain.
Class Method Summary collapse
-
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
-
.names ⇒ Object
A mapping from model property names to API property names.
-
.nullables ⇒ Object
An array for nullable fields.
-
.optionals ⇒ Object
An array for optional fields.
Instance Method Summary collapse
-
#initialize(tax_year: SKIP, corrected: SKIP, account_id: SKIP, tax_form_id: SKIP, tax_form_date: SKIP, additional_information: SKIP, tax_form_type: SKIP, issuer: SKIP, recipient: SKIP, attributes: SKIP, error: SKIP, links: SKIP, final_k1: SKIP, amended_k1: SKIP, fiscal_year_begin: SKIP, fiscal_year_end: SKIP, fiduciary: SKIP, form1041_t: SKIP, date1041_t: SKIP, final1041: SKIP, domestic: SKIP, foreign: SKIP, interest_income: SKIP, ordinary_dividends: SKIP, qualified_dividends: SKIP, net_short_term_gain: SKIP, net_long_term_gain: SKIP, gain28_rate: SKIP, unrecaptured1250_gain: SKIP, other_portfolio_income: SKIP, ordinary_business_income: SKIP, net_rental_real_estate_income: SKIP, other_rental_income: SKIP, directly_apportioned_deductions: SKIP, estate_tax_deduction: SKIP, final_year_deductions: SKIP, amt_adjustments: SKIP, credits: SKIP, other_info: SKIP, additional_properties: nil) ⇒ Form1041ScheduleK11
constructor
A new instance of Form1041ScheduleK11.
-
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
-
#to_s ⇒ Object
Provides a human-readable string representation of the object.
Methods inherited from BaseModel
#check_for_conflict, #process_additional_properties, #process_array, #process_basic_value, #process_hash, #to_hash, #to_json
Constructor Details
#initialize(tax_year: SKIP, corrected: SKIP, account_id: SKIP, tax_form_id: SKIP, tax_form_date: SKIP, additional_information: SKIP, tax_form_type: SKIP, issuer: SKIP, recipient: SKIP, attributes: SKIP, error: SKIP, links: SKIP, final_k1: SKIP, amended_k1: SKIP, fiscal_year_begin: SKIP, fiscal_year_end: SKIP, fiduciary: SKIP, form1041_t: SKIP, date1041_t: SKIP, final1041: SKIP, domestic: SKIP, foreign: SKIP, interest_income: SKIP, ordinary_dividends: SKIP, qualified_dividends: SKIP, net_short_term_gain: SKIP, net_long_term_gain: SKIP, gain28_rate: SKIP, unrecaptured1250_gain: SKIP, other_portfolio_income: SKIP, ordinary_business_income: SKIP, net_rental_real_estate_income: SKIP, other_rental_income: SKIP, directly_apportioned_deductions: SKIP, estate_tax_deduction: SKIP, final_year_deductions: SKIP, amt_adjustments: SKIP, credits: SKIP, other_info: SKIP, additional_properties: nil) ⇒ Form1041ScheduleK11
Returns a new instance of Form1041ScheduleK11.
277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 277 def initialize(tax_year: SKIP, corrected: SKIP, account_id: SKIP, tax_form_id: SKIP, tax_form_date: SKIP, additional_information: SKIP, tax_form_type: SKIP, issuer: SKIP, recipient: SKIP, attributes: SKIP, error: SKIP, links: SKIP, final_k1: SKIP, amended_k1: SKIP, fiscal_year_begin: SKIP, fiscal_year_end: SKIP, fiduciary: SKIP, form1041_t: SKIP, date1041_t: SKIP, final1041: SKIP, domestic: SKIP, foreign: SKIP, interest_income: SKIP, ordinary_dividends: SKIP, qualified_dividends: SKIP, net_short_term_gain: SKIP, net_long_term_gain: SKIP, gain28_rate: SKIP, unrecaptured1250_gain: SKIP, other_portfolio_income: SKIP, ordinary_business_income: SKIP, net_rental_real_estate_income: SKIP, other_rental_income: SKIP, directly_apportioned_deductions: SKIP, estate_tax_deduction: SKIP, final_year_deductions: SKIP, amt_adjustments: SKIP, credits: SKIP, other_info: SKIP, additional_properties: nil) # Add additional model properties to the instance additional_properties = {} if additional_properties.nil? @tax_year = tax_year unless tax_year == SKIP @corrected = corrected unless corrected == SKIP @account_id = account_id unless account_id == SKIP @tax_form_id = tax_form_id unless tax_form_id == SKIP @tax_form_date = tax_form_date unless tax_form_date == SKIP @additional_information = additional_information unless additional_information == SKIP @tax_form_type = tax_form_type unless tax_form_type == SKIP @issuer = issuer unless issuer == SKIP @recipient = recipient unless recipient == SKIP @attributes = attributes unless attributes == SKIP @error = error unless error == SKIP @links = links unless links == SKIP @final_k1 = final_k1 unless final_k1 == SKIP @amended_k1 = amended_k1 unless amended_k1 == SKIP @fiscal_year_begin = fiscal_year_begin unless fiscal_year_begin == SKIP @fiscal_year_end = fiscal_year_end unless fiscal_year_end == SKIP @fiduciary = fiduciary unless fiduciary == SKIP @form1041_t = form1041_t unless form1041_t == SKIP @date1041_t = date1041_t unless date1041_t == SKIP @final1041 = final1041 unless final1041 == SKIP @domestic = domestic unless domestic == SKIP @foreign = foreign unless foreign == SKIP @interest_income = interest_income unless interest_income == SKIP @ordinary_dividends = ordinary_dividends unless ordinary_dividends == SKIP @qualified_dividends = qualified_dividends unless qualified_dividends == SKIP @net_short_term_gain = net_short_term_gain unless net_short_term_gain == SKIP @net_long_term_gain = net_long_term_gain unless net_long_term_gain == SKIP @gain28_rate = gain28_rate unless gain28_rate == SKIP @unrecaptured1250_gain = unrecaptured1250_gain unless unrecaptured1250_gain == SKIP @other_portfolio_income = other_portfolio_income unless other_portfolio_income == SKIP @ordinary_business_income = ordinary_business_income unless ordinary_business_income == SKIP unless net_rental_real_estate_income == SKIP @net_rental_real_estate_income = net_rental_real_estate_income end @other_rental_income = other_rental_income unless other_rental_income == SKIP unless directly_apportioned_deductions == SKIP @directly_apportioned_deductions = directly_apportioned_deductions end @estate_tax_deduction = estate_tax_deduction unless estate_tax_deduction == SKIP @final_year_deductions = final_year_deductions unless final_year_deductions == SKIP @amt_adjustments = amt_adjustments unless amt_adjustments == SKIP @credits = credits unless credits == SKIP @other_info = other_info unless other_info == SKIP @additional_properties = additional_properties end |
Instance Attribute Details
#account_id ⇒ String
Long-term persistent identity of the source account. Not the account number
23 24 25 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 23 def account_id @account_id end |
#additional_information ⇒ String
Additional explanation text or content about this tax form
37 38 39 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 37 def additional_information @additional_information end |
#amended_k1 ⇒ TrueClass | FalseClass
Amended K-1
79 80 81 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 79 def amended_k1 @amended_k1 end |
#amt_adjustments ⇒ Array[CodeAndAmount]
Box 12, Alternative minimum tax adjustment
171 172 173 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 171 def amt_adjustments @amt_adjustments end |
#attributes ⇒ Array[TaxFormAttribute]
Additional attributes for this tax form when defined fields are not available. Some specific additional attributes already defined by providers: Fields required by [IRS FIRE](https://www.irs.gov/e-file-providers/filing-information-returns-elec tronically-fire): Name Control, Type of Identification Number (EIN, SSN, ITIN, ATIN). (ATIN is tax ID number for pending adoptions.) Tax form provider field for taxpayer notification: Recipient Email Address.
63 64 65 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 63 def attributes @attributes end |
#corrected ⇒ TrueClass | FalseClass
True to indicate this is a corrected tax form
18 19 20 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 18 def corrected @corrected end |
#credits ⇒ Array[CodeAndAmount]
Box 13, Credits and credit recapture
175 176 177 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 175 def credits @credits end |
#date1041_t ⇒ Date
Box D, and enter the date it was filed
99 100 101 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 99 def date1041_t @date1041_t end |
#directly_apportioned_deductions ⇒ Array[CodeAndAmount]
Box 9, Directly apportioned deductions
159 160 161 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 159 def directly_apportioned_deductions @directly_apportioned_deductions end |
#domestic ⇒ TrueClass | FalseClass
Box H, Domestic beneficiary
107 108 109 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 107 def domestic @domestic end |
#error ⇒ Error2
Present if an error was encountered while retrieving this form
67 68 69 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 67 def error @error end |
#estate_tax_deduction ⇒ Float
Box 10, Estate tax deduction
163 164 165 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 163 def estate_tax_deduction @estate_tax_deduction end |
#fiduciary ⇒ TaxParty2
Box C, Fiduciary's name and address
91 92 93 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 91 def fiduciary @fiduciary end |
#final1041 ⇒ TrueClass | FalseClass
Box E, Check if this is the final Form 1041 for the estate or trust
103 104 105 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 103 def final1041 @final1041 end |
#final_k1 ⇒ TrueClass | FalseClass
Final K-1
75 76 77 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 75 def final_k1 @final_k1 end |
#final_year_deductions ⇒ Array[CodeAndAmount]
Box 11, Final year deductions
167 168 169 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 167 def final_year_deductions @final_year_deductions end |
#fiscal_year_begin ⇒ Date
Fiscal year begin date
83 84 85 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 83 def fiscal_year_begin @fiscal_year_begin end |
#fiscal_year_end ⇒ Date
Fiscal year end date
87 88 89 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 87 def fiscal_year_end @fiscal_year_end end |
#foreign ⇒ TrueClass | FalseClass
Box H, Foreign beneficiary
111 112 113 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 111 def foreign @foreign end |
#form1041_t ⇒ TrueClass | FalseClass
Box D, Check if Form 1041-T was filed
95 96 97 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 95 def form1041_t @form1041_t end |
#gain28_rate ⇒ Float
Box 4b, 28% rate gain
135 136 137 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 135 def gain28_rate @gain28_rate end |
#interest_income ⇒ Float
Box 1, Interest income
115 116 117 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 115 def interest_income @interest_income end |
#issuer ⇒ TaxParty8
Issuer's name, address, phone, and TIN. Issuer data need only be transmitted on enclosing TaxStatement, if it is the same on all its included tax forms.
47 48 49 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 47 def issuer @issuer end |
#links ⇒ Array[HateoasLink]
Links to retrieve this form as data or image, or to invoke other APIs
71 72 73 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 71 def links @links end |
#net_long_term_gain ⇒ Float
Box 4a, Net long-term capital gain
131 132 133 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 131 def net_long_term_gain @net_long_term_gain end |
#net_rental_real_estate_income ⇒ Float
Box 7, Net rental real estate income
151 152 153 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 151 def net_rental_real_estate_income @net_rental_real_estate_income end |
#net_short_term_gain ⇒ Float
Box 3, Net short-term capital gain
127 128 129 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 127 def net_short_term_gain @net_short_term_gain end |
#ordinary_business_income ⇒ Float
Box 6, Ordinary business income
147 148 149 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 147 def ordinary_business_income @ordinary_business_income end |
#ordinary_dividends ⇒ Float
Box 2a, Ordinary dividends
119 120 121 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 119 def ordinary_dividends @ordinary_dividends end |
#other_info ⇒ Array[CodeAndAmount]
Box 14, Other information
179 180 181 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 179 def other_info @other_info end |
#other_portfolio_income ⇒ Float
Box 5, Other portfolio and nonbusiness income
143 144 145 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 143 def other_portfolio_income @other_portfolio_income end |
#other_rental_income ⇒ Float
Box 8, Other rental income
155 156 157 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 155 def other_rental_income @other_rental_income end |
#qualified_dividends ⇒ Float
Box 2b, Qualified dividends
123 124 125 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 123 def qualified_dividends @qualified_dividends end |
#recipient ⇒ TaxParty1
Recipient's name, address, phone, and TIN. Recipient data need only be transmitted on enclosing TaxStatement, if it is the same on all its included tax forms.
53 54 55 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 53 def recipient @recipient end |
#tax_form_date ⇒ Date
Date of production or delivery of the tax form
33 34 35 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 33 def tax_form_date @tax_form_date end |
#tax_form_id ⇒ String
Long-term persistent id for this tax form. Depending upon the data provider, this may be the same id as the enclosing tax statement id, or this may be a different id, or this id may be omitted.
29 30 31 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 29 def tax_form_id @tax_form_id end |
#tax_form_type ⇒ TypeFormType1
Enumerated name of the tax form entity e.g. "TaxW2"
41 42 43 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 41 def tax_form_type @tax_form_type end |
#tax_year ⇒ Integer
Year for which taxes are being paid
14 15 16 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 14 def tax_year @tax_year end |
#unrecaptured1250_gain ⇒ Float
Box 4c, Unrecaptured section 1250 gain
139 140 141 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 139 def unrecaptured1250_gain @unrecaptured1250_gain end |
Class Method Details
.from_hash(hash) ⇒ Object
Creates an instance of the object from a hash.
348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 348 def self.from_hash(hash) return nil unless hash # Extract variables from the hash. tax_year = hash.key?('taxYear') ? hash['taxYear'] : SKIP corrected = hash.key?('corrected') ? hash['corrected'] : SKIP account_id = hash.key?('accountId') ? hash['accountId'] : SKIP tax_form_id = hash.key?('taxFormId') ? hash['taxFormId'] : SKIP tax_form_date = hash.key?('taxFormDate') ? hash['taxFormDate'] : SKIP additional_information = hash.key?('additionalInformation') ? hash['additionalInformation'] : SKIP tax_form_type = hash.key?('taxFormType') ? hash['taxFormType'] : SKIP issuer = TaxParty8.from_hash(hash['issuer']) if hash['issuer'] recipient = TaxParty1.from_hash(hash['recipient']) if hash['recipient'] # Parameter is an array, so we need to iterate through it attributes = nil unless hash['attributes'].nil? attributes = [] hash['attributes'].each do |structure| attributes << (TaxFormAttribute.from_hash(structure) if structure) end end attributes = SKIP unless hash.key?('attributes') error = Error2.from_hash(hash['error']) if hash['error'] # Parameter is an array, so we need to iterate through it links = nil unless hash['links'].nil? links = [] hash['links'].each do |structure| links << (HateoasLink.from_hash(structure) if structure) end end links = SKIP unless hash.key?('links') final_k1 = hash.key?('finalK1') ? hash['finalK1'] : SKIP amended_k1 = hash.key?('amendedK1') ? hash['amendedK1'] : SKIP fiscal_year_begin = hash.key?('fiscalYearBegin') ? hash['fiscalYearBegin'] : SKIP fiscal_year_end = hash.key?('fiscalYearEnd') ? hash['fiscalYearEnd'] : SKIP fiduciary = TaxParty2.from_hash(hash['fiduciary']) if hash['fiduciary'] form1041_t = hash.key?('form1041T') ? hash['form1041T'] : SKIP date1041_t = hash.key?('date1041T') ? hash['date1041T'] : SKIP final1041 = hash.key?('final1041') ? hash['final1041'] : SKIP domestic = hash.key?('domestic') ? hash['domestic'] : SKIP foreign = hash.key?('foreign') ? hash['foreign'] : SKIP interest_income = hash.key?('interestIncome') ? hash['interestIncome'] : SKIP ordinary_dividends = hash.key?('ordinaryDividends') ? hash['ordinaryDividends'] : SKIP qualified_dividends = hash.key?('qualifiedDividends') ? hash['qualifiedDividends'] : SKIP net_short_term_gain = hash.key?('netShortTermGain') ? hash['netShortTermGain'] : SKIP net_long_term_gain = hash.key?('netLongTermGain') ? hash['netLongTermGain'] : SKIP gain28_rate = hash.key?('gain28Rate') ? hash['gain28Rate'] : SKIP unrecaptured1250_gain = hash.key?('unrecaptured1250Gain') ? hash['unrecaptured1250Gain'] : SKIP other_portfolio_income = hash.key?('otherPortfolioIncome') ? hash['otherPortfolioIncome'] : SKIP ordinary_business_income = hash.key?('ordinaryBusinessIncome') ? hash['ordinaryBusinessIncome'] : SKIP net_rental_real_estate_income = hash.key?('netRentalRealEstateIncome') ? hash['netRentalRealEstateIncome'] : SKIP other_rental_income = hash.key?('otherRentalIncome') ? hash['otherRentalIncome'] : SKIP # Parameter is an array, so we need to iterate through it directly_apportioned_deductions = nil unless hash['directlyApportionedDeductions'].nil? directly_apportioned_deductions = [] hash['directlyApportionedDeductions'].each do |structure| directly_apportioned_deductions << (CodeAndAmount.from_hash(structure) if structure) end end directly_apportioned_deductions = SKIP unless hash.key?('directlyApportionedDeductions') estate_tax_deduction = hash.key?('estateTaxDeduction') ? hash['estateTaxDeduction'] : SKIP # Parameter is an array, so we need to iterate through it final_year_deductions = nil unless hash['finalYearDeductions'].nil? final_year_deductions = [] hash['finalYearDeductions'].each do |structure| final_year_deductions << (CodeAndAmount.from_hash(structure) if structure) end end final_year_deductions = SKIP unless hash.key?('finalYearDeductions') # Parameter is an array, so we need to iterate through it amt_adjustments = nil unless hash['amtAdjustments'].nil? amt_adjustments = [] hash['amtAdjustments'].each do |structure| amt_adjustments << (CodeAndAmount.from_hash(structure) if structure) end end amt_adjustments = SKIP unless hash.key?('amtAdjustments') # Parameter is an array, so we need to iterate through it credits = nil unless hash['credits'].nil? credits = [] hash['credits'].each do |structure| credits << (CodeAndAmount.from_hash(structure) if structure) end end credits = SKIP unless hash.key?('credits') # Parameter is an array, so we need to iterate through it other_info = nil unless hash['otherInfo'].nil? other_info = [] hash['otherInfo'].each do |structure| other_info << (CodeAndAmount.from_hash(structure) if structure) end end other_info = SKIP unless hash.key?('otherInfo') # Create a new hash for additional properties, removing known properties. new_hash = hash.reject { |k, _| names.value?(k) } additional_properties = APIHelper.get_additional_properties( new_hash, proc { |value| value } ) # Create object from extracted values. Form1041ScheduleK11.new(tax_year: tax_year, corrected: corrected, account_id: account_id, tax_form_id: tax_form_id, tax_form_date: tax_form_date, additional_information: additional_information, tax_form_type: tax_form_type, issuer: issuer, recipient: recipient, attributes: attributes, error: error, links: links, final_k1: final_k1, amended_k1: amended_k1, fiscal_year_begin: fiscal_year_begin, fiscal_year_end: fiscal_year_end, fiduciary: fiduciary, form1041_t: form1041_t, date1041_t: date1041_t, final1041: final1041, domestic: domestic, foreign: foreign, interest_income: interest_income, ordinary_dividends: ordinary_dividends, qualified_dividends: qualified_dividends, net_short_term_gain: net_short_term_gain, net_long_term_gain: net_long_term_gain, gain28_rate: gain28_rate, unrecaptured1250_gain: unrecaptured1250_gain, other_portfolio_income: other_portfolio_income, ordinary_business_income: ordinary_business_income, net_rental_real_estate_income: net_rental_real_estate_income, other_rental_income: other_rental_income, directly_apportioned_deductions: directly_apportioned_deductions, estate_tax_deduction: estate_tax_deduction, final_year_deductions: final_year_deductions, amt_adjustments: amt_adjustments, credits: credits, other_info: other_info, additional_properties: additional_properties) end |
.names ⇒ Object
A mapping from model property names to API property names.
182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 182 def self.names @_hash = {} if @_hash.nil? @_hash['tax_year'] = 'taxYear' @_hash['corrected'] = 'corrected' @_hash['account_id'] = 'accountId' @_hash['tax_form_id'] = 'taxFormId' @_hash['tax_form_date'] = 'taxFormDate' @_hash['additional_information'] = 'additionalInformation' @_hash['tax_form_type'] = 'taxFormType' @_hash['issuer'] = 'issuer' @_hash['recipient'] = 'recipient' @_hash['attributes'] = 'attributes' @_hash['error'] = 'error' @_hash['links'] = 'links' @_hash['final_k1'] = 'finalK1' @_hash['amended_k1'] = 'amendedK1' @_hash['fiscal_year_begin'] = 'fiscalYearBegin' @_hash['fiscal_year_end'] = 'fiscalYearEnd' @_hash['fiduciary'] = 'fiduciary' @_hash['form1041_t'] = 'form1041T' @_hash['date1041_t'] = 'date1041T' @_hash['final1041'] = 'final1041' @_hash['domestic'] = 'domestic' @_hash['foreign'] = 'foreign' @_hash['interest_income'] = 'interestIncome' @_hash['ordinary_dividends'] = 'ordinaryDividends' @_hash['qualified_dividends'] = 'qualifiedDividends' @_hash['net_short_term_gain'] = 'netShortTermGain' @_hash['net_long_term_gain'] = 'netLongTermGain' @_hash['gain28_rate'] = 'gain28Rate' @_hash['unrecaptured1250_gain'] = 'unrecaptured1250Gain' @_hash['other_portfolio_income'] = 'otherPortfolioIncome' @_hash['ordinary_business_income'] = 'ordinaryBusinessIncome' @_hash['net_rental_real_estate_income'] = 'netRentalRealEstateIncome' @_hash['other_rental_income'] = 'otherRentalIncome' @_hash['directly_apportioned_deductions'] = 'directlyApportionedDeductions' @_hash['estate_tax_deduction'] = 'estateTaxDeduction' @_hash['final_year_deductions'] = 'finalYearDeductions' @_hash['amt_adjustments'] = 'amtAdjustments' @_hash['credits'] = 'credits' @_hash['other_info'] = 'otherInfo' @_hash end |
.nullables ⇒ Object
An array for nullable fields
273 274 275 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 273 def self.nullables [] end |
.optionals ⇒ Object
An array for optional fields
228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 228 def self.optionals %w[ tax_year corrected account_id tax_form_id tax_form_date additional_information tax_form_type issuer recipient attributes error links final_k1 amended_k1 fiscal_year_begin fiscal_year_end fiduciary form1041_t date1041_t final1041 domestic foreign interest_income ordinary_dividends qualified_dividends net_short_term_gain net_long_term_gain gain28_rate unrecaptured1250_gain other_portfolio_income ordinary_business_income net_rental_real_estate_income other_rental_income directly_apportioned_deductions estate_tax_deduction final_year_deductions amt_adjustments credits other_info ] end |
Instance Method Details
#inspect ⇒ Object
Provides a debugging-friendly string with detailed object information.
543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 543 def inspect class_name = self.class.name.split('::').last "<#{class_name} tax_year: #{@tax_year.inspect}, corrected: #{@corrected.inspect},"\ " account_id: #{@account_id.inspect}, tax_form_id: #{@tax_form_id.inspect}, tax_form_date:"\ " #{@tax_form_date.inspect}, additional_information: #{@additional_information.inspect},"\ " tax_form_type: #{@tax_form_type.inspect}, issuer: #{@issuer.inspect}, recipient:"\ " #{@recipient.inspect}, attributes: #{@attributes.inspect}, error: #{@error.inspect},"\ " links: #{@links.inspect}, final_k1: #{@final_k1.inspect}, amended_k1:"\ " #{@amended_k1.inspect}, fiscal_year_begin: #{@fiscal_year_begin.inspect}, fiscal_year_end:"\ " #{@fiscal_year_end.inspect}, fiduciary: #{@fiduciary.inspect}, form1041_t:"\ " #{@form1041_t.inspect}, date1041_t: #{@date1041_t.inspect}, final1041:"\ " #{@final1041.inspect}, domestic: #{@domestic.inspect}, foreign: #{@foreign.inspect},"\ " interest_income: #{@interest_income.inspect}, ordinary_dividends:"\ " #{@ordinary_dividends.inspect}, qualified_dividends: #{@qualified_dividends.inspect},"\ " net_short_term_gain: #{@net_short_term_gain.inspect}, net_long_term_gain:"\ " #{@net_long_term_gain.inspect}, gain28_rate: #{@gain28_rate.inspect},"\ " unrecaptured1250_gain: #{@unrecaptured1250_gain.inspect}, other_portfolio_income:"\ " #{@other_portfolio_income.inspect}, ordinary_business_income:"\ " #{@ordinary_business_income.inspect}, net_rental_real_estate_income:"\ " #{@net_rental_real_estate_income.inspect}, other_rental_income:"\ " #{@other_rental_income.inspect}, directly_apportioned_deductions:"\ " #{@directly_apportioned_deductions.inspect}, estate_tax_deduction:"\ " #{@estate_tax_deduction.inspect}, final_year_deductions:"\ " #{@final_year_deductions.inspect}, amt_adjustments: #{@amt_adjustments.inspect}, credits:"\ " #{@credits.inspect}, other_info: #{@other_info.inspect}, additional_properties:"\ " #{@additional_properties}>" end |
#to_s ⇒ Object
Provides a human-readable string representation of the object.
520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 |
# File 'lib/fdx_v660_api/models/form1041_schedule_k11.rb', line 520 def to_s class_name = self.class.name.split('::').last "<#{class_name} tax_year: #{@tax_year}, corrected: #{@corrected}, account_id:"\ " #{@account_id}, tax_form_id: #{@tax_form_id}, tax_form_date: #{@tax_form_date},"\ " additional_information: #{@additional_information}, tax_form_type: #{@tax_form_type},"\ " issuer: #{@issuer}, recipient: #{@recipient}, attributes: #{@attributes}, error:"\ " #{@error}, links: #{@links}, final_k1: #{@final_k1}, amended_k1: #{@amended_k1},"\ " fiscal_year_begin: #{@fiscal_year_begin}, fiscal_year_end: #{@fiscal_year_end}, fiduciary:"\ " #{@fiduciary}, form1041_t: #{@form1041_t}, date1041_t: #{@date1041_t}, final1041:"\ " #{@final1041}, domestic: #{@domestic}, foreign: #{@foreign}, interest_income:"\ " #{@interest_income}, ordinary_dividends: #{@ordinary_dividends}, qualified_dividends:"\ " #{@qualified_dividends}, net_short_term_gain: #{@net_short_term_gain}, net_long_term_gain:"\ " #{@net_long_term_gain}, gain28_rate: #{@gain28_rate}, unrecaptured1250_gain:"\ " #{@unrecaptured1250_gain}, other_portfolio_income: #{@other_portfolio_income},"\ " ordinary_business_income: #{@ordinary_business_income}, net_rental_real_estate_income:"\ " #{@net_rental_real_estate_income}, other_rental_income: #{@other_rental_income},"\ " directly_apportioned_deductions: #{@directly_apportioned_deductions},"\ " estate_tax_deduction: #{@estate_tax_deduction}, final_year_deductions:"\ " #{@final_year_deductions}, amt_adjustments: #{@amt_adjustments}, credits: #{@credits},"\ " other_info: #{@other_info}, additional_properties: #{@additional_properties}>" end |