class Ven::World
- Ven::World
- Reference
- Object
Overview
World manages communication & cooperation between the
different parts of Ven. It is also used as an inter-file
medium.
Included Modules
Defined in:
ven/world.crConstructors
Instance Method Summary
-
#<<(directory : Path)
Adds directory to the lookup paths if there isn't an identical path already.
- #context : Ven::Suite::Context
-
#die(message : String)
Dies of
WorldErrorwith message. -
#expose(distinct : Array(String)) : Bool
Makes a list of candidate modules matching distinct and evaluates these candidate modules in the context of this world.
-
#feed(filename : String, source : String)
Reads and evaluates source under the filename filename.
-
#gather(ignore : String | Nil = nil)
Gathers all '.ven' files in the lookup directories and registers each in
@modules, under their appropriate 'distinct' paths. -
#load(*extensions : Suite::Extension.class)
Loads given extensions into the context of this world.
- #machine : Ven::Machine
-
#origin(directory : Path)
Returns the origin for the directory.
- #reader : Ven::Reader
-
#verbose=(verbose : Bool)
Whether or not this World is verbose.
-
#visit(quote : Quote) : Model
Visits a quote in the context of this world.
Constructor Detail
Instance Method Detail
Adds directory to the lookup paths if there isn't an identical path already.
Makes a list of candidate modules matching distinct and evaluates these candidate modules in the context of this world. Returns false if found no candidate modules.
Reads and evaluates source under the filename filename.
Gathers all '.ven' files in the lookup directories and
registers each in @modules, under their appropriate
'distinct' paths. except can be used to ignore a
specific '.ven' file.
Loads given extensions into the context of this world.
Returns the origin for the directory. Dies if this
origin does not exist.
Origin is a Ven script that has the same name as the
directory. For example, for the directory a/b/c
the origin will be a/b/c/c.ven.
Visits a quote in the context of this world. Dies on
any interrupt (e.g. NextInterrupt) that was not captured.