Class: Nfe::Purchase
- Inherits:
-
Object
- Object
- Nfe::Purchase
- Defined in:
- lib/nfe_reader/purchase.rb
Instance Attribute Summary collapse
-
#contract ⇒ Object
readonly
Returns the value of attribute contract.
-
#demand ⇒ Object
readonly
Returns the value of attribute demand.
-
#number ⇒ Object
readonly
Returns the value of attribute number.
Instance Method Summary collapse
-
#initialize(attrs = {}) ⇒ Purchase
constructor
A new instance of Purchase.
Constructor Details
#initialize(attrs = {}) ⇒ Purchase
Returns a new instance of Purchase.
8 9 10 11 12 |
# File 'lib/nfe_reader/purchase.rb', line 8 def initialize(attrs = {}) @number = attrs[:xNEmp] @demand = attrs[:xPed] @contract = attrs[:xCont] end |
Instance Attribute Details
#contract ⇒ Object (readonly)
Returns the value of attribute contract.
6 7 8 |
# File 'lib/nfe_reader/purchase.rb', line 6 def contract @contract end |
#demand ⇒ Object (readonly)
Returns the value of attribute demand.
6 7 8 |
# File 'lib/nfe_reader/purchase.rb', line 6 def demand @demand end |
#number ⇒ Object (readonly)
Returns the value of attribute number.
6 7 8 |
# File 'lib/nfe_reader/purchase.rb', line 6 def number @number end |