Class: Hashie::Extensions::Parsers::YamlErbParser

### Home Classes Methods

### In Files

- lib/hashie/extensions/parsers/yaml_erb_parser.rb

### Parent

Object

### Methods

- ::new
- ::perform
- #perform

### Class/Module Index

Quicksearch

- Hashie
- Hashie::Clash
- Hashie::Clash::ChainError
- Hashie::CoercionError
- Hashie::Dash
- Hashie::Extensions
- Hashie::Extensions::Coercion
- Hashie::Extensions::Coercion::ClassMethods
- Hashie::Extensions::Coercion::InstanceMethods
- Hashie::Extensions::Dash
- Hashie::Extensions::Dash::IndifferentAccess
- Hashie::Extensions::Dash::IndifferentAccess::ClassMethods
- Hashie::Extensions::DeepFetch
- Hashie::Extensions::DeepFetch::UndefinedPathError
- Hashie::Extensions::DeepFind
- Hashie::Extensions::DeepMerge
- Hashie::Extensions::IgnoreUndeclared
- Hashie::Extensions::IndifferentAccess
- Hashie::Extensions::KeyConversion
- Hashie::Extensions::Mash
- Hashie::Extensions::Mash::SafeAssignment
- Hashie::Extensions::MergeInitializer
- Hashie::Extensions::MethodAccess
- Hashie::Extensions::MethodAccessWithOverride
- Hashie::Extensions::MethodOverridingWriter
- Hashie::Extensions::MethodQuery
- Hashie::Extensions::MethodReader
- Hashie::Extensions::MethodWriter
- Hashie::Extensions::Parsers
- Hashie::Extensions::Parsers::YamlErbParser
- Hashie::Extensions::PrettyInspect
- Hashie::Extensions::StringifyKeys
- Hashie::Extensions::StringifyKeys::ClassMethods
- Hashie::Extensions::SymbolizeKeys
- Hashie::Extensions::SymbolizeKeys::ClassMethods
- Hashie::Hash
- Hashie::Mash
- Hashie::Rash
- Hashie::Trash

No matching classes.

# Hashie::Extensions::Parsers::YamlErbParser

### Public Class Methods

new(file_path) click to toggle source

    # File lib/hashie/extensions/parsers/yaml_erb_parser.rb, line 7
    def initialize(file_path)
      @content = File.read(file_path)
      @file_path = file_path
    end

perform(file_path) click to toggle source

    # File lib/hashie/extensions/parsers/yaml_erb_parser.rb, line 18
    def self.perform(file_path)
      new(file_path).perform
    end

### Public Instance Methods

perform() click to toggle source

    # File lib/hashie/extensions/parsers/yaml_erb_parser.rb, line 12
    def perform
      template = ERB.new(@content)
      template.filename = @file_path
      YAML.load template.result
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.