lib/puppet/provider/sensu_client_config/json.rb
##
# Memoized method to load the configuration from the filesystem.  This
# configuration state is modified by the property setter methods and written
# out to the filesystem in the flush method.
#
# @return [Hash] configuration map
Memoized method to load the configuration from the filesystem.  This
configuration state is modified by the property setter methods and written
out to the filesystem in the flush method.
Memoized method to load the configuration from the filesystem . This configuration state is modified by the property setter methods and written out to the filesystem in the flush method .
def conf
    return @conf if @conf
    data = File.read(config_file)
    if data.length > 0
      @conf = JSON.parse(data)
    else
      @conf = {}
    end
  rescue Errno::ENOENT
    @conf = {}
  end
def conf return @conf if @conf data = File . read ( config_file ) if data . length > 0 @conf = JSON . parse ( data ) else @conf = { } end rescue Errno :: ENOENT @conf = { } end
Memoized method to load the configuration from the filesystem.
Memoized method to load the configuration from the filesystem .
None
Hash