Module | YARD::Templates::Engine |
In: |
lib/yard/templates/engine.rb
|
Passes a set of objects to the +:fulldoc+ template for full documentation generation. This is called by {CLI::Yardoc} to most commonly perform HTML documentation generation.
@param [Array<CodeObjects::Base>] objects a list of {CodeObjects::Base}
objects to pass to the template
Renders a template on a {CodeObjects::Base code object} using a set of default (overridable) options. Either the +:object+ or +:type+ keys must be provided.
If a +:serializer+ key is provided and +:serialize+ is not set to false, the rendered contents will be serialized through the {Serializers::Base} object. See {with_serializer}.
@example Renders an object with html formatting
Engine.render(:format => :html, :object => obj)
@example Renders without an object
Engine.render(:type => :fulldoc, :otheropts => somevalue)
@param [Hash] options the options hash @option options [Symbol] :format (:text) the default format @option options [Symbol] :type (nil) the :object‘s type. @option options [Symbol] :template (:default) the default template @return [String] the rendered template
Creates a template module representing the path. Searches on disk for the first directory named path (joined by ’/’) within the template paths and builds a template module for. All other matching directories in other template paths will be included in the generated module as mixins (for overriding).
@param [Array<String, Symbol>] path a list of path components @raise [ArgumentError] if the path does not exist within one of the
{template_paths} on disk.
Serializes the results of a block with a serializer object.
@param [CodeObjects::Base] object the code object to serialize @param [Serializers::Base] serializer the serializer object @yield a block whose result will be serialize @yieldreturn [String] the contents to serialize @see Serializers::Base