Class: Patriot::Util::Config::Base

Inherits:
Object
  • Object
show all
Defined in:
lib/patriot/util/config/base.rb

Overview

base class of configuration classes

Direct Known Subclasses

IniFileConfig

Instance Method Summary collapse

Instance Method Details

#get(key, default = nil) ⇒ Object

get value for the specified key

Parameters:

  • key (String)
  • default (Object) (defaults to: nil)

    default value

Returns:

  • (Object)

    the value for the ke

Raises:

  • (NotImplementedError)


10
11
12
# File 'lib/patriot/util/config/base.rb', line 10

def get(key, default=nil)
  raise NotImplementedError
end

#pathString

get path where this configuration is loaded

Returns:

  • (String)

    path to the file

Raises:

  • (NotImplementedError)


16
17
18
# File 'lib/patriot/util/config/base.rb', line 16

def path
  raise NotImplementedError
end