Module | Kramdown::Options |
In: |
lib/kramdown/options.rb
|
This module defines all options that are used by parsers and/or converters as well as providing methods to deal with the options.
Definition | = | Struct.new(:name, :type, :default, :desc, :validator) | Struct class for storing the definition of an option. | |
ALLOWED_TYPES | = | [String, Integer, Float, Symbol, Boolean, Object] | Allowed option types. |
Define a new option called name (a Symbol) with the given type (String, Integer, Float, Symbol, Boolean, Object), default value default and the description desc. If a block is specified, it should validate the value and either raise an error or return a valid value.
The type ‘Object’ should only be used for complex types for which none of the other types suffices. A block needs to be specified when using type ‘Object’ and it has to cope with a value given as string and as the opaque type.
This sections contains all pre-defined option validators.
This sections contains all option definitions that are used by the included parsers/converters.
This sections describes the methods that can be used on the Options module.