io.github.karols

units

package units

Main package of the library.

Importing io.github.karols.units._ brings into scope most of its features.

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

Type Members

  1. type /[U <: MUnit, V <: MUnit] = units./.U.Mul[units./.V.Invert]

    Unit division.

  2. type ><[U <: MUnit, V <: MUnit] = units.><.U.Mul[V]

    Unit multiplication.

  3. type @@[N, U <: MUnit] = WithU[N, U]

  4. trait AffineSpace extends AnyRef

    Supertype of all affine spaces.

  5. final case class DoubleA[A <: AffineSpace](value: Double) extends AnyVal with Product with Serializable

    Double-precision floating-point value representing a point in a 1-dimensional affine space.

  6. type DoubleAffineSpaceConverter[T1 <: AffineSpace, T2 <: AffineSpace] = units.internal.ratios.DoubleAffineSpaceConverter[T1, T2]

  7. type DoubleRatio[U <: MUnit, V <: MUnit] = units.internal.ratios.DoubleRatio[U, V]

  8. final case class DoubleU[U <: MUnit](value: Double) extends AnyVal with Product with Serializable

    Double-precision floating-point value representing a value with a unit of measure.

  9. implicit final class DoubleUBuilder extends AnyVal

    Extention methods for Double.

  10. final case class IntA[A <: AffineSpace](value: Long) extends AnyVal with Product with Serializable

    64-bit signed integer representing a point in a 1-dimensional affine space.

  11. type IntAffineSpaceConverter[T1 <: AffineSpace, T2 <: AffineSpace] = units.internal.ratios.IntAffineSpaceConverter[T1, T2]

  12. type IntRatio[U <: MUnit, V <: MUnit] = units.internal.ratios.IntRatio[U, V]

  13. final case class IntU[U <: MUnit](value: Long) extends AnyVal with Product with Serializable

    64-bit signed integer representing a value with a unit of measure.

  14. implicit final class IntUBuilder extends AnyVal

    Extention methods for Long.

  15. trait MUnit extends AnyRef

    Supertype of all units of measure.

  16. final class System1[U1 <: TSingleUnit, V1 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 1 unit.

  17. final class System2[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 2 units.

  18. final class System3[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 3 units.

  19. final class System4[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit, U4 <: TSingleUnit, V4 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 4 units.

  20. final class System5[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit, U4 <: TSingleUnit, V4 <: MUnit, U5 <: TSingleUnit, V5 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 5 units.

  21. final class System6[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit, U4 <: TSingleUnit, V4 <: MUnit, U5 <: TSingleUnit, V5 <: MUnit, U6 <: TSingleUnit, V6 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 6 units.

  22. final class System7[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit, U4 <: TSingleUnit, V4 <: MUnit, U5 <: TSingleUnit, V5 <: MUnit, U6 <: TSingleUnit, V6 <: MUnit, U7 <: TSingleUnit, V7 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 7 units.

  23. final class System8[U1 <: TSingleUnit, V1 <: MUnit, U2 <: TSingleUnit, V2 <: MUnit, U3 <: TSingleUnit, V3 <: MUnit, U4 <: TSingleUnit, V4 <: MUnit, U5 <: TSingleUnit, V5 <: MUnit, U6 <: TSingleUnit, V6 <: MUnit, U7 <: TSingleUnit, V7 <: MUnit, U8 <: TSingleUnit, V8 <: MUnit] extends AnyVal

    Represents a system of units of measurements consisting of 8 units.

  24. implicit final class UnitNameBuilder extends AnyVal

    Annotations
    @inline()
  25. case class Vector2A[A <: AffineSpace](x: DoubleA[A], y: DoubleA[A]) extends Product with Serializable

    A two-dimensional vector within an affine space

  26. case class Vector2U[U <: MUnit](x: DoubleU[U], y: DoubleU[U]) extends Product with Serializable

    A two-dimensional vector with a unit

  27. class Vector2UBuilder extends AnyRef

  28. case class Vector3A[A <: AffineSpace](x: DoubleA[A], y: DoubleA[A], z: DoubleA[A]) extends Product with Serializable

    A three-dimensional vector within an affine space

  29. case class Vector3U[U <: MUnit](x: DoubleU[U], y: DoubleU[U], z: DoubleU[U]) extends Product with Serializable

    A three-dimensional vector with a unit

  30. class Vector3UBuilder extends AnyRef

  31. case class WithA[N, A <: AffineSpace](value: N) extends Product with Serializable

    A value within an affine space.

  32. case class WithU[N, U <: MUnit](value: N) extends Product with Serializable

    A value with a unit of measure.

  33. implicit final class WithUBuilder[N] extends AnyVal

    Extension methods for everything

  34. type _1 = TDimensionless

    Unit dimensionless values have, which is 1.

  35. type cube[U <: MUnit] = units.cube.U.ToPower[P3]

    Takes unit to the third power.

  36. type inverse[U <: MUnit] = units.inverse.U.Invert

    Gets inverse of a unit.

    Gets inverse of a unit. inverse[second] is equivalent to hertz.

  37. type inverseCube[U <: MUnit] = units.inverseCube.U.ToPower[N3]

    Gets inverse of the third power a unit.

  38. type inversePower4[U <: MUnit] = units.inversePower4.U.ToPower[N4]

    Gets inverse of the fourth power a unit.

  39. type inversePower5[U <: MUnit] = units.inversePower5.U.ToPower[N5]

    Gets inverse of the fifth power a unit.

  40. type inverseSquare[U <: MUnit] = units.inverseSquare.U.ToPower[N2]

    Gets inverse of the second power a unit.

  41. type power4[U <: MUnit] = units.power4.U.ToPower[P4]

    Takes unit to the fourth power.

  42. type power5[U <: MUnit] = units.power5.U.ToPower[P5]

    Takes unit to the fifth power.

  43. type square[U <: MUnit] = units.square.U.ToPower[P2]

    Takes unit to the second power.

  44. type ×[U <: MUnit, V <: MUnit] = units.×.U.Mul[V]

    Unit multiplication.

Value Members

  1. object Currency

    Some of currencies of the world.

  2. object DoubleA extends Serializable

  3. object DoubleU extends Serializable

  4. object Information

    Units of information.

  5. object IntA extends Serializable

  6. object IntU extends Serializable

  7. object Mechanical

    Abstract definition of mechanical units, for use with explicit polymorphism.

  8. object SI

    SI units.

  9. object System1

  10. object System2

  11. object System3

  12. object System4

  13. object System5

  14. object System6

  15. object System7

  16. object System8

  17. object USCustomary

    US customary and British units and their conversions to SI.

  18. object Vector2A extends Serializable

  19. object Vector2U extends Serializable

  20. object Vector3A extends Serializable

  21. object Vector3U extends Serializable

  22. object WithA extends Serializable

  23. object WithU extends Serializable

  24. package arrays

  25. package constants

  26. package defining

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

  27. implicit def implicit_dimensionless2DoubleUBuilder(value: DoubleU[_1]): DoubleUBuilder

    Annotations
    @inline()
  28. implicit def implicit_dimensionless2IntUBuilder(value: IntU[_1]): IntUBuilder

    Annotations
    @inline()
  29. implicit def implicit_dimensionless2Vector2UBuilder(value: Vector2U[_1]): Vector2UBuilder

    Annotations
    @inline()
  30. implicit def implicit_dimensionless2Vector3UBuilder(value: Vector3U[_1]): Vector3UBuilder

    Annotations
    @inline()
  31. implicit def implicit_float2DoubleUBuilder(value: Float): DoubleUBuilder

    Annotations
    @inline()
  32. implicit def implicit_fromDimensionlessDouble(i: DoubleU[_1]): Double

    Annotations
    @inline()
  33. implicit def implicit_fromDimensionlessInt(i: IntU[_1]): Long

    Annotations
    @inline()
  34. implicit def implicit_fromDimensionlessTuple(i: Vector3U[_1]): (Double, Double, Double)

    Annotations
    @inline()
  35. implicit def implicit_int2IntUBuilder(value: Int): IntUBuilder

    Annotations
    @inline()
  36. implicit def implicit_toDimensionlessDouble(i: Double): DoubleU[_1]

    Annotations
    @inline()
  37. implicit def implicit_toDimensionlessFloat(i: Float): DoubleU[_1]

    Annotations
    @inline()
  38. implicit def implicit_toDimensionlessInt(i: Int): IntU[_1]

    Annotations
    @inline()
  39. implicit def implicit_toDimensionlessLong(i: Long): IntU[_1]

    Annotations
    @inline()
  40. implicit def implicit_toDimensionlessTupleDDD(i: (Double, Double, Double)): Vector3U[_1]

    Annotations
    @inline()
  41. implicit def implicit_toDimensionlessTupleIII(i: (Int, Int, Int)): Vector3U[_1]

    Annotations
    @inline()
  42. implicit def implicit_tupleDD2Vector2UBuilder(value: (Double, Double)): Vector2UBuilder

    Annotations
    @inline()
  43. implicit def implicit_tupleDDD2Vector3UBuilder(value: (Double, Double, Double)): Vector3UBuilder

    Annotations
    @inline()
  44. implicit def implicit_tupleII2Vector2UBuilder(value: (Int, Int)): Vector2UBuilder

    Annotations
    @inline()
  45. implicit def implicit_tupleIII2Vector3UBuilder(value: (Int, Int, Int)): Vector3UBuilder

    Annotations
    @inline()
  46. implicit def implicit_widening[U <: MUnit](i: IntU[U]): DoubleU[U]

    Annotations
    @inline()
  47. implicit def implicit_wideningA[A <: AffineSpace](i: IntA[A]): DoubleA[A]

    Annotations
    @inline()
  48. package internal

  49. package utils

Inherited from AnyRef

Inherited from Any

Ungrouped