Warlock.ModuleUtils (warlock v2.0.2)
Summary
Functions
Helpers for working with Module.
Gets a module name from an option or from the module when no option is given.
Replaces a fragment of a module name, e.g App.Controllers.My -> App.Schemas.My
Replaces and slices a module name, e.g App.Controllers.My -> App.Repo
Functions
Link to this function
atom_name(module)
Link to this function
name(module)
Helpers for working with Module.
Link to this function
name_or_option(module, opt)
Gets a module name from an option or from the module when no option is given.
Link to this function
replace_at(module, replacement, index \\ 1)
Replaces a fragment of a module name, e.g App.Controllers.My -> App.Schemas.My
The default index is 1.
Link to this function
slice_replace(module, replacement, index \\ 1)
Replaces and slices a module name, e.g App.Controllers.My -> App.Repo