text: // Generated by CoffeeScript 1.6.2
  /*
    Class: Getter
  
    Small module that either requires a file or reads
    from a directory of files
  */
  
  
  (function() {
    var Getter, fs;
  
    fs = require('fs');
  
    Getter = (function() {
      function Getter(_p) {
        this._p = _p;
      }
  
      Getter.prototype.init = function() {
        return this._load();
      };
  
      Getter.prototype.get = function() {
        return this._elems || (this._elems = this._load());
      };
  
      Getter.prototype.__defineGetter__('path', function() {
        return this._p;
      });
  
      Getter.prototype._prefix = function(fileName) {
        return fileName.split(".")[0];
      };
  
      Getter.prototype._load = function() {
        var elems, file, files, _i, _len;
  
        if (fs.statSync(this._p).isFile()) {
          elems = require(this._p);
        } else {
          elems = {};
          files = fs.readdirSync(this._p);
          for (_i = 0, _len = files.length; _i < _len; _i++) {
            file = files[_i];
            if (fs.statSync("" + this._p + "/" + file).isFile()) {
              elems[this._prefix(file)] = require("" + this._p + "/" + file);
            }
          }
        }
        return elems;
      };
  
      return Getter;
  
    })();
  
    module.exports = Getter;
  
  }).call(this);
  