π File Manager Pro
v10.0.3 | PHP: 8.1.34
Server: Apache
2026-06-22 10:48:40
π
/ (Root)
/
opt
/
alt
/
ruby27
/
share
/
ri
/
system
/
String
π /opt/alt/ruby27/share/ri/system/String
π Refresh
βοΈ
Editing: byteslice-i.ri
Read Only
U:RDoc::AnyMethod[iI"byteslice:ETI"String#byteslice;TF:privateo:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"<Byte Reference---If passed a single Integer, returns a ;TI"Csubstring of one byte at that position. If passed two Integer ;TI"Qobjects, returns a substring starting at the offset given by the first, and ;TI"La length given by the second. If given a Range, a substring containing ;TI"Mbytes at offsets given by the range is returned. In all three cases, if ;TI"Nan offset is negative, it is counted from the end of <i>str</i>. Returns ;TI"Q<code>nil</code> if the initial offset falls outside the string, the length ;TI"Iis negative, or the beginning of the range is greater than the end. ;TI"AThe encoding of the resulted string keeps original encoding.;To:RDoc::Markup::BlankLine o:RDoc::Markup::Verbatim; [ I"&"hello".byteslice(1) #=> "e" ;TI"&"hello".byteslice(-1) #=> "o" ;TI"'"hello".byteslice(1, 2) #=> "el" ;TI"/"\x80\u3042".byteslice(1, 3) #=> "\u3042" ;TI"2"\x03\u3042\xff".byteslice(1..3) #=> "\u3042";T:@format0: @fileI" string.c;T:0@omit_headings_from_table_of_contents_below0I"οΏ½str.byteslice(integer) -> new_str or nil str.byteslice(integer, integer) -> new_str or nil str.byteslice(range) -> new_str or nil ;T0[ I"(*args);T@FI"String;TcRDoc::NormalClass00
πΎ Save Changes
β Cancel