るりまサーチ

最速Rubyリファレンスマニュアル検索!
110件ヒット [1-100件を表示] (0.038秒)

別のキーワード

  1. openssl integer
  2. asn1 integer
  3. _builtin integer
  4. integer new
  5. integer chr

クラス

キーワード

検索結果

<< 1 2 > >>

Integer#ord -> Integer (27228.0)

自身を返します。

...自身を返します。

//emlist[][ruby]{
10.ord #=> 10
# String#ord
?a.ord #=> 97
//}

@see String#ord...

String#ord -> Integer (18216.0)

文字列の最初の文字の文字コードを整数で返します。

...の文字コードを整数で返します。

self が空文字列のときは例外を発生します。

@return 文字コードを表す整数
@raise ArgumentError self の長さが 0 のとき発生

//emlist[例][ruby]{
p "a".ord # => 97
//}

@see Integer#chr, String#chr...

Integer#chr -> String (9008.0)

self を文字コードとして見た時に、引数で与えたエンコーディング encoding に対応する文字を返します。

...ンコーディングを表すオブジェクト。Encoding::UTF_8、'shift_jis' など。
@return 一文字からなる文字列
@raise RangeError self を与えられたエンコーディングで正しく解釈できない場合に発生します。
@see String#ord Encoding.default_internal...

Integer#chr(encoding) -> String (9008.0)

self を文字コードとして見た時に、引数で与えたエンコーディング encoding に対応する文字を返します。

...ンコーディングを表すオブジェクト。Encoding::UTF_8、'shift_jis' など。
@return 一文字からなる文字列
@raise RangeError self を与えられたエンコーディングで正しく解釈できない場合に発生します。
@see String#ord Encoding.default_internal...

Numeric (84.0)

数値を表す抽象クラスです。Integer や Float などの数値クラス は Numeric のサブクラスとして実装されています。

...数値を表す抽象クラスです。Integer や Float などの数値クラス
は Numeric のサブクラスとして実装されています。

演算や比較を行うメソッド(+, -, *, /, <=>)は Numeric のサブクラスで定義されま
す。Numeric で定義されているメソッ...
...れのクラスを参照してください。


=> ruby 2.1.2p95 (2014-05-08 revision 45877) [x86_64-linux]
Numeric Integer Fixnum Bignum Float Rational Complex
------------------------------------------------------------------------------...
...o o
< | - - o o o - -
Numeric Integer Fixnum Bignum Float Rational Complex
-----------------------------------------------------------------------------...
...クラスを参照してください。


=> ruby 2.4.2p198 (2017-09-14 revision 59899) [x86_64-darwin15]
Numeric Integer Float Rational Complex
--------------------------------------------------------------------------------
% |...
...o o o
< | - o o - -
Numeric Integer Float Rational Complex
--------------------------------------------------------------------------------
<< |...

絞り込み条件を変える

String#chr -> String (26.0)

self の最初の文字だけを含む文字列を返します。

...by 1.9 で IO#getc の戻り値が Integer から String を返すように変更になりました。
Ruby 1.8 以前と1.9以降の互換性を保つために String#chr が存在します。

例:
# ruby 1.8 系では STDIN.getc が 116 を返すため Integer#chr が呼び出される
$ ech...
...o test | ruby -e "p STDIN.getc.chr" # => "t"
# ruby 1.9 系以降では STDIN.getc が "t" を返すため String#chr が呼び出される
$ echo test | ruby -e "p STDIN.getc.chr" # => "t"

@see String#ord, Integer#chr...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer) -> Symbol (14.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...ut => true # source buffer may be part of larger source
:after_output => true # stop conversion after output before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT

戻り値は以下のうちのどれかです。

* :invalid_byt...
...redo
when :undefined_conversion
c = ec.primitive_errinfo[3].dup.force_encoding(ec.primitive_errinfo[1])
ec.insert_output('\x{%X:%s}' % [c.ord, c.encoding])
redo
when :incomplete_input
ec.insert_output(ec.primitive_errinfo[3].dump[1..-2])
when :finished
end
break
end while...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset) -> Symbol (14.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...ut => true # source buffer may be part of larger source
:after_output => true # stop conversion after output before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT

戻り値は以下のうちのどれかです。

* :invalid_byt...
...redo
when :undefined_conversion
c = ec.primitive_errinfo[3].dup.force_encoding(ec.primitive_errinfo[1])
ec.insert_output('\x{%X:%s}' % [c.ord, c.encoding])
redo
when :incomplete_input
ec.insert_output(ec.primitive_errinfo[3].dump[1..-2])
when :finished
end
break
end while...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset, destination_bytesize) -> Symbol (14.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...ut => true # source buffer may be part of larger source
:after_output => true # stop conversion after output before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT

戻り値は以下のうちのどれかです。

* :invalid_byt...
...redo
when :undefined_conversion
c = ec.primitive_errinfo[3].dup.force_encoding(ec.primitive_errinfo[1])
ec.insert_output('\x{%X:%s}' % [c.ord, c.encoding])
redo
when :incomplete_input
ec.insert_output(ec.primitive_errinfo[3].dump[1..-2])
when :finished
end
break
end while...

Encoding::Converter#primitive_convert(source_buffer, destination_buffer, destination_byteoffset, destination_bytesize, options) -> Symbol (14.0)

エンコーディング変換のためのメソッドの中で、もっとも細かな扱いが可能なメソッドです。

...ut => true # source buffer may be part of larger source
:after_output => true # stop conversion after output before input
: integer form
Encoding::Converter::PARTIAL_INPUT
Encoding::Converter::AFTER_OUTPUT

戻り値は以下のうちのどれかです。

* :invalid_byt...
...redo
when :undefined_conversion
c = ec.primitive_errinfo[3].dup.force_encoding(ec.primitive_errinfo[1])
ec.insert_output('\x{%X:%s}' % [c.ord, c.encoding])
redo
when :incomplete_input
ec.insert_output(ec.primitive_errinfo[3].dump[1..-2])
when :finished
end
break
end while...

絞り込み条件を変える

<< 1 2 > >>