class NvimConf::Writers::Code::SettingsWriter
Constants
- SETTING_GENERATOR_MAPPING
Public Class Methods
new(manager, io, format:, commented:)
click to toggle source
# File lib/nvim_conf/writers/code/settings.rb, line 13 def initialize(manager, io, format:, commented:) @manager = manager @io = io @format = format end
Public Instance Methods
write()
click to toggle source
# File lib/nvim_conf/writers/code/settings.rb, line 19 def write @manager.settings.each do |setting| @io.write( [ generator_class.new(setting).generate, "\n" ].join ) end end
Private Instance Methods
generator_class()
click to toggle source
# File lib/nvim_conf/writers/code/settings.rb, line 32 def generator_class SETTING_GENERATOR_MAPPING[@format] end