Module: GOBL::Extensions::Tax::RegimeHelper::ClassMethods

Included in:
Tax::RegimeDef
Defined in:
lib/gobl/extensions/tax/regime_helper.rb

Instance Method Summary collapse

Instance Method Details

#fetch(code) ⇒ Regime

Loads a Tax::Regime object identified by the given code with all its data

Parameters:

  • code (String)

    the code of the regime to load

Returns:

  • (Regime)

    the requested regime



14
15
16
# File 'lib/gobl/extensions/tax/regime_helper.rb', line 14

def fetch(code)
  regimes[code] ||= load_regime(code)
end