| Class | PageTemplate::ValueCommand |
| In: |
lib/PageTemplate/commands.rb
|
| Parent: | Command |
ValueCommand will print out a variable name, possibly passing its value through a preprocessor.
variable is first plucked out of the Namespace,
The to_s of the output from Namespace#get is passed through parser‘s preprocessor. If :processor is defined, then parser.preprocessor.send(:processor,body) is called. This allows the designer to choose a particular format for the output. If :processor is not given, then parser‘s default processor is used.
Creates the ValueCommand, with value as the name of the variable to be inserted during output. parser is the Parser object, which we save so we can access its Preprocessor and its default preprocessor