Class: Giblish::IndexConfigBuilder
- Inherits:
-
Object
- Object
- Giblish::IndexConfigBuilder
- Defined in:
- lib/giblish/config_builders/index_config_builder.rb
Overview
AIDEV-NOTE: Builder for Index configuration following established provider pattern
Class Method Summary collapse
-
.build(config_opts, resource_paths, doc_attr, adoc_src_provider_class = SubtreeIndexBase) ⇒ IndexConfig
Builds complete Index configuration with index generation support.
Class Method Details
.build(config_opts, resource_paths, doc_attr, adoc_src_provider_class = SubtreeIndexBase) ⇒ IndexConfig
Builds complete Index configuration with index generation support. Returns a null configuration if index generation is disabled.
29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 |
# File 'lib/giblish/config_builders/index_config_builder.rb', line 29 def self.build(config_opts, resource_paths, doc_attr, adoc_src_provider_class = SubtreeIndexBase) return null_config if config_opts.no_index adoc_src_provider = adoc_src_provider_class.new( {erb_template_path: resource_paths.idx_erb_template_abs} ) idx = SubtreeInfoBuilder.new( doc_attr, nil, adoc_src_provider, config_opts.index_basename ) IndexConfig.new(post_builders: [idx]) end |