'DROP TABLE %1$s' ); /** * @var string */ protected $table = ''; /** * @param string $table */ public function __construct($table = '') { $this->table = $table; } /** * @param null|PlatformInterface $adapterPlatform * @return string */ public function getSqlString(PlatformInterface $adapterPlatform = null) { // get platform, or create default $adapterPlatform = ($adapterPlatform) ?: new AdapterSql92Platform; $sqls = array(); $parameters = array(); foreach ($this->specifications as $name => $specification) { $parameters[$name] = $this->{'process' . $name}( $adapterPlatform, null, null, $sqls, $parameters ); if ($specification && is_array($parameters[$name])) { $sqls[$name] = $this->createSqlFromSpecificationAndParameters( $specification, $parameters[$name] ); } } $sql = implode(' ', $sqls); return $sql; } protected function processTable(PlatformInterface $adapterPlatform = null) { return array($adapterPlatform->quoteIdentifier($this->table)); } }