るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.145秒)
トップページ > クエリ:t[x] > クエリ:Ruby[x] > クエリ:ruby[x] > クエリ:string[x] > クラス:String[x] > クエリ:split[x] > クエリ:unpack[x]

別のキーワード

  1. fiddle build_ruby_platform
  2. rbconfig ruby
  3. fiddle ruby_free
  4. rake ruby
  5. rubygems/defaults ruby_engine

ライブラリ

検索結果

String#unpack(template) -> Array (32150.0)

Array#pack で生成された文字列を テンプレート文字列 template にしたがってアンパックし、 それらの要素を含む配列を返します。

...レート文字列 template にしたがってアンパックし、
それらの要素を含む配列を返します。

@param template pack テンプレート文字列
@return オブジェクトの配列


以下にあげるものは、Array#pack、String#unpack
のテンプレート...
...どに適切)
//emlist{
S>: big endian unsigned 16bit(nと同じ)
s>: big endian int16_t
s!>: big endian signed short
l<: little endian int32_t
l!<: little endian signed long
//}

=== 各テンプレート文字の説明

説明中、Array#pack と String#unpack で違いのあるもの...
...の説明 / String#unpack の説明」としています。

: a

ASCII文字列(ヌル文字を詰める/後続するヌル文字やスペースを残す)
//emlist[][ruby]{
["abc"].pack("a") # => "a"
["abc"].pack("a*") # => "abc"
["abc"].pack("a4") # => "abc\x00"

"abc\0".unpack("a4") # =>...
...ト文字列 template にしたがってアンパックし、
それらの要素を含む配列を返します。

@param template pack テンプレート文字列
@return オブジェクトの配列


以下にあげるものは、Array#pack、String#unpackString#unpack1
のテン...