Exemplo n.º 1
0
 public static function setUpBeforeClass()
 {
     $config = new Config();
     $config->setConfigPath(__DIR__ . "/mocks/config.php");
     Schemer::setConfig($config);
     Schemer::setSchemeLocation(__DIR__ . "/mocks/scheme.php");
 }
Exemplo n.º 2
0
 public static function generateCache()
 {
     if (empty(self::$template_code) || !self::loadTemplate(Config::get('template.default'))) {
         throw new RuntimeException('No template could be loaded!');
     }
     self::processTemplate(false);
 }
Exemplo n.º 3
0
 /**
  * Gets the full prefixed table name
  * with every decoration you can find in store.
  *
  * @param string $name
  * The name of the table without table prefix
  *
  * @return string
  * The finalized name of the table
  */
 public static function getTableName($name)
 {
     if (static::isTableInScheme($name)) {
         $scheme = static::getTableScheme($name);
         return $scheme['prefix_name'] === true ? self::$config->get('mysql.table_prefix') . $name : $scheme['prefix_name'] . $name;
     }
 }