Class GetText::ErbParser
In: lib/gettext/tools/parser/erb.rb
Parent: Object

Methods

detect_encoding   init   new   parse   parse  

Constants

MAGIC_COMMENT = /\A#coding:.*\n/

Public Class methods

Sets some preferences to parse ERB files.

  • config: a Hash of the config. It can takes some values below:
    • :extnames: An Array of target files extension. Default is [".rhtml"].

@param path [String] eRuby script path to be parsed @param options [Hash]

Parses eRuby script located at `path`.

This is a short cut method. It equals to `new(path, options).parse`.

@return [Array<POEntry>] Extracted messages @see initialize and parse

Public Instance methods

Extracts messages from @path.

@return [Array<POEntry>] Extracted messages

[Validate]