A Syberia engine defines the core re-usable structural unit across different Syberia projects. In the same way that Rails engines provide a modular structure for http://rubyonrails.org/ projects, Syberia engines serve as the re-usable rockbed upon which to construct projects that contain similar components.

syberia_engine(filepath = getwd(), ..., root. = TRUE)

syberia_project(filepath = getwd(), ..., root. = TRUE)

Arguments

filepath

character. The root directory of the engine. If this directory does not define a (relative) "config/application.R" file, the parent directories of filepath will be traversed until such a file is found, or the function will error. By default, the current directory.

...

Additional arguments used internally.

root.

logical. Whether or not this is a root-level engine, by default TRUE.

Value

The director object responsible for managing the engine.

Details

A Syberia engine is managed by a director object. This object ensures that the engine cannot access resources outside of its domain, and allows insularity from other engines and the top-level project from which the engine will be used.

Note

The syberia package will maintain an internal cache of engines. Therefore, calling syberia_engine twice will retrieve the cached object. This cache is maintained in the .syberia_env environment object in the syberia package namespace.