trait Dimension[A <: Quantity[A]] extends AnyRef
Represents a Dimension or Quantity Type
This trait should be mixed into the Companion Objects of specific Quantity Types.
- A
Quantity Type
- Source
- Dimension.scala
- Alphabetic
- By Inheritance
- Dimension
- AnyRef
- Any
- Hide All
- Show All
- Public
- Protected
Abstract Value Members
- abstract def name: String
The name
- abstract def primaryUnit: UnitOfMeasure[A] with PrimaryUnit
The unit with a conversions factor of 1.
The unit with a conversions factor of 1. The conversionFactor for other units should be set relative to this unit.
- abstract def siUnit: UnitOfMeasure[A] with SiUnit
The International System of Units (SI) Base Unit
- abstract def units: Set[UnitOfMeasure[A]]
Set of available units
Concrete Value Members
- final def !=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def ##(): Int
- Definition Classes
- AnyRef → Any
- final def ==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- final def asInstanceOf[T0]: T0
- Definition Classes
- Any
- def clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws(classOf[java.lang.CloneNotSupportedException]) @native()
- implicit val dimensionImplicit: Dimension[A]
- final def eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def equals(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef → Any
- 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 hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
- final def isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- 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 parse(value: Any): Try[A]
Tries to map a string or tuple value to Quantity of this Dimension
Tries to map a string or tuple value to Quantity of this Dimension
- value
the source string (ie, "10 kW") or tuple (ie, (10, "kW"))
- returns
Try[A]
- Attributes
- protected
- def parseString(s: String): Try[A]
- def parseTuple[N](t: (N, String))(implicit num: Numeric[N]): Try[A]
- def symbolToUnit(symbol: String): Option[UnitOfMeasure[A]]
Maps a string representation of a unit symbol into the matching UnitOfMeasure object
Maps a string representation of a unit symbol into the matching UnitOfMeasure object
- symbol
String
- final def synchronized[T0](arg0: => T0): T0
- Definition Classes
- AnyRef
- def toString(): String
- Definition Classes
- 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()