| Class | Lisp::Format::Directives::Directive |
| In: |
lib/facet/lisp-format.rb
|
| Parent: | Object |
Base class for formatting directives. This class makes it easy for sub-classes to access the parameters and modifiers that were given to it when created.
| pos | [R] | The position at which this directive occurs in the input string. |
Given a set of parameters, modifiers, an owning directive if available, and a position in the output string, create a new Directive.
This method should be overridden in sub-classes. It gets called when the directive is to be executed. It does nothing by default.
Join this directive with the following one, given in other. The default is to simply return other. The only known use for this is in SkipWhitespace, where some processing of other is done if it is a Literal.
Check if the given modifier was given. This method should not generally be called, as colon_mod? and at_mod? are easier and better to use.
Read the param:th parameter in the Lisp::Format::State state, using default as a default value if the parameter was not given.