lib/lorj_defaults.rb
# Check if data found in this default layer has a value.
#
# It implements the following:
# 1. Search in data_options[:section] section or :default section if missing
# 2. otherwise, provide the metadata default value, erb like.
#   It uses data_options[:metadata_section]
#
# * *Args*
#   - +keys+ : Array of key path to found
#
# * *Returns*
#   - boolean : true if the key path was found
#
Check if data found in this default layer has a value.
It implements the following:
1. Search in data_options[:section] section or :default section if missing
2. otherwise, provide the metadata default value, erb like.

*Args
+keys+ : Array of key path to found

*Returns
boolean : true if the key path was found
Check if data found in this default layer has a value . It implements the following : 1 . Search in data_options [ : section ] section or : default section if missing 2 . otherwise provide the metadata default value erb like . * Args + keys + : Array of key path to found * Returns boolean : true if the key path was found
def exist?(*keys)
      return nil if keys.length == 0
      if @data_options[:section].nil?
        section = :default
      else
        section = @data_options[:section]
      end
      return true if p_exist?(section, *keys)
      metadata_section = @data_options[:metadata_section]
      return false if metadata_section.nil?
      Lorj.data.exist?(:sections, metadata_section, keys[0], :default_value)
    end
def exist? ( * keys ) return nil if keys . length == 0 if @data_options [ :section ] . nil? section = :default else section = @data_options [ :section ] end return true if p_exist? ( section , * keys ) metadata_section = @data_options [ :metadata_section ] return false if metadata_section . nil? Lorj . data . exist? ( :sections , metadata_section , keys [ 0 ] , :default_value ) end
Check if data found in this default layer has a value.
Check if data found in this default layer has a value .
keys
<not_specific>