update parser_sql

This commit is contained in:
shreesh arora
2021-05-03 01:06:30 +05:30
parent b7ef2391cc
commit d91def3d84
172 changed files with 8743 additions and 2571 deletions

View File

@@ -35,16 +35,13 @@
* @author André Rothe <andre.rothe@phosco.info>
* @copyright 2010-2014 Justin Swanhart and André Rothe
* @license http://www.debian.org/misc/bsd.license BSD License (3 Clause)
* @version SVN: $Id: CharacterSetBuilder.php 914 2014-01-08 11:33:25Z phosco@gmx.de $
* @version SVN: $Id$
*
*/
require_once dirname(__FILE__) . '/../utils/ExpressionType.php';
require_once dirname(__FILE__) . '/../exceptions/UnableToCreateSQLException.php';
require_once dirname(__FILE__) . '/ColumnListBuilder.php';
require_once dirname(__FILE__) . '/ConstraintBuilder.php';
require_once dirname(__FILE__) . '/ReservedBuilder.php';
require_once dirname(__FILE__) . '/IndexTypeBuilder.php';
namespace PHPSQLParser\builders;
use PHPSQLParser\exceptions\UnableToCreateSQLException;
use PHPSQLParser\utils\ExpressionType;
/**
* This class implements the builder for the CHARACTER SET statement part of CREATE TABLE.
@@ -54,7 +51,7 @@ require_once dirname(__FILE__) . '/IndexTypeBuilder.php';
* @license http://www.debian.org/misc/bsd.license BSD License (3 Clause)
*
*/
class CharacterSetBuilder {
class CharacterSetBuilder implements Builder {
protected function buildConstant($parsed) {
$builder = new ConstantBuilder();
@@ -71,7 +68,7 @@ class CharacterSetBuilder {
return $builder->build($parsed);
}
public function build($parsed) {
public function build(array $parsed) {
if ($parsed['expr_type'] !== ExpressionType::CHARSET) {
return "";
}