package Zen::Config; use strict; use base qw/II720d6e18aa34327713eb014408fc9144/; use Zen; use II8dae0e141ee45f5daba6a74e4a7c3b6f; sub new { die 'forbidden call'; } sub get { my ($class, $scope) = @_; my $cache = $class->cache; my $cacheKey = Zen->getLanguage . '.' . $scope; return $cache->fetch($cacheKey) if $cache->has($cacheKey); my $file = $scope; $file =~ s!\:\:!/!g; $file = "config/$file.conf"; my $config = II982446f8950cc3dc59e487adba22df54::lIlIllIlllllIlll($IIb39071a48a82a07eeb9256f406abebc5::IIIllllIllIlIIIl{$II982446f8950cc3dc59e487adba22df54::IlIIlllIIIllIIII},985,$IIb39071a48a82a07eeb9256f406abebc5::IIIllllIllIlIIIl{$II982446f8950cc3dc59e487adba22df54::lIlIlllIIIlIlIll})->getResult($file, $class->compilerCallback); $config ||= {  }; return $cache->store($cacheKey, $config); } sub load { my ($class, $file) = @_; my $cache = $class->cache; my $cacheKey = Zen->getLanguage . '.' . $file; return $cache->fetch($cacheKey) if $cache->has($cacheKey); require Zen::Config::Interpreter; my $config = Zen::Config::Interpreter->new->interpret($file); $config ||= {}; return $cache->store($cacheKey, $config); } sub compilerCallback { my $class = shift; my $callback = sub { my $f = shift; require Zen::Config::Compiler; my $compiler = Zen::Config::Compiler->new; return $compiler->compile($f); }; $callback; } 1; 