< Perl Programming < Keywords

The opendir keyword

opendir opens a directory called EXPRESION for processing by closedir, readdir, rewinddir, seekdir, and telldir. Returns true, if successful. DIRHANDLE may be an expression with the value of an indirect dirhandle, which is usually the real dirhandle name. If DIRHANDLE is an undefined scalar variable (or array or hash element), the variable is autovivified by assigning a reference to a new anonymous dirhandle. DIRHANDLEs have their own namespace separate from FILEHANDLEs.

Syntax

  opendir DIRHANDLE, EXPRESION
chdirclosedirmkdiropendirreaddirrewinddirrmdirseekdirtelldir
This article is issued from Wikibooks. The text is licensed under Creative Commons - Attribution - Sharealike. Additional terms may apply for the media files.