case class Price[A <: Quantity[A]](money: squants.Money, quantity: A) extends Ratio[squants.Money, A] with Serializable with Product
Represents a price
A price is an squants.Ratio between a quantity of squants.market.Money and some other squants.Quantity
- A
Quantity Type
- money
Money
- quantity
Quantity
- Source
- Price.scala
- Since
0.1
- Alphabetic
- By Inheritance
- Price
- Product
- Equals
- Serializable
- Ratio
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Instance Constructors
- new Price(money: squants.Money, quantity: A)
- money
Money
- quantity
Quantity
Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- def *(that: A): squants.Money
Returns the Cost (Money) for a quantity
that
of AReturns the Cost (Money) for a quantity
that
of A- that
Quantity
- def *(that: BigDecimal): Price[A]
- def *(that: Double): Price[A]
- def +(that: Price[A]): Price[A]
- def -(that: Price[A]): Price[A]
- def /(that: Price[A]): BigDecimal
- def /(that: BigDecimal): Price[A]
- def /(that: Double): Price[A]
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def base: squants.Money
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- def convertToBase(q: A): squants.Money
- Definition Classes
- Ratio
- def convertToCounter(q: squants.Money): A
- Definition Classes
- Ratio
- def counter: A
- def divide(that: Price[A]): BigDecimal
- def divide(that: BigDecimal): Price[A]
- def divide(that: Double): Price[A]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.Throwable])
- final def getClass(): Class[_ <: AnyRef]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- def in(currency: Currency)(implicit moneyContext: MoneyContext): squants.Price[A]
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- def minus(that: Price[A]): Price[A]
- val money: squants.Money
- final def ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- final def notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- final def notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
- def plus(that: Price[A]): Price[A]
- def productElementNames: Iterator[String]
- Definition Classes
- Product
- val quantity: A
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def times(that: BigDecimal): Price[A]
- def times(that: Double): Price[A]
- def toString(currency: Currency, unit: UnitOfMeasure[A])(implicit moneyContext: MoneyContext): String
- def toString(unit: UnitOfMeasure[A]): String
- def toString(): String
- Definition Classes
- Price → AnyRef → Any
- final def wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException])
- final def wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.InterruptedException]) @native()
Deprecated Value Members
- def *(that: squants.Money): A
Returns the Quantity that will cost that)
Returns the Quantity that will cost that)
- that
Money
- Annotations
- @deprecated
- Deprecated
(Since version 0.6.3) Use
money / price
instead