⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.13
Server IP:
109.199.105.153
Server:
Linux connect.inboxifs.com 5.15.0-152-generic #162-Ubuntu SMP Wed Jul 23 09:48:42 UTC 2025 x86_64
Server Software:
Apache
PHP Version:
8.2.29
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
usr
/
share
/
ri
/
3.0.0
/
system
/
String
/
Edit File: unpack-i.ri
U:RDoc::AnyMethod[iI"unpack:ETI"String#unpack;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"IDecodes <i>str</i> (which may contain binary data) according to the ;TI"Dformat string, returning an array of each value extracted. The ;TI"Jformat string consists of a sequence of single-character directives, ;TI"7summarized in the table at the end of this entry. ;TI"$Each directive may be followed ;TI"Eby a number, indicating the number of times to repeat with this ;TI"Adirective. An asterisk (``<code>*</code>'') will use up all ;TI"Hremaining elements. The directives <code>sSiIlL</code> may each be ;TI"7followed by an underscore (``<code>_</code>'') or ;TI"Aexclamation mark (``<code>!</code>'') to use the underlying ;TI"Iplatform's native size for the specified type; otherwise, it uses a ;TI"Eplatform-independent consistent size. Spaces are ignored in the ;TI"9format string. See also String#unpack1, Array#pack.;To:RDoc::Markup::BlankLine o:RDoc::Markup::Verbatim; [ I"="abc \0\0abc \0\0".unpack('A6Z6') #=> ["abc", "abc "] ;TI"B"abc \0\0".unpack('a3a3') #=> ["abc", " \000\000"] ;TI">"abc \0abc \0".unpack('Z*Z*') #=> ["abc ", "abc "] ;TI"F"aa".unpack('b8B8') #=> ["10000110", "01100001"] ;TI">"aaa".unpack('h2H2c') #=> ["16", "61", 97] ;TI"9"\xfe\xff\xfe\xff".unpack('sS') #=> [-2, 65534] ;TI"8"now=20is".unpack('M*') #=> ["now is"] ;TI"G"whole".unpack('xax2aX2aX1aX2a') #=> ["h", "e", "l", "l", "o"] ;T:@format0o; ; [I"DThis table summarizes the various formats and the Ruby classes ;TI"returned by each.;T@o;; [WI"Integer | | ;TI"'Directive | Returns | Meaning ;TI"H------------------------------------------------------------------ ;TI">C | Integer | 8-bit unsigned (unsigned char) ;TI"IS | Integer | 16-bit unsigned, native endian (uint16_t) ;TI"IL | Integer | 32-bit unsigned, native endian (uint32_t) ;TI"IQ | Integer | 64-bit unsigned, native endian (uint64_t) ;TI"QJ | Integer | pointer width unsigned, native endian (uintptr_t) ;TI" | | ;TI":c | Integer | 8-bit signed (signed char) ;TI"Fs | Integer | 16-bit signed, native endian (int16_t) ;TI"Fl | Integer | 32-bit signed, native endian (int32_t) ;TI"Fq | Integer | 64-bit signed, native endian (int64_t) ;TI"Nj | Integer | pointer width signed, native endian (intptr_t) ;TI" | | ;TI"=S_ S! | Integer | unsigned short, native endian ;TI";I I_ I! | Integer | unsigned int, native endian ;TI"<L_ L! | Integer | unsigned long, native endian ;TI"PQ_ Q! | Integer | unsigned long long, native endian (ArgumentError ;TI"G | | if the platform has no long long type.) ;TI"FJ! | Integer | uintptr_t, native endian (same with J) ;TI" | | ;TI";s_ s! | Integer | signed short, native endian ;TI"9i i_ i! | Integer | signed int, native endian ;TI":l_ l! | Integer | signed long, native endian ;TI"Nq_ q! | Integer | signed long long, native endian (ArgumentError ;TI"G | | if the platform has no long long type.) ;TI"Ej! | Integer | intptr_t, native endian (same with j) ;TI" | | ;TI"IS> s> S!> s!> | Integer | same as the directives without ">" except ;TI"*L> l> L!> l!> | | big endian ;TI"I!> i!> | | ;TI"3Q> q> Q!> q!> | | "S>" is same as "n" ;TI"3J> j> J!> j!> | | "L>" is same as "N" ;TI" | | ;TI"IS< s< S!< s!< | Integer | same as the directives without "<" except ;TI"-L< l< L!< l!< | | little endian ;TI"I!< i!< | | ;TI"3Q< q< Q!< q!< | | "S<" is same as "v" ;TI"3J< j< J!< j!< | | "L<" is same as "V" ;TI" | | ;TI"Pn | Integer | 16-bit unsigned, network (big-endian) byte order ;TI"PN | Integer | 32-bit unsigned, network (big-endian) byte order ;TI"Ov | Integer | 16-bit unsigned, VAX (little-endian) byte order ;TI"OV | Integer | 32-bit unsigned, VAX (little-endian) byte order ;TI" | | ;TI"/U | Integer | UTF-8 character ;TI"Gw | Integer | BER-compressed integer (see Array#pack) ;TI" ;TI"Float | | ;TI"&Directive | Returns | Meaning ;TI"G----------------------------------------------------------------- ;TI">D d | Float | double-precision, native format ;TI">F f | Float | single-precision, native format ;TI"IE | Float | double-precision, little-endian byte order ;TI"Ie | Float | single-precision, little-endian byte order ;TI"PG | Float | double-precision, network (big-endian) byte order ;TI"Pg | Float | single-precision, network (big-endian) byte order ;TI" ;TI"String | | ;TI"&Directive | Returns | Meaning ;TI"G----------------------------------------------------------------- ;TI"_A | String | arbitrary binary string (remove trailing nulls and ASCII spaces) ;TI"6a | String | arbitrary binary string ;TI"5Z | String | null-terminated string ;TI"5B | String | bit string (MSB first) ;TI"5b | String | bit string (LSB first) ;TI"=H | String | hex string (high nibble first) ;TI"<h | String | hex string (low nibble first) ;TI"0u | String | UU-encoded string ;TI"LM | String | quoted-printable, MIME encoding (see RFC2045) ;TI"Im | String | base64 encoded string (RFC 2045) (default) ;TI"P | | base64 encoded string (RFC 4648) if followed by 0 ;TI"KP | String | pointer to a structure (fixed-length string) ;TI"Bp | String | pointer to a null-terminated string ;TI" ;TI"Misc. | | ;TI"&Directive | Returns | Meaning ;TI"G----------------------------------------------------------------- ;TI"N@ | --- | skip to the offset given by the length argument ;TI"5X | --- | skip backward one byte ;TI"4x | --- | skip forward one byte ;T; 0o; ; [I"HISTORY;T@o:RDoc::Markup::List: @type:BULLET:@items[o:RDoc::Markup::ListItem:@label0; [o; ; [I"2J, J! j, and j! are available since Ruby 2.3.;To;;0; [o; ; [I"5Q_, Q!, q_, and q! are available since Ruby 2.1.;To;;0; [o; ; [I";I!<, i!<, I!>, and i!> are available since Ruby 1.9.3.;T: @fileI"pack.rb;T:0@omit_headings_from_table_of_contents_below0I"'str.unpack(format) -> anArray ;T0[ I" (fmt);T@�FI"String;TcRDoc::NormalClass00
Simpan