Class: Rocket::Invoice::InvoiceProduct
- Inherits:
-
Object
- Object
- Rocket::Invoice::InvoiceProduct
- Defined in:
- lib/rocket/invoice/invoice_product.rb
Instance Attribute Summary collapse
-
#description ⇒ Object
Returns the value of attribute description.
-
#name ⇒ Object
Returns the value of attribute name.
-
#quantity ⇒ Object
Returns the value of attribute quantity.
-
#unity_price ⇒ Object
Returns the value of attribute unity_price.
Instance Method Summary collapse
-
#initialize ⇒ InvoiceProduct
constructor
A new instance of InvoiceProduct.
Constructor Details
#initialize ⇒ InvoiceProduct
Returns a new instance of InvoiceProduct.
6 7 8 9 10 11 |
# File 'lib/rocket/invoice/invoice_product.rb', line 6 def initialize self.name = '' self.description = '' self.unity_price = BigDecimal.new('0.0') self.quantity = BigDecimal.new('0.0') end |
Instance Attribute Details
#description ⇒ Object
Returns the value of attribute description.
4 5 6 |
# File 'lib/rocket/invoice/invoice_product.rb', line 4 def description @description end |
#name ⇒ Object
Returns the value of attribute name.
4 5 6 |
# File 'lib/rocket/invoice/invoice_product.rb', line 4 def name @name end |
#quantity ⇒ Object
Returns the value of attribute quantity.
4 5 6 |
# File 'lib/rocket/invoice/invoice_product.rb', line 4 def quantity @quantity end |
#unity_price ⇒ Object
Returns the value of attribute unity_price.
4 5 6 |
# File 'lib/rocket/invoice/invoice_product.rb', line 4 def unity_price @unity_price end |