⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.116
Server IP:
78.40.11.138
Server:
Linux tango.o2switch.net 4.18.0-553.30.1.lve.el8.x86_64 #1 SMP Tue Dec 3 01:21:19 UTC 2024 x86_64
Server Software:
Apache
PHP Version:
7.4.33
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
opt
/
alt
/
ruby33
/
share
/
ri
/
system
/
Kernel
/
Edit File: BigDecimal-i.ri
U:RDoc::AnyMethod[iI"BigDecimal:ETI"Kernel#BigDecimal;TF:privateo:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"4Returns the \BigDecimal converted from +value+ ;TI"2with a precision of +ndigits+ decimal digits.;To:RDoc::Markup::BlankLine o; ; [I"BWhen +ndigits+ is less than the number of significant digits ;TI"Cin the value, the result is rounded to that number of digits, ;TI"Aaccording to the current rounding mode; see BigDecimal.mode.;T@o; ; [I"UWhen +ndigits+ is 0, the number of digits to correctly represent a float number ;TI"!is determined automatically.;T@o; ; [I"RReturns +value+ converted to a \BigDecimal, depending on the type of +value+:;T@o:RDoc::Markup::List: @type:BULLET:@items[ o:RDoc::Markup::ListItem:@label0; [o; ; [I"JInteger, Float, Rational, Complex, or BigDecimal: converted directly:;T@o:RDoc::Markup::Verbatim; [I"Y# Integer, Complex, or BigDecimal value does not require ndigits; ignored if given. ;TI"2BigDecimal(2) # => 0.2e1 ;TI"2BigDecimal(Complex(2, 0)) # => 0.2e1 ;TI"2BigDecimal(BigDecimal(2)) # => 0.2e1 ;TI"1# Float or Rational value requires ndigits. ;TI"2BigDecimal(2.0, 0) # => 0.2e1 ;TI"2BigDecimal(Rational(2, 1), 0) # => 0.2e1 ;T:@format0o;;0; [o; ; [I"WString: converted by parsing if it contains an integer or floating-point literal; ;TI"0leading and trailing whitespace is ignored:;T@o;; [ I":# String does not require ndigits; ignored if given. ;TI"$BigDecimal('2') # => 0.2e1 ;TI"$BigDecimal('2.0') # => 0.2e1 ;TI"$BigDecimal('0.2e1') # => 0.2e1 ;TI"$BigDecimal(' 2.0 ') # => 0.2e1 ;T;0o;;0; [o; ; [I":Other type that responds to method <tt>:to_str</tt>: ;TI"Lfirst converted to a string, then converted to a \BigDecimal, as above.;T@o;;0; [o; ; [I"Other type:;T@o;; ;;[o;;0; [o; ; [I"CRaises an exception if keyword argument +exception+ is +true+.;To;;0; [o; ; [I">Returns +nil+ if keyword argument +exception+ is +false+.;T@o; ; [I"9Raises an exception if +value+ evaluates to a Float ;TI"0and +digits+ is larger than Float::DIG + 1.;T: @fileI" ext/bigdecimal/bigdecimal.c;T:0@omit_headings_from_table_of_contents_below0I"pBigDecimal(value, exception: true) -> bigdecimal BigDecimal(value, ndigits, exception: true) -> bigdecimal ;T0[ I"(p1, p2 = v2, p3 = {});T@TFI"Kernel;TcRDoc::NormalModule00
Simpan