Class: Nacha::Record::FileControl
- Includes:
- FileControlRecordType
- Defined in:
- lib/nacha/record/file_control.rb
Instance Attribute Summary collapse
-
#batch_count ⇒ Nacha::Numeric
The total number of batches in the file.
-
#block_count ⇒ Nacha::Numeric
The total number of physical blocks in the file.
-
#entry_addenda_count ⇒ Nacha::Numeric
The total number of entry detail and addenda records in the file.
-
#entry_hash ⇒ Nacha::Numeric
A sum of the entry hash totals from all the batch control records in the file.
-
#record_type_code ⇒ String
Identifies the record as a File Control record with a constant value of ‘9’.
-
#reserved ⇒ String
A reserved field for future use.
-
#total_credit_entry_dollar_amount_in_file ⇒ Nacha::Numeric
The total dollar amount of all credit entries in the file.
-
#total_debit_entry_dollar_amount_in_file ⇒ Nacha::Numeric
The total dollar amount of all debit entries in the file.
Attributes inherited from Base
#children, #fields, #line_number, #name, #original_input_line, #parent, #validations
Method Summary
Methods included from FileControlRecordType
Methods inherited from Base
#add_error, #create_fields_from_definition, #credit?, #debit?, definition, #definition, #errors, #human_name, #initialize, #inspect, matcher, #method_missing, nacha_field, parse, #record_type, record_type, #respond_to_missing?, #to_ach, #to_h, to_h, #to_html, to_json, #to_json, unpack_str, #valid?, #validate, validations
Methods included from Validations::FieldValidations
Constructor Details
This class inherits a constructor from Nacha::Record::Base
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Nacha::Record::Base
Instance Attribute Details
#batch_count ⇒ Nacha::Numeric
Returns The total number of batches in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#block_count ⇒ Nacha::Numeric
Returns The total number of physical blocks in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#entry_addenda_count ⇒ Nacha::Numeric
Returns The total number of entry detail and addenda records in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#entry_hash ⇒ Nacha::Numeric
Returns A sum of the entry hash totals from all the batch control records in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#record_type_code ⇒ String
Returns Identifies the record as a File Control record with a constant value of ‘9’.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#reserved ⇒ String
Returns A reserved field for future use.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#total_credit_entry_dollar_amount_in_file ⇒ Nacha::Numeric
Returns The total dollar amount of all credit entries in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |
#total_debit_entry_dollar_amount_in_file ⇒ Nacha::Numeric
Returns The total dollar amount of all debit entries in the file.
25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
# File 'lib/nacha/record/file_control.rb', line 25 class FileControl < Nacha::Record::Base include FileControlRecordType nacha_field :record_type_code, inclusion: 'M', contents: 'C9', position: 1..1 nacha_field :batch_count, inclusion: 'M', contents: 'Numeric', position: 2..7 nacha_field :block_count, inclusion: 'M', contents: 'Numeric', position: 8..13 nacha_field :entry_addenda_count, inclusion: 'M', contents: 'Numeric', position: 14..21 nacha_field :entry_hash, inclusion: 'M', contents: 'Numeric', position: 22..31 nacha_field :total_debit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 32..43 nacha_field :total_credit_entry_dollar_amount_in_file, inclusion: 'M', contents: '$$$$$$$$$$¢¢', position: 44..55 nacha_field :reserved, inclusion: 'M', contents: 'C ', position: 56..94 end |