Module: FormatEngine

Defined in:
lib/format_engine/format_spec.rb,
lib/format_engine/engine.rb,
lib/format_engine/version.rb,
lib/format_engine/spec_info.rb,
lib/format_engine/attr_parser.rb,
lib/format_engine/attr_formatter.rb,
lib/format_engine/format_spec/literal.rb,
lib/format_engine/format_spec/variable.rb

Overview

Format String Specification Syntax (BNF):

spec = { text | item }+
item = "%" {flag}* {parm {"." parm}?}? {command}
flag = { "~" | "@" | "#" | "&" | "^"  |
         "&" | "*" | "-" | "+" | "="  |
         "?" | "_" | "<" | ">" | "\\" |
         "/" | "." | "," | "|" | "!"  }
parm = { "0" .. "9" }+
command = { "a" .. "z" | "A" .. "Z" }
Sample: x = FormatSpec.get_spec "Elapsed = %*03.1H:%M:%S!"

Defined Under Namespace

Modules: AttrFormatter, AttrParser Classes: Engine, FormatLiteral, FormatSpec, FormatVariable, SpecInfo

Constant Summary collapse

VERSION =

The version of the format_engine gem.

"0.0.2"