ÿØÿà JFIF    ÿÛ „ ( %!1!%*+...983,7(-.- entries-c.ri000064400000001451152360743000006772 0ustar00U:RDoc::AnyMethod[iI" entries:ETI"Dir::entries;TT: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"CReturns an array containing all of the filenames in the given ;TI"Gdirectory. Will raise a SystemCallError if the named ;TI"directory doesn't exist.;To:RDoc::Markup::BlankLineo; ; [I"OThe optional enc argument specifies the encoding of the directory. ;TI"7If not specified, the filesystem encoding is used.;T@o:RDoc::Markup::Verbatim; [I"DDir.entries("testdir") #=> [".", "..", "config.h", "main.rb"];T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"cDir.entries( dirname ) -> array Dir.entries( dirname, encoding: enc ) -> array ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00each_child-i.ri000064400000001463152360743000007375 0ustar00U:RDoc::AnyMethod[iI"each_child:ETI"Dir#each_child;TF: privateo:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"DCalls the block once for each entry except for "." and ".." in ;TI"Gthis directory, passing the filename of each entry as a parameter ;TI"to the block.;To:RDoc::Markup::BlankLineo; ; [I"=If no block is given, an enumerator is returned instead.;T@o:RDoc::Markup::Verbatim; [I"d = Dir.new("testdir") ;TI"*d.each_child {|x| puts "Got #{x}" } ;T: @format0o; ; [I"produces:;T@o; ; [I"Got config.h ;TI"Got main.rb;T; 0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"idir.each_child {| filename | block } -> dir dir.each_child -> an_enumerator ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00to_path-i.ri000064400000000722152360743000006765 0ustar00U:RDoc::AnyMethod[iI" to_path:ETI"Dir#to_path;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"EReturns the path parameter passed to dir's constructor.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"d = Dir.new("..") ;TI"d.path #=> "..";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"!dir.to_path -> string or nil;T0[I"();T@FI"Dir;TcRDoc::NormalClass00home-c.ri000064400000000616152360743000006253 0ustar00U:RDoc::AnyMethod[iI" home:ETI"Dir::home;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"FReturns the home directory of the current user or the named user ;TI"if given.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"@Dir.home() -> "/home/me" Dir.home("root") -> "/root" ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00inspect-i.ri000064400000000503152360743000006771 0ustar00U:RDoc::AnyMethod[iI" inspect:ETI"Dir#inspect;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"0Return a string describing this Dir object.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.inspect -> string ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00delete-c.ri000064400000000617152360743000006566 0ustar00U:RDoc::AnyMethod[iI" delete:ETI"Dir::delete;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"7Deletes the named directory. Raises a subclass of ;TI"?SystemCallError if the directory isn't empty.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.delete( string ) -> 0;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00%5b%5d-c.ri000064400000000573152360743000006176 0ustar00U:RDoc::AnyMethod[iI"[]:ETI" Dir::[];TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"Equivalent to calling ;TI"?Dir.glob([string,...],0).;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"+Dir[ string [, string ...] ] -> array ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00glob-c.ri000064400000007444152360743000006254 0ustar00U:RDoc::AnyMethod[iI" glob:ETI"Dir::glob;TT: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"OExpands +pattern+, which is an Array of patterns or a pattern String, and ;TI"Ireturns the results as +matches+ or as arguments given to the block.;To:RDoc::Markup::BlankLineo; ; [ I"ONote that this pattern is not a regexp, it's closer to a shell glob. See ;TI"MFile::fnmatch for the meaning of the +flags+ parameter. Note that case ;TI"Osensitivity depends on your system (so File::FNM_CASEFOLD is ignored), as ;TI"6does the order in which the results are returned.;T@o:RDoc::Markup::List: @type: NOTE: @items[ o:RDoc::Markup::ListItem: @label[I"*;T; [ o; ; [I"FMatches any file. Can be restricted by other values in the glob. ;TI"2Equivalent to / .* /x in regexp.;T@o; ; ;;[ o;;[I"*;T; [o; ; [I"Matches all files;To;;[I"c*;T; [o; ; [I"4Matches all files beginning with c;To;;[I"*c;T; [o; ; [I"1Matches all files ending with c;To;;[I"\*c\*;T; [o; ; [I"6Match all files that have c in them ;TI")(including at the beginning or end).;T@o; ; [I"LNote, this will not match Unix-like hidden files (dotfiles). In order ;TI"=to include those in the match results, you must use the ;TI"EFile::FNM_DOTMATCH flag or something like "{*,.*}".;T@o;;[I"**;T; [o; ; [I"%Matches directories recursively.;T@o;;[I"?;T; [o; ; [I"LMatches any one character. Equivalent to /.{1}/ in regexp.;T@o;;[I"[set];T; [o; ; [I"NMatches any one character in +set+. Behaves exactly like character sets ;TI"=in Regexp, including set negation ([^a-z]).;T@o;;[I"{p,q};T; [ o; ; [I"FMatches either literal p or literal q. ;TI"1Equivalent to pattern alternation in regexp.;T@o; ; [I"LMatching literals may be more than one character in length. More than ;TI"#two literals may be specified.;T@o;;[I" \\ ;T; [ o; ; [I"$Escapes the next metacharacter.;T@o; ; [I"KNote that this means you cannot use backslash on windows as part of a ;TI"Aglob, i.e. Dir["c:\\foo*"] will not work, use ;TI")Dir["c:/foo*"] instead.;T@o; ; [I"Examples:;T@o:RDoc::Markup::Verbatim; [I":Dir["config.?"] #=> ["config.h"] ;TI":Dir.glob("config.?") #=> ["config.h"] ;TI"9Dir.glob("*.[a-z][a-z]") #=> ["main.rb"] ;TI":Dir.glob("*.[^r]*") #=> ["config.h"] ;TI"EDir.glob("*.{rb,h}") #=> ["main.rb", "config.h"] ;TI"EDir.glob("*") #=> ["config.h", "main.rb"] ;TI"PDir.glob("*", File::FNM_DOTMATCH) #=> [".", "..", "config.h", "main.rb"] ;TI" ;TI"'rbfiles = File.join("**", "*.rb") ;TI"9Dir.glob(rbfiles) #=> ["main.rb", ;TI"= # "lib/song.rb", ;TI"E # "lib/song/karaoke.rb"] ;TI"&libdirs = File.join("**", "lib") ;TI"5Dir.glob(libdirs) #=> ["lib"] ;TI" ;TI"7librbfiles = File.join("**", "lib", "**", "*.rb") ;TI"=Dir.glob(librbfiles) #=> ["lib/song.rb", ;TI"E # "lib/song/karaoke.rb"] ;TI" ;TI"1librbfiles = File.join("**", "lib", "*.rb") ;TI" ["lib/song.rb"];T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"gDir.glob( pattern, [flags] ) -> matches Dir.glob( pattern, [flags] ) { |filename| block } -> nil ;T0[I"(p1, p2 = v2);T@‡FI"Dir;TcRDoc::NormalClass00mktmpdir-c.ri000064400000004371152360743000007154 0ustar00U:RDoc::AnyMethod[iI" mktmpdir:EFI"Dir::mktmpdir;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"0Dir.mktmpdir creates a temporary directory.;To:RDoc::Markup::BlankLineo; ; [I"4The directory is created with 0700 permission. ;TI"nApplication should not change the permission to make the temporary directory accessible from other users.;T@o; ; [I"HThe prefix and suffix of the name of the directory is specified by ;TI"7the optional first argument, prefix_suffix.;To:RDoc::Markup::List: @type: BULLET: @items[o:RDoc::Markup::ListItem: @label0; [o; ; [I"TIf it is not specified or nil, "d" is used as the prefix and no suffix is used.;To;;0; [o; ; [I"GIf it is a string, it is used as the prefix and no suffix is used.;To;;0; [o; ; [I"cIf it is an array, first element is used as the prefix and second element is used as a suffix.;T@o:RDoc::Markup::Verbatim; [I"-Dir.mktmpdir {|dir| dir is ".../d..." } ;TI"6Dir.mktmpdir("foo") {|dir| dir is ".../foo..." } ;TI"BDir.mktmpdir(["foo", "bar"]) {|dir| dir is ".../foo...bar" } ;T: @format0o; ; [I"2The directory is created under Dir.tmpdir or ;TI"Jthe optional second argument tmpdir if non-nil value is given.;T@o;; [I"7Dir.mktmpdir {|dir| dir is "#{Dir.tmpdir}/d..." } ;TI"CDir.mktmpdir(nil, "/var/tmp") {|dir| dir is "/var/tmp/d..." } ;T;0o; ; [ I"If a block is given, ;TI"3it is yielded with the path of the directory. ;TI"0The directory and its contents are removed ;TI"?using FileUtils.remove_entry before Dir.mktmpdir returns. ;TI"(The value of the block is returned.;T@o;; [ I"Dir.mktmpdir {|dir| ;TI" # use the directory... ;TI"' open("#{dir}/foo", "w") { ... } ;TI"} ;T;0o; ; [I"If a block is not given, ;TI",The path of the directory is returned. ;TI"=In this case, Dir.mktmpdir doesn't remove the directory.;T@o;; [ I"dir = Dir.mktmpdir ;TI" begin ;TI" # use the directory... ;TI"' open("#{dir}/foo", "w") { ... } ;TI" ensure ;TI" # remove the directory. ;TI"" FileUtils.remove_entry dir ;TI"end;T;0: @fileI"lib/tmpdir.rb;T:0@omit_headings_from_table_of_contents_below00I" path;T[I"(prefix_suffix=nil, *rest);T@QFI"Dir;TcRDoc::NormalClass00rmdir-c.ri000064400000000614152360743000006436 0ustar00U:RDoc::AnyMethod[iI" rmdir:ETI"Dir::rmdir;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"7Deletes the named directory. Raises a subclass of ;TI"?SystemCallError if the directory isn't empty.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.rmdir( string ) -> 0;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00new-c.ri000064400000001055152360743000006112 0ustar00U:RDoc::AnyMethod[iI"new:ETI" Dir::new;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"enc argument specifies the encoding of the directory. ;TI"7If not specified, the filesystem encoding is used.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"HDir.new( string ) -> aDir Dir.new( string, encoding: enc ) -> aDir ;T0[I"(p1, p2 = {});T@FI"Dir;TcRDoc::NormalClass00children-i.ri000064400000001016152360743000007114 0ustar00U:RDoc::AnyMethod[iI" children:ETI"Dir#children;TF: privateo:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"EReturns an array containing all of the filenames except for "." ;TI" and ".." in this directory.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"d = Dir.new("testdir") ;TI"-d.children #=> ["config.h", "main.rb"];T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.children -> array ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00each_child-c.ri000064400000001772152360743000007372 0ustar00U:RDoc::AnyMethod[iI"each_child:ETI"Dir::each_child;TT: privateo:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"HCalls the block once for each entry except for "." and ".." in the ;TI"Hnamed directory, passing the filename of each entry as a parameter ;TI"to the block.;To:RDoc::Markup::BlankLineo; ; [I"=If no block is given, an enumerator is returned instead.;T@o:RDoc::Markup::Verbatim; [I"6Dir.each_child("testdir") {|x| puts "Got #{x}" } ;T: @format0o; ; [I"produces:;T@o; ; [I"Got config.h ;TI"Got main.rb;T; 0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"0Dir.each_child( dirname ) {| filename | block } -> nil Dir.each_child( dirname, encoding: enc ) {| filename | block } -> nil Dir.each_child( dirname ) -> an_enumerator Dir.each_child( dirname, encoding: enc ) -> an_enumerator ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00cdesc-Dir.ri000064400000003204152360743000006674 0ustar00U:RDoc::NormalClass[iI"Dir:ET@I" Object;To:RDoc::Markup::Document: @parts[o;;[o:RDoc::Markup::Paragraph;[ I"JObjects of class Dir are directory streams representing ;TI"Jdirectories in the underlying file system. They provide a variety of ;TI";ways to list directories and their contents. See also ;TI"File.;To:RDoc::Markup::BlankLineo; ;[ I"IThe directory used in these examples contains the two regular files ;TI"B(config.h and main.rb), the parent ;TI";directory (..), and the directory itself ;TI"(.).;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0o;;[; I"lib/tmpdir.rb;T; 0; 0; 0[[[[I"Enumerable;To;;[; @; 0I" dir.c;T[[I" class;T[[: public[[I"[];T@%[I" chdir;T@%[I" chroot;T@%[I" delete;T@%[I" entries;T@%[I" exist?;T@%[I" exists?;T@%[I" foreach;T@%[I" getwd;T@%[I" glob;T@%[I" home;T@%[I" mkdir;T@%[I" mktmpdir;FI"lib/tmpdir.rb;T[I"new;T@%[I" open;T@%[I"pwd;T@%[I" rmdir;T@%[I" tmpdir;F@F[I" unlink;T@%[:protected[[: private[[I" instance;T[[; [[I" close;T@%[I" each;T@%[I" inspect;T@%[I" path;T@%[I"pos;T@%[I" pos=;T@%[I" read;T@%[I" rewind;T@%[I" seek;T@%[I" tell;T@%[I" to_path;T@%[;[[;[[[U:RDoc::Context::Section[i0o;;[; 0; 0[@I"lib/cgi/session.rb;TI"lib/cgi/session/pstore.rb;TI"lib/drb/unix.rb;TI"lib/tempfile.rb;T@I"*lib/webrick/httpservlet/cgi_runner.rb;TI"+lib/webrick/httpservlet/filehandler.rb;TI"lib/webrick/server.rb;T@cRDoc::TopLevelchdir-c.ri000064400000003136152360743000006414 0ustar00U:RDoc::AnyMethod[iI" chdir:ETI"Dir::chdir;TT: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [ I"GChanges the current working directory of the process to the given ;TI"Gstring. When called without an argument, changes the directory to ;TI"Athe value of the environment variable HOME, or ;TI"ALOGDIR. SystemCallError (probably ;TI"HErrno::ENOENT) if the target directory does not exist.;To:RDoc::Markup::BlankLineo; ; [ I"CIf a block is given, it is passed the name of the new current ;TI"Cdirectory, and the block is executed with that as the current ;TI"Jdirectory. The original working directory is restored when the block ;TI"Gexits. The return value of chdir is the value of the ;TI">block. chdir blocks can be nested, but in a ;TI"Imulti-threaded program an error will be raised if a thread attempts ;TI"Eto open a chdir block while another thread has one ;TI" open.;T@o:RDoc::Markup::Verbatim; [I""Dir.chdir("/var/spool/mail") ;TI"puts Dir.pwd ;TI"Dir.chdir("/tmp") do ;TI" puts Dir.pwd ;TI" Dir.chdir("/usr") do ;TI" puts Dir.pwd ;TI" end ;TI" puts Dir.pwd ;TI" end ;TI"puts Dir.pwd ;T: @format0o; ; [I"produces:;T@o; ; [ I"/var/spool/mail ;TI" /tmp ;TI" /usr ;TI" /tmp ;TI"/var/spool/mail;T; 0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"WDir.chdir( [ string] ) -> 0 Dir.chdir( [ string] ) {| path | block } -> anObject ;T0[I"(p1 = v1);T@3FI"Dir;TcRDoc::NormalClass00tell-i.ri000064400000001010152360743000006256 0ustar00U:RDoc::AnyMethod[iI" tell:ETI" Dir#tell;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"dir. See also ;TI"Dir#seek.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"d = Dir.new("testdir") ;TI"d.tell #=> 0 ;TI"d.read #=> "." ;TI"d.tell #=> 12;T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.tell -> integer;T0[I"();T@FI"Dir;TcRDoc::NormalClass00close-i.ri000064400000000773152360743000006442 0ustar00U:RDoc::AnyMethod[iI" close:ETI"Dir#close;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"ACloses the directory stream. Any further attempts to access ;TI"5dir will raise an IOError.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"d = Dir.new("testdir") ;TI"d.close #=> nil;T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.close -> nil ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00unlink-c.ri000064400000000617152360743000006624 0ustar00U:RDoc::AnyMethod[iI" unlink:ETI"Dir::unlink;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"7Deletes the named directory. Raises a subclass of ;TI"?SystemCallError if the directory isn't empty.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.unlink( string ) -> 0;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00pos-i.ri000064400000001005152360743000006123 0ustar00U:RDoc::AnyMethod[iI"pos:ETI" Dir#pos;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"dir. See also ;TI"Dir#seek.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"d = Dir.new("testdir") ;TI"d.tell #=> 0 ;TI"d.read #=> "." ;TI"d.tell #=> 12;T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.pos -> integer;T0[I"();T@FI"Dir;TcRDoc::NormalClass00pos%3d-i.ri000064400000001251152360743000006422 0ustar00U:RDoc::AnyMethod[iI" pos=:ETI" Dir#pos=;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"ASynonym for Dir#seek, but returns the position ;TI"parameter.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"4d = Dir.new("testdir") #=> # ;TI"&d.read #=> "." ;TI"%i = d.pos #=> 12 ;TI"'d.read #=> ".." ;TI"%d.pos = i #=> 12 ;TI"&d.read #=> "..";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"#dir.pos = integer -> integer ;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00children-c.ri000064400000001474152360743000007116 0ustar00U:RDoc::AnyMethod[iI" children:ETI"Dir::children;TT: privateo:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"EReturns an array containing all of the filenames except for "." ;TI"Fand ".." in the given directory. Will raise a SystemCallError if ;TI"'the named directory doesn't exist.;To:RDoc::Markup::BlankLineo; ; [I"QThe optional encoding keyword argument specifies the encoding of the ;TI"Bdirectory. If not specified, the filesystem encoding is used.;T@o:RDoc::Markup::Verbatim; [I":Dir.children("testdir") #=> ["config.h", "main.rb"];T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"eDir.children( dirname ) -> array Dir.children( dirname, encoding: enc ) -> array ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00path-i.ri000064400000000711152360743000006261 0ustar00U:RDoc::AnyMethod[iI" path:ETI" Dir#path;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"EReturns the path parameter passed to dir's constructor.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"d = Dir.new("..") ;TI"d.path #=> "..";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.path -> string or nil;T0[I"();T@FI"Dir;TcRDoc::NormalClass00seek-i.ri000064400000001340152360743000006253 0ustar00U:RDoc::AnyMethod[iI" seek:ETI" Dir#seek;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"DSeeks to a particular location in dir. integer ;TI"7must be a value returned by Dir#tell.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"4d = Dir.new("testdir") #=> # ;TI"&d.read #=> "." ;TI"%i = d.tell #=> 12 ;TI"'d.read #=> ".." ;TI"4d.seek(i) #=> # ;TI"&d.read #=> "..";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I" dir.seek( integer ) -> dir ;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00fileno-i.ri000064400000001170152360743000006601 0ustar00U:RDoc::AnyMethod[iI" fileno:ETI"Dir#fileno;TF: privateo:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"6Returns the file descriptor used in dir.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"d = Dir.new("..") ;TI"d.fileno #=> 8 ;T: @format0o; ; [I">This method uses dirfd() function defined by POSIX 2008. ;TI"HNotImplementedError is raised on other platforms, such as Windows, ;TI"(which doesn't provide the function.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.fileno -> integer ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00open-c.ri000064400000001566152360743000006271 0ustar00U:RDoc::AnyMethod[iI" open:ETI"Dir::open;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"OThe optional enc argument specifies the encoding of the directory. ;TI"7If not specified, the filesystem encoding is used.;To:RDoc::Markup::BlankLineo; ; [ I"7With no block, open is a synonym for ;TI"@Dir::new. If a block is present, it is passed ;TI"GaDir as a parameter. The directory is closed at the end of ;TI"Dthe block, and Dir::open returns the value of the ;TI" block.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"¶Dir.open( string ) -> aDir Dir.open( string, encoding: enc ) -> aDir Dir.open( string ) {| aDir | block } -> anObject Dir.open( string, encoding: enc ) {| aDir | block } -> anObject ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00read-i.ri000064400000001102152360743000006233 0ustar00U:RDoc::AnyMethod[iI" read:ETI" Dir#read;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"HReads the next entry from dir and returns it as a string. ;TI"7Returns nil at the end of the stream.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"d = Dir.new("testdir") ;TI"d.read #=> "." ;TI"d.read #=> ".." ;TI"d.read #=> "config.h";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.read -> string or nil ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00chroot-c.ri000064400000000766152360743000006627 0ustar00U:RDoc::AnyMethod[iI" chroot:ETI"Dir::chroot;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [ I"AChanges this process's idea of the file system root. Only a ;TI"Aprivileged process may make this call. Not available on all ;TI"Eplatforms. On Unix systems, see chroot(2) for more ;TI"information.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.chroot( string ) -> 0 ;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00foreach-c.ri000064400000001740152360743000006731 0ustar00U:RDoc::AnyMethod[iI" foreach:ETI"Dir::foreach;TT: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"ICalls the block once for each entry in the named directory, passing ;TI"produces:;T@o; ; [ I" Got . ;TI" Got .. ;TI"Got config.h ;TI"Got main.rb;T; 0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"$Dir.foreach( dirname ) {| filename | block } -> nil Dir.foreach( dirname, encoding: enc ) {| filename | block } -> nil Dir.foreach( dirname ) -> an_enumerator Dir.foreach( dirname, encoding: enc ) -> an_enumerator ;T0[I" (*args);T@FI"Dir;TcRDoc::NormalClass00getwd-c.ri000064400000000760152360743000006435 0ustar00U:RDoc::AnyMethod[iI" getwd:ETI"Dir::getwd;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"JReturns the path to the current working directory of this process as ;TI"a string.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"Dir.chdir("/tmp") #=> 0 ;TI"#Dir.getwd #=> "/tmp";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.getwd -> string;T0[I"();T@FI"Dir;TcRDoc::NormalClass00rewind-i.ri000064400000000772152360743000006624 0ustar00U:RDoc::AnyMethod[iI" rewind:ETI"Dir#rewind;TF: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"1Repositions dir to the first entry.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [ I"d = Dir.new("testdir") ;TI"d.read #=> "." ;TI"&d.rewind #=> # ;TI"d.read #=> ".";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"dir.rewind -> dir ;T0[I"();T@FI"Dir;TcRDoc::NormalClass00pwd-c.ri000064400000000752152360743000006116 0ustar00U:RDoc::AnyMethod[iI"pwd:ETI" Dir::pwd;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"JReturns the path to the current working directory of this process as ;TI"a string.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"Dir.chdir("/tmp") #=> 0 ;TI"#Dir.getwd #=> "/tmp";T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"Dir.pwd -> string;T0[I"();T@FI"Dir;TcRDoc::NormalClass00each-i.ri000064400000001416152360743000006230 0ustar00U:RDoc::AnyMethod[iI" each:ETI" Dir#each;TF: publico:RDoc::Markup::Document: @parts[ o:RDoc::Markup::Paragraph; [I"HCalls the block once for each entry in this directory, passing the ;TI"8filename of each entry as a parameter to the block.;To:RDoc::Markup::BlankLineo; ; [I"=If no block is given, an enumerator is returned instead.;T@o:RDoc::Markup::Verbatim; [I"d = Dir.new("testdir") ;TI"$d.each {|x| puts "Got #{x}" } ;T: @format0o; ; [I"produces:;T@o; ; [ I" Got . ;TI" Got .. ;TI"Got config.h ;TI"Got main.rb;T; 0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"[dir.each { |filename| block } -> dir dir.each -> an_enumerator ;T0[I"();T@ FI"Dir;TcRDoc::NormalClass00empty%3f-c.ri000064400000000660152360743000006756 0ustar00U:RDoc::AnyMethod[iI" empty?:ETI"Dir::empty?;TT: privateo:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"HReturns true if the named file is an empty directory, ;TI">false if it is not a directory or non-empty.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I".Dir.empty?(path_name) -> true or false ;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00tmpdir-c.ri000064400000000466152360743000006625 0ustar00U:RDoc::AnyMethod[iI" tmpdir:EFI"Dir::tmpdir;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"8Returns the operating system's temporary file path.;T: @fileI"lib/tmpdir.rb;T:0@omit_headings_from_table_of_contents_below000[I"();T@FI"Dir;TcRDoc::NormalClass00exist%3f-c.ri000064400000000670152360743000006755 0ustar00U:RDoc::AnyMethod[iI" exist?:ETI"Dir::exist?;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [I"AReturns true if the named file is a directory, ;TI""false otherwise.;T: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"ZDir.exist?(file_name) -> true or false Dir.exists?(file_name) -> true or false ;T0[I" (p1);T@FI"Dir;TcRDoc::NormalClass00mkdir-c.ri000064400000001515152360743000006430 0ustar00U:RDoc::AnyMethod[iI" mkdir:ETI"Dir::mkdir;TT: publico:RDoc::Markup::Document: @parts[o:RDoc::Markup::Paragraph; [ I"DMakes a new directory named by string, with permissions ;TI"?specified by the optional parameter anInteger. The ;TI"1permissions may be modified by the value of ;TI"?File::umask, and are ignored on NT. Raises a ;TI"JSystemCallError if the directory cannot be created. See ;TI"Galso the discussion of permissions in the class documentation for ;TI"File.;To:RDoc::Markup::BlankLineo:RDoc::Markup::Verbatim; [I"7Dir.mkdir(File.join(Dir.home, ".foo"), 0700) #=> 0;T: @format0: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below0I"*Dir.mkdir( string [, integer] ) -> 0 ;T0[I"(p1, p2 = v2);T@FI"Dir;TcRDoc::NormalClass00exists%3f-c.ri000064400000000331152373045310007135 0ustar00U:RDoc::AnyMethod[iI" exists?:ETI"Dir::exists?;TT: publico:RDoc::Markup::Document: @parts[: @fileI" dir.c;T:0@omit_headings_from_table_of_contents_below000[I" (p1);T@ FI"Dir;TcRDoc::NormalClass00