Class: Flt::DecNum::Context

Inherits:
Num::ContextBase show all
Defined in:
lib/flt/dec_num.rb

Overview

This is the Context class for Flt::DecNum.

The context defines the arithmetic context: rounding mode, precision,…

DecNum.context is the current (thread-local) context for DecNum numbers.

Constant Summary

Constants inherited from Num::ContextBase

Num::ContextBase::CONDITION_MAP

Instance Attribute Summary

Attributes inherited from Num::ContextBase

#angle, #capitals, #clamp, #emax, #emin, #flags, #ignored_flags, #rounding, #traps

Instance Method Summary collapse

Methods inherited from Num::ContextBase

#Num, #_coerce, #abs, #add, #assign, #clamp?, #cmath, #coefficient, #coercible_types, #coercible_types_or_num, #compare, #convert_to, #copy_abs, #copy_from, #copy_negate, #copy_sign, #define_conversion_from, #define_conversion_to, #digits, #digits=, #div, #divide, #divide_int, #divmod, #divrem, #dup, #elimit=, #epsilon, #etiny, #etop, #eval, #exact, #exact=, #exact?, #exception, #exp, #exponent, #fma, #half_epsilon, #ignore_all_flags, #ignore_flags, #infinite?, #inspect, #int_div_radix_power, #int_mult_radix_power, #int_radix_power, #ln, #log, #log10, #log2, #logb, #math, #maximum_coefficient, #maximum_finite, #maximum_nan_diagnostic_digits, #maximum_subnormal, #minimum_nonzero, #minimum_normal, #minimum_normalized_coefficient, #minus, #modulo, #multiply, #nan?, #next_minus, #next_plus, #next_toward, #normal?, #normalize, #normalized_integral_exponent, #normalized_integral_significand, #num_class, #number_class, #plus, #power, #prec, #prec=, #precision, #precision=, #quantize, #radix, #reduce, #regard_flags, #remainder, #remainder_near, #rescale, #same_quantum?, #scaleb, #sign, #split, #sqrt, #strict_epsilon, #subnormal?, #subtract, #to_eng_string, #to_int_scale, #to_integral_exact, #to_integral_value, #to_normalized_int_scale, #to_s, #to_sci_string, #to_string, #ulp, #zero?

Constructor Details

#initialize(*options) ⇒ Context

See Flt::Num::ContextBase#new() for the valid options

See also the context constructor method Flt::Num.Context().



44
45
46
# File 'lib/flt/dec_num.rb', line 44

def initialize(*options)
  super(DecNum, *options)
end