D7net
Home
Console
Upload
information
Create File
Create Folder
About
Tools
:
/
opt
/
alt
/
ruby34
/
share
/
ri
/
system
/
Kernel
/
Filename :
load-i.ri
back
Copy
U:RDoc::AnyMethod[iI" load:ETI"Kernel#load;TF:publico:RDoc::Markup::Document:@parts[o:RDoc::Markup::Paragraph; [I"@Loads and executes the Ruby program in the file _filename_.;To:RDoc::Markup::BlankLine o; ; [I"JIf the filename is an absolute path (e.g. starts with '/'), the file ;TI"5will be loaded directly using the absolute path.;T@o; ; [I"LIf the filename is an explicit relative path (e.g. starts with './' or ;TI"N'../'), the file will be loaded using the relative path from the current ;TI"directory.;T@o; ; [I"=Otherwise, the file will be searched for in the library ;TI"Fdirectories listed in <code>$LOAD_PATH</code> (<code>$:</code>). ;TI"KIf the file is found in a directory, it will attempt to load the file ;TI"Irelative to that directory. If the file is not found in any of the ;TI"Kdirectories in <code>$LOAD_PATH</code>, the file will be loaded using ;TI"2the relative path from the current directory.;T@o; ; [I"FIf the file doesn't exist when there is an attempt to load it, a ;TI"LoadError will be raised.;T@o; ; [ I"HIf the optional _wrap_ parameter is +true+, the loaded script will ;TI"Mbe executed under an anonymous module. If the optional _wrap_ parameter ;TI"Mis a module, the loaded script will be executed under the given module. ;TI"GIn no circumstance will any local variables in the loaded file be ;TI"+propagated to the loading environment.;T: @fileI"load.c;T:0@omit_headings_from_table_of_contents_below0I"*load(filename, wrap=false) -> true ;T0[ I"(p1, p2 = v2);T@+FI"Kernel;TcRDoc::NormalModule00