io.github.karols.units

defining

package defining

Package containing helper types and methods for defining new units and ratios between units.

It also contains a set of type-level characters, used for defining type-level unit identifiers.

Usage:

import io.github.karols.units.defining._

Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. defining
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Learn more about member selection
Visibility
  1. Public
  2. All

Type Members

  1. type DefineAffineSpace[Z, U <: MUnit] = internal.AffineSpaces.DefineAffineSpace[Z, U]

    Defines a 1-dimensional affine space using given unit and starting at given zero point.

  2. type DefineUnit[S <: TString] = ^[ASingleUnit[S], P1]

    Defines a unit of measure identified by given type-level string.

  3. class DoubleAScalingTranslation[A <: AffineSpace, B <: AffineSpace] extends ReversibleDoubleAConversion[A, B]

    A two-way conversion between affine spaces with different underlying units.

  4. class DoubleATranslation[A <: AffineSpace, B <: AffineSpace] extends ReversibleDoubleAConversion[A, B]

    A two-way conversion between affine spaces with the same underlying units.

  5. class DoubleATranslationScaling[A <: AffineSpace, B <: AffineSpace] extends ReversibleDoubleAConversion[A, B]

    A two-way conversion between affine spaces with different underlying units.

  6. class DoubleATwoValues[A <: AffineSpace, B <: AffineSpace] extends ReversibleDoubleAConversion[A, B]

    A two-way linears conversion between affine spaces.

  7. class IntATranslation[A <: AffineSpace, B <: AffineSpace] extends ReversibleDoubleAConversion[A, B] with ReversibleIntAConversion[A, B]

    A two-way conversion between affine spaces with the same underlying units.

  8. sealed trait ReversibleDoubleAConversion[A <: AffineSpace, B <: AffineSpace] extends AnyRef

  9. sealed trait ReversibleIntAConversion[A <: AffineSpace, B <: AffineSpace] extends AnyRef

  10. type _A = AChar[TZ5_0, TZ5_0, TZ5_1]

  11. type _AA = AChar[TZ5_2, TZ5_0, TZ5_4]

    angström sign (Å)

  12. type _B = AChar[TZ5_0, TZ5_0, TZ5_2]

  13. type _C = AChar[TZ5_0, TZ5_0, TZ5_3]

  14. type _D = AChar[TZ5_0, TZ5_0, TZ5_4]

  15. type _DOLLAR = AChar[TZ5_2, TZ5_2, TZ5_2]

    dollar sign ($)

  16. type _DONG = AChar[TZ5_2, TZ5_3, TZ5_3]

    dong sign (₫)

  17. type _E = AChar[TZ5_0, TZ5_1, TZ5_0]

  18. type _EURO = AChar[TZ5_2, TZ5_2, TZ5_3]

    euro sign (€)

  19. type _F = AChar[TZ5_0, TZ5_1, TZ5_1]

  20. type _G = AChar[TZ5_0, TZ5_1, TZ5_2]

  21. type _H = AChar[TZ5_0, TZ5_1, TZ5_3]

  22. type _I = AChar[TZ5_0, TZ5_1, TZ5_4]

  23. type _J = AChar[TZ5_0, TZ5_2, TZ5_0]

  24. type _K = AChar[TZ5_0, TZ5_2, TZ5_1]

  25. type _L = AChar[TZ5_0, TZ5_2, TZ5_2]

  26. type _M = AChar[TZ5_0, TZ5_2, TZ5_3]

  27. type _N = AChar[TZ5_0, TZ5_2, TZ5_4]

  28. type _O = AChar[TZ5_0, TZ5_3, TZ5_0]

  29. type _OMEGA = AChar[TZ5_2, TZ5_1, TZ5_1]

    ohm sign (Ω)

  30. type _P = AChar[TZ5_0, TZ5_3, TZ5_1]

  31. type _POUND = AChar[TZ5_2, TZ5_2, TZ5_0]

    pound sign (£)

  32. type _Q = AChar[TZ5_0, TZ5_3, TZ5_2]

  33. type _R = AChar[TZ5_0, TZ5_3, TZ5_3]

  34. type _RUPEE = AChar[TZ5_2, TZ5_3, TZ5_4]

    rupee sign (₨)

  35. type _S = AChar[TZ5_0, TZ5_3, TZ5_4]

  36. type _T = AChar[TZ5_0, TZ5_4, TZ5_0]

  37. type _U = AChar[TZ5_0, TZ5_4, TZ5_1]

  38. type _V = AChar[TZ5_0, TZ5_4, TZ5_2]

  39. type _W = AChar[TZ5_0, TZ5_4, TZ5_3]

  40. type _X = AChar[TZ5_0, TZ5_4, TZ5_4]

  41. type _Y = AChar[TZ5_1, TZ5_0, TZ5_0]

  42. type _YEN = AChar[TZ5_2, TZ5_2, TZ5_1]

    yen sign (¥)

  43. type _Z = AChar[TZ5_1, TZ5_0, TZ5_1]

  44. type _a = AChar[TZ5_1, TZ5_0, TZ5_3]

  45. type _at = AChar[TZ5_0, TZ5_0, TZ5_0]

    commercial at sign (@)

  46. type _b = AChar[TZ5_1, TZ5_0, TZ5_4]

  47. type _bis = AChar[TZ5_2, TZ5_3, TZ5_2]

    a synonym for angular second sign _sec (ʺ)

  48. type _c = AChar[TZ5_1, TZ5_1, TZ5_0]

  49. type _d = AChar[TZ5_1, TZ5_1, TZ5_1]

  50. type _deg = AChar[TZ5_2, TZ5_3, TZ5_0]

    degree sign (°)

  51. type _digit_1 = AChar[TZ5_3, TZ5_3, TZ5_1]

    digit 1 (₅)

  52. type _dot = AChar[TZ5_2, TZ5_4, TZ5_2]

    center dot (·)

  53. type _e = AChar[TZ5_1, TZ5_1, TZ5_2]

  54. type _e_acute = AChar[TZ5_2, TZ5_1, TZ5_4]

    e with acute accent (é)

  55. type _epsilon = AChar[TZ5_2, TZ5_1, TZ5_2]

    epsilon (ε)

  56. type _f = AChar[TZ5_1, TZ5_1, TZ5_3]

  57. type _foot = AChar[TZ5_2, TZ5_3, TZ5_1]

    a synonym for angular minute sign _min (ʹ)

  58. type _g = AChar[TZ5_1, TZ5_1, TZ5_4]

  59. type _h = AChar[TZ5_1, TZ5_2, TZ5_0]

  60. type _i = AChar[TZ5_1, TZ5_2, TZ5_1]

  61. type _inch = AChar[TZ5_2, TZ5_3, TZ5_2]

    a synonym for angular second sign _sec (ʺ)

  62. type _j = AChar[TZ5_1, TZ5_2, TZ5_2]

  63. type _k = AChar[TZ5_1, TZ5_2, TZ5_3]

  64. type _l = AChar[TZ5_1, TZ5_2, TZ5_4]

  65. type _l_ = AChar[TZ5_2, TZ5_2, TZ5_4]

    lowercase L with stroke (ł)

  66. type _left_paren = AChar[TZ5_3, TZ5_1, TZ5_3]

    left parenthesis

  67. type _m = AChar[TZ5_1, TZ5_3, TZ5_0]

  68. type _min = AChar[TZ5_2, TZ5_3, TZ5_1]

    angular minute sign (ʹ)

  69. type _mu = AChar[TZ5_2, TZ5_1, TZ5_0]

    micro sign (µ)

  70. type _n = AChar[TZ5_1, TZ5_3, TZ5_1]

  71. type _o = AChar[TZ5_1, TZ5_3, TZ5_2]

  72. type _p = AChar[TZ5_1, TZ5_3, TZ5_3]

  73. type _percent = AChar[TZ5_2, TZ5_4, TZ5_0]

    percent sign (%)

  74. type _period = AChar[TZ5_2, TZ5_4, TZ5_3]

    full stop / period (.

    full stop / period (.)

  75. type _permille = AChar[TZ5_2, TZ5_4, TZ5_1]

    permille sign (‰)

  76. type _prime = AChar[TZ5_2, TZ5_3, TZ5_1]

    a synonym for angular minute sign _min (ʹ)

  77. type _q = AChar[TZ5_1, TZ5_3, TZ5_4]

  78. type _r = AChar[TZ5_1, TZ5_4, TZ5_0]

  79. type _right_paren = AChar[TZ5_3, TZ5_1, TZ5_4]

    right parenthesis

  80. type _s = AChar[TZ5_1, TZ5_4, TZ5_1]

  81. type _sec = AChar[TZ5_2, TZ5_3, TZ5_2]

    angular second sign (ʺ)

  82. type _space = AChar[TZ5_2, TZ5_4, TZ5_4]

    space

  83. type _sub_0 = AChar[TZ5_3, TZ5_0, TZ5_0]

    subscript zero (₀₅)

  84. type _sub_2 = AChar[TZ5_3, TZ5_0, TZ5_1]

    subscript two (₂)

  85. type _sub_3 = AChar[TZ5_3, TZ5_0, TZ5_2]

    subscript three (₃)

  86. type _sub_4 = AChar[TZ5_3, TZ5_0, TZ5_3]

    subscript four (₄)

  87. type _sub_5 = AChar[TZ5_3, TZ5_0, TZ5_4]

    subscript five (₅)

  88. type _sub_e = AChar[TZ5_3, TZ5_2, TZ5_0]

    subscript e (₅)

  89. type _sub_h = AChar[TZ5_3, TZ5_2, TZ5_1]

    subscript h (₅)

  90. type _sub_m = AChar[TZ5_3, TZ5_1, TZ5_0]

    subscript m (₅)

  91. type _sub_n = AChar[TZ5_3, TZ5_1, TZ5_1]

    subscript n (₅)

  92. type _sub_p = AChar[TZ5_3, TZ5_2, TZ5_2]

    subscript p (₅)

  93. type _sub_s = AChar[TZ5_3, TZ5_2, TZ5_3]

    subscript s (₅)

  94. type _sub_t = AChar[TZ5_3, TZ5_2, TZ5_4]

    subscript t (₅)

  95. type _t = AChar[TZ5_1, TZ5_4, TZ5_2]

  96. type _u = AChar[TZ5_1, TZ5_4, TZ5_3]

  97. type _v = AChar[TZ5_1, TZ5_4, TZ5_4]

  98. type _w = AChar[TZ5_2, TZ5_0, TZ5_0]

  99. type _x = AChar[TZ5_2, TZ5_0, TZ5_1]

  100. type _y = AChar[TZ5_2, TZ5_0, TZ5_2]

  101. type _z = AChar[TZ5_2, TZ5_0, TZ5_3]

  102. type ~:[H <: TChar, T <: TString] = internal.Strings.~:[H, T]

    String constructor.

    String constructor. Separate type-level characters with ~: to create a type-level string.

Value Members

  1. def alias[F <: MUnit, T <: MUnit]: UnitAlias[F, T]

    Annotations
    @inline()
  2. def convertAffineSpace[T1 <: AffineSpace, T2 <: AffineSpace](f: (Double) ⇒ Double): internal.ratios.DoubleAffineSpaceConverter[T1, T2]

    Creates a one-way affine space converter.

    Creates a one-way affine space converter. You should store it in an implicit val.

    Annotations
    @inline()
  3. def convertIntAffineSpace[T1 <: AffineSpace, T2 <: AffineSpace](f: (Long) ⇒ Long): internal.ratios.IntAffineSpaceConverter[T1, T2]

    Creates a one-way integer affine space converter.

    Creates a one-way integer affine space converter. You should store it in an implicit val.

    Annotations
    @inline()
  4. def matchingAffineSpacePoint[A <: AffineSpace, B <: AffineSpace](xA: DoubleA[A], xB: DoubleA[B])(implicit ev: =:=[defining.matchingAffineSpacePoint.A.Unit, defining.matchingAffineSpacePoint.B.Unit]): DoubleATranslation[A, B]

    Creates a two-way affine space converter, based on one points defined in two affine spaces.

    Creates a two-way affine space converter, based on one points defined in two affine spaces. The affine spaces should have the same base unit. This defines a translation – a conversion that simply shifts values by a constant displacement. You should store it in an implicit val.

    Annotations
    @inline()
  5. def matchingAffineSpacePoints[A <: AffineSpace, B <: AffineSpace](xA: DoubleA[A], xB: DoubleA[B], yA: DoubleA[A], yB: DoubleA[B]): DoubleATwoValues[A, B]

    Creates a two-way affine space converter, based on two points x and y defined in two affine spaces.

    Creates a two-way affine space converter, based on two points x and y defined in two affine spaces. You should store it in an implicit val.

    Annotations
    @inline()
  6. def one[U <: MUnit]: OneBuilder[U]

    Helper for defining unit ratios.

    Helper for defining unit ratios. Syntax: one[kilometre].contains(1000)[metre]

    Annotations
    @inline()
  7. def product[F1 <: MUnit, F2 <: MUnit, T1 <: MUnit, T2 <: MUnit](implicit r1: internal.ratios.DoubleRatio[F1, T2], r2: internal.ratios.DoubleRatio[F2, T2]): BaseDoubleRatio[defining.product.F1.Mul[F2], defining.product.T1.Mul[T2]]

    Annotations
    @inline()
  8. def productInt[F1 <: MUnit, F2 <: MUnit, T1 <: MUnit, T2 <: MUnit](implicit r1: BaseIntRatio[F1, T2], r2: BaseIntRatio[F2, T2]): BaseIntRatio[defining.productInt.F1.Mul[F2], defining.productInt.T2.Mul[T2]]

    Annotations
    @inline()

Inherited from AnyRef

Inherited from Any

Ungrouped