Struct ketos::interpreter::Builder [] [src]

pub struct Builder { /* fields omitted */ }

Builds an Interpreter with configured parameters.

Some methods are mutually exclusive. For example, a Scope contains a ModuleLoader instance. Therefore, the builder will panic if both a Scope and a ModuleLoader are supplied.

Example


let interp = Builder::new()
    .name("foo")
    // ...
    .finish();

// ...

Methods

impl Builder
[src]

Creates a new Builder.

Sets the name of the new scope.

Sets the context of the new interpreter.

Sets the scope in the new context.

Sets the restriction configuration in the new context.

Sets the I/O handles in the new scope.

Sets the module loader in the new scope.

Sets the search paths for a new FileModuleLoader.

Consumes the Builder and creates an Interpreter.