Module

Dependencies

There's no documentation for this item.

Classes
LoadingModule
Public Methods
associate_with
autoload_module! Attempt to autoload the provided module name by searching for a directory matching the expect path suffix. If found, the module is created and assigned to into’s constants with the name const_name. Provided that the directory was loaded from a reloadable base path, it is added to the set of constants that are to be unloaded.
autoloadable_module? Does the provided path_suffix correspond to an autoloadable module? Instead of returning a boolean, the autoload base for this module is returned.
autoloaded? Determine if the given constant has been automatically loaded.
clear
depend_on
load?
load_file Load the file at the provided path. const_paths is a set of qualified constant names. When loading the file, Dependencies will watch for the addition of these constants. Each that is defined will be marked as autoloaded, and will be removed when Dependencies.clear is next called.
load_missing_constant Load the constant named const_name which is missing from from_mod. If it is not possible to load the constant into from_mod, try its parent module using const_missing.
load_once_path?
loadable_constants_for_path Given path, a filesystem path to a ruby file, return an array of constant paths which would cause Dependencies to attempt to load this file.
mark_for_unload Mark the provided constant name for unloading. This constant will be unloaded on each request, not just the next one.
new_constants_in Run the provided block and detect the new constants that were loaded during its execution. Constants may only be regarded as ‘new’ once — so if the block calls new_constants_in again, then the constants defined within the inner call will not be reported in this one.
qualified_const_defined? Is the provided constant path defined?
qualified_name_for Return the constant path for the provided parent and constant name.
remove_constant
remove_unloadable_constants! Remove the constants that have been autoloaded, and those that have been marked for unloading.
require_or_load
search_for_file Search for a file in load_paths matching the provided suffix.
to_constant_name Convert the provided const desc to a qualified constant name (as a string). A module, class, symbol, or string may be provided.
will_unload? Will the provided constant descriptor be unloaded?
Protected Methods
log
log_call
Comments

Have your say
Please use Textile formatting (click here for a cheat sheet). Use <code/> and <pre/> for code samples.
Click here to login with OpenID to to post comments.