MaybeRate

object MaybeRate
Companion
class
trait Sum
trait Mirror
class Object
trait Matchable
class Any

Type members

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Inherited from
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Inherited from
Mirror

Value members

Concrete methods

def apply(id: Int): MaybeRate

Constructs an optional rate from a given identifier. -1 denotes the UndefinedRate, values >= 0 denote the identifier of a defined rate.

Constructs an optional rate from a given identifier. -1 denotes the UndefinedRate, values >= 0 denote the identifier of a defined rate.

def max_?(rates: MaybeRate*): MaybeRate

Calculates the maximum rate among a list of optional rates. If the list is empty or contains at least one UndefinedRate, the return value is also UndefinedRate.

Calculates the maximum rate among a list of optional rates. If the list is empty or contains at least one UndefinedRate, the return value is also UndefinedRate.

def min_?(rates: MaybeRate*): MaybeRate

Calculates the minimum rate among a list of optional rates. If the list is empty or contains at least one UndefinedRate, the return value is also UndefinedRate.

Calculates the minimum rate among a list of optional rates. If the list is empty or contains at least one UndefinedRate, the return value is also UndefinedRate.

def reduce(rates: MaybeRate*): MaybeRate

Reduces a list of optional rates to one value. If the list is empty or contains different rates, the return value is UndefinedRate. Otherwise, if all elements are equal, returns that one rate.

Reduces a list of optional rates to one value. If the list is empty or contains different rates, the return value is UndefinedRate. Otherwise, if all elements are equal, returns that one rate.