Module: RubiGen::Lookup

### Home Classes Methods

### In Files

- lib/rubigen/lookup.rb

### Namespace

- MODULE RubiGen::Lookup::ClassMethods

### Methods

- ::included
- #instance

### Files

- History.txt
- License.txt
- Manifest.txt
- Todo.txt
- README.txt
- index.txt
- version-raw.txt
- version.txt

### Class/Module Index

Quicksearch

- RubiGen
- RubiGen::AbstractGemSource
- RubiGen::Base
- RubiGen::Commands
- RubiGen::Commands::Base
- RubiGen::Commands::Create
- RubiGen::Commands::Destroy
- RubiGen::Commands::List
- RubiGen::Commands::RewindBase
- RubiGen::Commands::Update
- RubiGen::GemPathSource
- RubiGen::GeneratedAttribute
- RubiGen::GeneratorError
- RubiGen::GeneratorTestHelper
- RubiGen::Lookup
- RubiGen::Lookup::ClassMethods
- RubiGen::Manifest
- RubiGen::Options
- RubiGen::Options::ClassMethods
- RubiGen::PathFilteredSource
- RubiGen::PathSource
- RubiGen::Scripts
- RubiGen::Scripts::Base
- RubiGen::Scripts::Destroy
- RubiGen::Scripts::Generate
- RubiGen::Scripts::Update
- RubiGen::Source
- RubiGen::Spec
- RubiGen::UsageError
- Rubigen
- Rubigen::CLI
- Dir
- Object

No matching classes.

# RubiGen::Lookup

Generator lookup is managed by a list of sources which return specs describing where to find and how to create generators. This module provides class methods for manipulating the source list and looking up generator specs, and an instance wrapper for quickly instantiating generators by name.

A spec is not a generator: it's a description of where to find the generator and how to create it. A source is anything that yields generators from each. PathSource and GemGeneratorSource are provided.

### Public Class Methods

included(base) click to toggle source

    # File lib/rubigen/lookup.rb, line 50
    def self.included(base)
      base.extend(ClassMethods)
      # base.use_component_sources!  # TODO is this required since it has no scope/source context
    end

### Public Instance Methods

instance(generator_name, args, runtime_options = {}) click to toggle source

Convenience method to instantiate another generator.

    # File lib/rubigen/lookup.rb, line 56
    def instance(generator_name, args, runtime_options = {})
      self.class.active.instance(generator_name, args, runtime_options)
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.