class Fluent::Config::YamlParser::RootBuilder

Attributes

conf[R]
system[R]

Public Class Methods

new(system, conf) click to toggle source
# File lib/fluent/config/yaml_parser/section_builder.rb, line 41
def initialize(system, conf)
  @system = system
  @conf = conf
end

Public Instance Methods

to_element() click to toggle source
# File lib/fluent/config/yaml_parser/section_builder.rb, line 48
def to_element
  Fluent::Config::Element.new('ROOT', '', {}, [@system, @conf].compact.map(&:to_element).flatten)
end
to_s() click to toggle source
# File lib/fluent/config/yaml_parser/section_builder.rb, line 52
def to_s
  s = StringIO.new(+'')
  s.puts(@system.to_s) if @system
  s.puts(@conf.to_s) if @conf

  s.string
end