hive-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ser...@apache.org
Subject [10/50] [abbrv] hive git commit: HIVE-14671 : merge master into hive-14535 (Wei Zheng)
Date Fri, 13 Oct 2017 00:15:49 GMT
http://git-wip-us.apache.org/repos/asf/hive/blob/42a38577/standalone-metastore/src/gen/thrift/gen-php/metastore/Types.php
----------------------------------------------------------------------
diff --cc standalone-metastore/src/gen/thrift/gen-php/metastore/Types.php
index 0000000,f0f0a57..71c2cef
mode 000000,100644..100644
--- a/standalone-metastore/src/gen/thrift/gen-php/metastore/Types.php
+++ b/standalone-metastore/src/gen/thrift/gen-php/metastore/Types.php
@@@ -1,0 -1,21260 +1,21262 @@@
+ <?php
+ namespace metastore;
+ 
+ /**
+  * Autogenerated by Thrift Compiler (0.9.3)
+  *
+  * DO NOT EDIT UNLESS YOU ARE SURE THAT YOU KNOW WHAT YOU ARE DOING
+  *  @generated
+  */
+ use Thrift\Base\TBase;
+ use Thrift\Type\TType;
+ use Thrift\Type\TMessageType;
+ use Thrift\Exception\TException;
+ use Thrift\Exception\TProtocolException;
+ use Thrift\Protocol\TProtocol;
+ use Thrift\Protocol\TBinaryProtocolAccelerated;
+ use Thrift\Exception\TApplicationException;
+ 
+ 
+ final class HiveObjectType {
+   const GLOBAL = 1;
+   const DATABASE = 2;
+   const TABLE = 3;
+   const PARTITION = 4;
+   const COLUMN = 5;
+   static public $__names = array(
+     1 => 'GLOBAL',
+     2 => 'DATABASE',
+     3 => 'TABLE',
+     4 => 'PARTITION',
+     5 => 'COLUMN',
+   );
+ }
+ 
+ final class PrincipalType {
+   const USER = 1;
+   const ROLE = 2;
+   const GROUP = 3;
+   static public $__names = array(
+     1 => 'USER',
+     2 => 'ROLE',
+     3 => 'GROUP',
+   );
+ }
+ 
+ final class PartitionEventType {
+   const LOAD_DONE = 1;
+   static public $__names = array(
+     1 => 'LOAD_DONE',
+   );
+ }
+ 
+ final class TxnState {
+   const COMMITTED = 1;
+   const ABORTED = 2;
+   const OPEN = 3;
+   static public $__names = array(
+     1 => 'COMMITTED',
+     2 => 'ABORTED',
+     3 => 'OPEN',
+   );
+ }
+ 
+ final class LockLevel {
+   const DB = 1;
+   const TABLE = 2;
+   const PARTITION = 3;
+   static public $__names = array(
+     1 => 'DB',
+     2 => 'TABLE',
+     3 => 'PARTITION',
+   );
+ }
+ 
+ final class LockState {
+   const ACQUIRED = 1;
+   const WAITING = 2;
+   const ABORT = 3;
+   const NOT_ACQUIRED = 4;
+   static public $__names = array(
+     1 => 'ACQUIRED',
+     2 => 'WAITING',
+     3 => 'ABORT',
+     4 => 'NOT_ACQUIRED',
+   );
+ }
+ 
+ final class LockType {
+   const SHARED_READ = 1;
+   const SHARED_WRITE = 2;
+   const EXCLUSIVE = 3;
+   static public $__names = array(
+     1 => 'SHARED_READ',
+     2 => 'SHARED_WRITE',
+     3 => 'EXCLUSIVE',
+   );
+ }
+ 
+ final class CompactionType {
+   const MINOR = 1;
+   const MAJOR = 2;
+   static public $__names = array(
+     1 => 'MINOR',
+     2 => 'MAJOR',
+   );
+ }
+ 
+ final class GrantRevokeType {
+   const GRANT = 1;
+   const REVOKE = 2;
+   static public $__names = array(
+     1 => 'GRANT',
+     2 => 'REVOKE',
+   );
+ }
+ 
+ final class DataOperationType {
+   const SELECT = 1;
+   const INSERT = 2;
+   const UPDATE = 3;
+   const DELETE = 4;
+   const UNSET = 5;
+   const NO_TXN = 6;
+   static public $__names = array(
+     1 => 'SELECT',
+     2 => 'INSERT',
+     3 => 'UPDATE',
+     4 => 'DELETE',
+     5 => 'UNSET',
+     6 => 'NO_TXN',
+   );
+ }
+ 
+ final class EventRequestType {
+   const INSERT = 1;
+   const UPDATE = 2;
+   const DELETE = 3;
+   static public $__names = array(
+     1 => 'INSERT',
+     2 => 'UPDATE',
+     3 => 'DELETE',
+   );
+ }
+ 
+ final class FunctionType {
+   const JAVA = 1;
+   static public $__names = array(
+     1 => 'JAVA',
+   );
+ }
+ 
+ final class ResourceType {
+   const JAR = 1;
+   const FILE = 2;
+   const ARCHIVE = 3;
+   static public $__names = array(
+     1 => 'JAR',
+     2 => 'FILE',
+     3 => 'ARCHIVE',
+   );
+ }
+ 
+ final class FileMetadataExprType {
+   const ORC_SARG = 1;
+   static public $__names = array(
+     1 => 'ORC_SARG',
+   );
+ }
+ 
+ final class ClientCapability {
+   const TEST_CAPABILITY = 1;
++  const INSERT_ONLY_TABLES = 2;
+   static public $__names = array(
+     1 => 'TEST_CAPABILITY',
++    2 => 'INSERT_ONLY_TABLES',
+   );
+ }
+ 
+ class Version {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $version = null;
+   /**
+    * @var string
+    */
+   public $comments = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'version',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'comments',
+           'type' => TType::STRING,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['version'])) {
+         $this->version = $vals['version'];
+       }
+       if (isset($vals['comments'])) {
+         $this->comments = $vals['comments'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'Version';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->version);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->comments);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('Version');
+     if ($this->version !== null) {
+       $xfer += $output->writeFieldBegin('version', TType::STRING, 1);
+       $xfer += $output->writeString($this->version);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->comments !== null) {
+       $xfer += $output->writeFieldBegin('comments', TType::STRING, 2);
+       $xfer += $output->writeString($this->comments);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class FieldSchema {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $name = null;
+   /**
+    * @var string
+    */
+   public $type = null;
+   /**
+    * @var string
+    */
+   public $comment = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'name',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'type',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'comment',
+           'type' => TType::STRING,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['name'])) {
+         $this->name = $vals['name'];
+       }
+       if (isset($vals['type'])) {
+         $this->type = $vals['type'];
+       }
+       if (isset($vals['comment'])) {
+         $this->comment = $vals['comment'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'FieldSchema';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->type);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->comment);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('FieldSchema');
+     if ($this->name !== null) {
+       $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
+       $xfer += $output->writeString($this->name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->type !== null) {
+       $xfer += $output->writeFieldBegin('type', TType::STRING, 2);
+       $xfer += $output->writeString($this->type);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->comment !== null) {
+       $xfer += $output->writeFieldBegin('comment', TType::STRING, 3);
+       $xfer += $output->writeString($this->comment);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class SQLPrimaryKey {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $table_db = null;
+   /**
+    * @var string
+    */
+   public $table_name = null;
+   /**
+    * @var string
+    */
+   public $column_name = null;
+   /**
+    * @var int
+    */
+   public $key_seq = null;
+   /**
+    * @var string
+    */
+   public $pk_name = null;
+   /**
+    * @var bool
+    */
+   public $enable_cstr = null;
+   /**
+    * @var bool
+    */
+   public $validate_cstr = null;
+   /**
+    * @var bool
+    */
+   public $rely_cstr = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'table_db',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'table_name',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'column_name',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'key_seq',
+           'type' => TType::I32,
+           ),
+         5 => array(
+           'var' => 'pk_name',
+           'type' => TType::STRING,
+           ),
+         6 => array(
+           'var' => 'enable_cstr',
+           'type' => TType::BOOL,
+           ),
+         7 => array(
+           'var' => 'validate_cstr',
+           'type' => TType::BOOL,
+           ),
+         8 => array(
+           'var' => 'rely_cstr',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['table_db'])) {
+         $this->table_db = $vals['table_db'];
+       }
+       if (isset($vals['table_name'])) {
+         $this->table_name = $vals['table_name'];
+       }
+       if (isset($vals['column_name'])) {
+         $this->column_name = $vals['column_name'];
+       }
+       if (isset($vals['key_seq'])) {
+         $this->key_seq = $vals['key_seq'];
+       }
+       if (isset($vals['pk_name'])) {
+         $this->pk_name = $vals['pk_name'];
+       }
+       if (isset($vals['enable_cstr'])) {
+         $this->enable_cstr = $vals['enable_cstr'];
+       }
+       if (isset($vals['validate_cstr'])) {
+         $this->validate_cstr = $vals['validate_cstr'];
+       }
+       if (isset($vals['rely_cstr'])) {
+         $this->rely_cstr = $vals['rely_cstr'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'SQLPrimaryKey';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_db);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->column_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->key_seq);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->pk_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 6:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->enable_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 7:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->validate_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 8:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->rely_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('SQLPrimaryKey');
+     if ($this->table_db !== null) {
+       $xfer += $output->writeFieldBegin('table_db', TType::STRING, 1);
+       $xfer += $output->writeString($this->table_db);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->table_name !== null) {
+       $xfer += $output->writeFieldBegin('table_name', TType::STRING, 2);
+       $xfer += $output->writeString($this->table_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->column_name !== null) {
+       $xfer += $output->writeFieldBegin('column_name', TType::STRING, 3);
+       $xfer += $output->writeString($this->column_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->key_seq !== null) {
+       $xfer += $output->writeFieldBegin('key_seq', TType::I32, 4);
+       $xfer += $output->writeI32($this->key_seq);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->pk_name !== null) {
+       $xfer += $output->writeFieldBegin('pk_name', TType::STRING, 5);
+       $xfer += $output->writeString($this->pk_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->enable_cstr !== null) {
+       $xfer += $output->writeFieldBegin('enable_cstr', TType::BOOL, 6);
+       $xfer += $output->writeBool($this->enable_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->validate_cstr !== null) {
+       $xfer += $output->writeFieldBegin('validate_cstr', TType::BOOL, 7);
+       $xfer += $output->writeBool($this->validate_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->rely_cstr !== null) {
+       $xfer += $output->writeFieldBegin('rely_cstr', TType::BOOL, 8);
+       $xfer += $output->writeBool($this->rely_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class SQLForeignKey {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $pktable_db = null;
+   /**
+    * @var string
+    */
+   public $pktable_name = null;
+   /**
+    * @var string
+    */
+   public $pkcolumn_name = null;
+   /**
+    * @var string
+    */
+   public $fktable_db = null;
+   /**
+    * @var string
+    */
+   public $fktable_name = null;
+   /**
+    * @var string
+    */
+   public $fkcolumn_name = null;
+   /**
+    * @var int
+    */
+   public $key_seq = null;
+   /**
+    * @var int
+    */
+   public $update_rule = null;
+   /**
+    * @var int
+    */
+   public $delete_rule = null;
+   /**
+    * @var string
+    */
+   public $fk_name = null;
+   /**
+    * @var string
+    */
+   public $pk_name = null;
+   /**
+    * @var bool
+    */
+   public $enable_cstr = null;
+   /**
+    * @var bool
+    */
+   public $validate_cstr = null;
+   /**
+    * @var bool
+    */
+   public $rely_cstr = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'pktable_db',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'pktable_name',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'pkcolumn_name',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'fktable_db',
+           'type' => TType::STRING,
+           ),
+         5 => array(
+           'var' => 'fktable_name',
+           'type' => TType::STRING,
+           ),
+         6 => array(
+           'var' => 'fkcolumn_name',
+           'type' => TType::STRING,
+           ),
+         7 => array(
+           'var' => 'key_seq',
+           'type' => TType::I32,
+           ),
+         8 => array(
+           'var' => 'update_rule',
+           'type' => TType::I32,
+           ),
+         9 => array(
+           'var' => 'delete_rule',
+           'type' => TType::I32,
+           ),
+         10 => array(
+           'var' => 'fk_name',
+           'type' => TType::STRING,
+           ),
+         11 => array(
+           'var' => 'pk_name',
+           'type' => TType::STRING,
+           ),
+         12 => array(
+           'var' => 'enable_cstr',
+           'type' => TType::BOOL,
+           ),
+         13 => array(
+           'var' => 'validate_cstr',
+           'type' => TType::BOOL,
+           ),
+         14 => array(
+           'var' => 'rely_cstr',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['pktable_db'])) {
+         $this->pktable_db = $vals['pktable_db'];
+       }
+       if (isset($vals['pktable_name'])) {
+         $this->pktable_name = $vals['pktable_name'];
+       }
+       if (isset($vals['pkcolumn_name'])) {
+         $this->pkcolumn_name = $vals['pkcolumn_name'];
+       }
+       if (isset($vals['fktable_db'])) {
+         $this->fktable_db = $vals['fktable_db'];
+       }
+       if (isset($vals['fktable_name'])) {
+         $this->fktable_name = $vals['fktable_name'];
+       }
+       if (isset($vals['fkcolumn_name'])) {
+         $this->fkcolumn_name = $vals['fkcolumn_name'];
+       }
+       if (isset($vals['key_seq'])) {
+         $this->key_seq = $vals['key_seq'];
+       }
+       if (isset($vals['update_rule'])) {
+         $this->update_rule = $vals['update_rule'];
+       }
+       if (isset($vals['delete_rule'])) {
+         $this->delete_rule = $vals['delete_rule'];
+       }
+       if (isset($vals['fk_name'])) {
+         $this->fk_name = $vals['fk_name'];
+       }
+       if (isset($vals['pk_name'])) {
+         $this->pk_name = $vals['pk_name'];
+       }
+       if (isset($vals['enable_cstr'])) {
+         $this->enable_cstr = $vals['enable_cstr'];
+       }
+       if (isset($vals['validate_cstr'])) {
+         $this->validate_cstr = $vals['validate_cstr'];
+       }
+       if (isset($vals['rely_cstr'])) {
+         $this->rely_cstr = $vals['rely_cstr'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'SQLForeignKey';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->pktable_db);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->pktable_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->pkcolumn_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->fktable_db);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->fktable_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 6:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->fkcolumn_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 7:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->key_seq);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 8:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->update_rule);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 9:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->delete_rule);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 10:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->fk_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 11:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->pk_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 12:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->enable_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 13:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->validate_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 14:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->rely_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('SQLForeignKey');
+     if ($this->pktable_db !== null) {
+       $xfer += $output->writeFieldBegin('pktable_db', TType::STRING, 1);
+       $xfer += $output->writeString($this->pktable_db);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->pktable_name !== null) {
+       $xfer += $output->writeFieldBegin('pktable_name', TType::STRING, 2);
+       $xfer += $output->writeString($this->pktable_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->pkcolumn_name !== null) {
+       $xfer += $output->writeFieldBegin('pkcolumn_name', TType::STRING, 3);
+       $xfer += $output->writeString($this->pkcolumn_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->fktable_db !== null) {
+       $xfer += $output->writeFieldBegin('fktable_db', TType::STRING, 4);
+       $xfer += $output->writeString($this->fktable_db);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->fktable_name !== null) {
+       $xfer += $output->writeFieldBegin('fktable_name', TType::STRING, 5);
+       $xfer += $output->writeString($this->fktable_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->fkcolumn_name !== null) {
+       $xfer += $output->writeFieldBegin('fkcolumn_name', TType::STRING, 6);
+       $xfer += $output->writeString($this->fkcolumn_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->key_seq !== null) {
+       $xfer += $output->writeFieldBegin('key_seq', TType::I32, 7);
+       $xfer += $output->writeI32($this->key_seq);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->update_rule !== null) {
+       $xfer += $output->writeFieldBegin('update_rule', TType::I32, 8);
+       $xfer += $output->writeI32($this->update_rule);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->delete_rule !== null) {
+       $xfer += $output->writeFieldBegin('delete_rule', TType::I32, 9);
+       $xfer += $output->writeI32($this->delete_rule);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->fk_name !== null) {
+       $xfer += $output->writeFieldBegin('fk_name', TType::STRING, 10);
+       $xfer += $output->writeString($this->fk_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->pk_name !== null) {
+       $xfer += $output->writeFieldBegin('pk_name', TType::STRING, 11);
+       $xfer += $output->writeString($this->pk_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->enable_cstr !== null) {
+       $xfer += $output->writeFieldBegin('enable_cstr', TType::BOOL, 12);
+       $xfer += $output->writeBool($this->enable_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->validate_cstr !== null) {
+       $xfer += $output->writeFieldBegin('validate_cstr', TType::BOOL, 13);
+       $xfer += $output->writeBool($this->validate_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->rely_cstr !== null) {
+       $xfer += $output->writeFieldBegin('rely_cstr', TType::BOOL, 14);
+       $xfer += $output->writeBool($this->rely_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class SQLUniqueConstraint {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $table_db = null;
+   /**
+    * @var string
+    */
+   public $table_name = null;
+   /**
+    * @var string
+    */
+   public $column_name = null;
+   /**
+    * @var int
+    */
+   public $key_seq = null;
+   /**
+    * @var string
+    */
+   public $uk_name = null;
+   /**
+    * @var bool
+    */
+   public $enable_cstr = null;
+   /**
+    * @var bool
+    */
+   public $validate_cstr = null;
+   /**
+    * @var bool
+    */
+   public $rely_cstr = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'table_db',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'table_name',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'column_name',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'key_seq',
+           'type' => TType::I32,
+           ),
+         5 => array(
+           'var' => 'uk_name',
+           'type' => TType::STRING,
+           ),
+         6 => array(
+           'var' => 'enable_cstr',
+           'type' => TType::BOOL,
+           ),
+         7 => array(
+           'var' => 'validate_cstr',
+           'type' => TType::BOOL,
+           ),
+         8 => array(
+           'var' => 'rely_cstr',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['table_db'])) {
+         $this->table_db = $vals['table_db'];
+       }
+       if (isset($vals['table_name'])) {
+         $this->table_name = $vals['table_name'];
+       }
+       if (isset($vals['column_name'])) {
+         $this->column_name = $vals['column_name'];
+       }
+       if (isset($vals['key_seq'])) {
+         $this->key_seq = $vals['key_seq'];
+       }
+       if (isset($vals['uk_name'])) {
+         $this->uk_name = $vals['uk_name'];
+       }
+       if (isset($vals['enable_cstr'])) {
+         $this->enable_cstr = $vals['enable_cstr'];
+       }
+       if (isset($vals['validate_cstr'])) {
+         $this->validate_cstr = $vals['validate_cstr'];
+       }
+       if (isset($vals['rely_cstr'])) {
+         $this->rely_cstr = $vals['rely_cstr'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'SQLUniqueConstraint';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_db);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->column_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->key_seq);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->uk_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 6:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->enable_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 7:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->validate_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 8:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->rely_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('SQLUniqueConstraint');
+     if ($this->table_db !== null) {
+       $xfer += $output->writeFieldBegin('table_db', TType::STRING, 1);
+       $xfer += $output->writeString($this->table_db);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->table_name !== null) {
+       $xfer += $output->writeFieldBegin('table_name', TType::STRING, 2);
+       $xfer += $output->writeString($this->table_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->column_name !== null) {
+       $xfer += $output->writeFieldBegin('column_name', TType::STRING, 3);
+       $xfer += $output->writeString($this->column_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->key_seq !== null) {
+       $xfer += $output->writeFieldBegin('key_seq', TType::I32, 4);
+       $xfer += $output->writeI32($this->key_seq);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->uk_name !== null) {
+       $xfer += $output->writeFieldBegin('uk_name', TType::STRING, 5);
+       $xfer += $output->writeString($this->uk_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->enable_cstr !== null) {
+       $xfer += $output->writeFieldBegin('enable_cstr', TType::BOOL, 6);
+       $xfer += $output->writeBool($this->enable_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->validate_cstr !== null) {
+       $xfer += $output->writeFieldBegin('validate_cstr', TType::BOOL, 7);
+       $xfer += $output->writeBool($this->validate_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->rely_cstr !== null) {
+       $xfer += $output->writeFieldBegin('rely_cstr', TType::BOOL, 8);
+       $xfer += $output->writeBool($this->rely_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class SQLNotNullConstraint {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $table_db = null;
+   /**
+    * @var string
+    */
+   public $table_name = null;
+   /**
+    * @var string
+    */
+   public $column_name = null;
+   /**
+    * @var string
+    */
+   public $nn_name = null;
+   /**
+    * @var bool
+    */
+   public $enable_cstr = null;
+   /**
+    * @var bool
+    */
+   public $validate_cstr = null;
+   /**
+    * @var bool
+    */
+   public $rely_cstr = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'table_db',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'table_name',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'column_name',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'nn_name',
+           'type' => TType::STRING,
+           ),
+         5 => array(
+           'var' => 'enable_cstr',
+           'type' => TType::BOOL,
+           ),
+         6 => array(
+           'var' => 'validate_cstr',
+           'type' => TType::BOOL,
+           ),
+         7 => array(
+           'var' => 'rely_cstr',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['table_db'])) {
+         $this->table_db = $vals['table_db'];
+       }
+       if (isset($vals['table_name'])) {
+         $this->table_name = $vals['table_name'];
+       }
+       if (isset($vals['column_name'])) {
+         $this->column_name = $vals['column_name'];
+       }
+       if (isset($vals['nn_name'])) {
+         $this->nn_name = $vals['nn_name'];
+       }
+       if (isset($vals['enable_cstr'])) {
+         $this->enable_cstr = $vals['enable_cstr'];
+       }
+       if (isset($vals['validate_cstr'])) {
+         $this->validate_cstr = $vals['validate_cstr'];
+       }
+       if (isset($vals['rely_cstr'])) {
+         $this->rely_cstr = $vals['rely_cstr'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'SQLNotNullConstraint';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_db);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->table_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->column_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->nn_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->enable_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 6:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->validate_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 7:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->rely_cstr);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('SQLNotNullConstraint');
+     if ($this->table_db !== null) {
+       $xfer += $output->writeFieldBegin('table_db', TType::STRING, 1);
+       $xfer += $output->writeString($this->table_db);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->table_name !== null) {
+       $xfer += $output->writeFieldBegin('table_name', TType::STRING, 2);
+       $xfer += $output->writeString($this->table_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->column_name !== null) {
+       $xfer += $output->writeFieldBegin('column_name', TType::STRING, 3);
+       $xfer += $output->writeString($this->column_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->nn_name !== null) {
+       $xfer += $output->writeFieldBegin('nn_name', TType::STRING, 4);
+       $xfer += $output->writeString($this->nn_name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->enable_cstr !== null) {
+       $xfer += $output->writeFieldBegin('enable_cstr', TType::BOOL, 5);
+       $xfer += $output->writeBool($this->enable_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->validate_cstr !== null) {
+       $xfer += $output->writeFieldBegin('validate_cstr', TType::BOOL, 6);
+       $xfer += $output->writeBool($this->validate_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->rely_cstr !== null) {
+       $xfer += $output->writeFieldBegin('rely_cstr', TType::BOOL, 7);
+       $xfer += $output->writeBool($this->rely_cstr);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class Type {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $name = null;
+   /**
+    * @var string
+    */
+   public $type1 = null;
+   /**
+    * @var string
+    */
+   public $type2 = null;
+   /**
+    * @var \metastore\FieldSchema[]
+    */
+   public $fields = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'name',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'type1',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'type2',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'fields',
+           'type' => TType::LST,
+           'etype' => TType::STRUCT,
+           'elem' => array(
+             'type' => TType::STRUCT,
+             'class' => '\metastore\FieldSchema',
+             ),
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['name'])) {
+         $this->name = $vals['name'];
+       }
+       if (isset($vals['type1'])) {
+         $this->type1 = $vals['type1'];
+       }
+       if (isset($vals['type2'])) {
+         $this->type2 = $vals['type2'];
+       }
+       if (isset($vals['fields'])) {
+         $this->fields = $vals['fields'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'Type';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->type1);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->type2);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::LST) {
+             $this->fields = array();
+             $_size0 = 0;
+             $_etype3 = 0;
+             $xfer += $input->readListBegin($_etype3, $_size0);
+             for ($_i4 = 0; $_i4 < $_size0; ++$_i4)
+             {
+               $elem5 = null;
+               $elem5 = new \metastore\FieldSchema();
+               $xfer += $elem5->read($input);
+               $this->fields []= $elem5;
+             }
+             $xfer += $input->readListEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('Type');
+     if ($this->name !== null) {
+       $xfer += $output->writeFieldBegin('name', TType::STRING, 1);
+       $xfer += $output->writeString($this->name);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->type1 !== null) {
+       $xfer += $output->writeFieldBegin('type1', TType::STRING, 2);
+       $xfer += $output->writeString($this->type1);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->type2 !== null) {
+       $xfer += $output->writeFieldBegin('type2', TType::STRING, 3);
+       $xfer += $output->writeString($this->type2);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->fields !== null) {
+       if (!is_array($this->fields)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('fields', TType::LST, 4);
+       {
+         $output->writeListBegin(TType::STRUCT, count($this->fields));
+         {
+           foreach ($this->fields as $iter6)
+           {
+             $xfer += $iter6->write($output);
+           }
+         }
+         $output->writeListEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class HiveObjectRef {
+   static $_TSPEC;
+ 
+   /**
+    * @var int
+    */
+   public $objectType = null;
+   /**
+    * @var string
+    */
+   public $dbName = null;
+   /**
+    * @var string
+    */
+   public $objectName = null;
+   /**
+    * @var string[]
+    */
+   public $partValues = null;
+   /**
+    * @var string
+    */
+   public $columnName = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'objectType',
+           'type' => TType::I32,
+           ),
+         2 => array(
+           'var' => 'dbName',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'objectName',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'partValues',
+           'type' => TType::LST,
+           'etype' => TType::STRING,
+           'elem' => array(
+             'type' => TType::STRING,
+             ),
+           ),
+         5 => array(
+           'var' => 'columnName',
+           'type' => TType::STRING,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['objectType'])) {
+         $this->objectType = $vals['objectType'];
+       }
+       if (isset($vals['dbName'])) {
+         $this->dbName = $vals['dbName'];
+       }
+       if (isset($vals['objectName'])) {
+         $this->objectName = $vals['objectName'];
+       }
+       if (isset($vals['partValues'])) {
+         $this->partValues = $vals['partValues'];
+       }
+       if (isset($vals['columnName'])) {
+         $this->columnName = $vals['columnName'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'HiveObjectRef';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->objectType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->dbName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->objectName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::LST) {
+             $this->partValues = array();
+             $_size7 = 0;
+             $_etype10 = 0;
+             $xfer += $input->readListBegin($_etype10, $_size7);
+             for ($_i11 = 0; $_i11 < $_size7; ++$_i11)
+             {
+               $elem12 = null;
+               $xfer += $input->readString($elem12);
+               $this->partValues []= $elem12;
+             }
+             $xfer += $input->readListEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->columnName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('HiveObjectRef');
+     if ($this->objectType !== null) {
+       $xfer += $output->writeFieldBegin('objectType', TType::I32, 1);
+       $xfer += $output->writeI32($this->objectType);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->dbName !== null) {
+       $xfer += $output->writeFieldBegin('dbName', TType::STRING, 2);
+       $xfer += $output->writeString($this->dbName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->objectName !== null) {
+       $xfer += $output->writeFieldBegin('objectName', TType::STRING, 3);
+       $xfer += $output->writeString($this->objectName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->partValues !== null) {
+       if (!is_array($this->partValues)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('partValues', TType::LST, 4);
+       {
+         $output->writeListBegin(TType::STRING, count($this->partValues));
+         {
+           foreach ($this->partValues as $iter13)
+           {
+             $xfer += $output->writeString($iter13);
+           }
+         }
+         $output->writeListEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->columnName !== null) {
+       $xfer += $output->writeFieldBegin('columnName', TType::STRING, 5);
+       $xfer += $output->writeString($this->columnName);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class PrivilegeGrantInfo {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $privilege = null;
+   /**
+    * @var int
+    */
+   public $createTime = null;
+   /**
+    * @var string
+    */
+   public $grantor = null;
+   /**
+    * @var int
+    */
+   public $grantorType = null;
+   /**
+    * @var bool
+    */
+   public $grantOption = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'privilege',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'createTime',
+           'type' => TType::I32,
+           ),
+         3 => array(
+           'var' => 'grantor',
+           'type' => TType::STRING,
+           ),
+         4 => array(
+           'var' => 'grantorType',
+           'type' => TType::I32,
+           ),
+         5 => array(
+           'var' => 'grantOption',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['privilege'])) {
+         $this->privilege = $vals['privilege'];
+       }
+       if (isset($vals['createTime'])) {
+         $this->createTime = $vals['createTime'];
+       }
+       if (isset($vals['grantor'])) {
+         $this->grantor = $vals['grantor'];
+       }
+       if (isset($vals['grantorType'])) {
+         $this->grantorType = $vals['grantorType'];
+       }
+       if (isset($vals['grantOption'])) {
+         $this->grantOption = $vals['grantOption'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'PrivilegeGrantInfo';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->privilege);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->createTime);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->grantor);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->grantorType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->grantOption);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('PrivilegeGrantInfo');
+     if ($this->privilege !== null) {
+       $xfer += $output->writeFieldBegin('privilege', TType::STRING, 1);
+       $xfer += $output->writeString($this->privilege);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->createTime !== null) {
+       $xfer += $output->writeFieldBegin('createTime', TType::I32, 2);
+       $xfer += $output->writeI32($this->createTime);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantor !== null) {
+       $xfer += $output->writeFieldBegin('grantor', TType::STRING, 3);
+       $xfer += $output->writeString($this->grantor);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantorType !== null) {
+       $xfer += $output->writeFieldBegin('grantorType', TType::I32, 4);
+       $xfer += $output->writeI32($this->grantorType);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantOption !== null) {
+       $xfer += $output->writeFieldBegin('grantOption', TType::BOOL, 5);
+       $xfer += $output->writeBool($this->grantOption);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class HiveObjectPrivilege {
+   static $_TSPEC;
+ 
+   /**
+    * @var \metastore\HiveObjectRef
+    */
+   public $hiveObject = null;
+   /**
+    * @var string
+    */
+   public $principalName = null;
+   /**
+    * @var int
+    */
+   public $principalType = null;
+   /**
+    * @var \metastore\PrivilegeGrantInfo
+    */
+   public $grantInfo = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'hiveObject',
+           'type' => TType::STRUCT,
+           'class' => '\metastore\HiveObjectRef',
+           ),
+         2 => array(
+           'var' => 'principalName',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'principalType',
+           'type' => TType::I32,
+           ),
+         4 => array(
+           'var' => 'grantInfo',
+           'type' => TType::STRUCT,
+           'class' => '\metastore\PrivilegeGrantInfo',
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['hiveObject'])) {
+         $this->hiveObject = $vals['hiveObject'];
+       }
+       if (isset($vals['principalName'])) {
+         $this->principalName = $vals['principalName'];
+       }
+       if (isset($vals['principalType'])) {
+         $this->principalType = $vals['principalType'];
+       }
+       if (isset($vals['grantInfo'])) {
+         $this->grantInfo = $vals['grantInfo'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'HiveObjectPrivilege';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRUCT) {
+             $this->hiveObject = new \metastore\HiveObjectRef();
+             $xfer += $this->hiveObject->read($input);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->principalName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->principalType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::STRUCT) {
+             $this->grantInfo = new \metastore\PrivilegeGrantInfo();
+             $xfer += $this->grantInfo->read($input);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('HiveObjectPrivilege');
+     if ($this->hiveObject !== null) {
+       if (!is_object($this->hiveObject)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('hiveObject', TType::STRUCT, 1);
+       $xfer += $this->hiveObject->write($output);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->principalName !== null) {
+       $xfer += $output->writeFieldBegin('principalName', TType::STRING, 2);
+       $xfer += $output->writeString($this->principalName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->principalType !== null) {
+       $xfer += $output->writeFieldBegin('principalType', TType::I32, 3);
+       $xfer += $output->writeI32($this->principalType);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantInfo !== null) {
+       if (!is_object($this->grantInfo)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('grantInfo', TType::STRUCT, 4);
+       $xfer += $this->grantInfo->write($output);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class PrivilegeBag {
+   static $_TSPEC;
+ 
+   /**
+    * @var \metastore\HiveObjectPrivilege[]
+    */
+   public $privileges = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'privileges',
+           'type' => TType::LST,
+           'etype' => TType::STRUCT,
+           'elem' => array(
+             'type' => TType::STRUCT,
+             'class' => '\metastore\HiveObjectPrivilege',
+             ),
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['privileges'])) {
+         $this->privileges = $vals['privileges'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'PrivilegeBag';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::LST) {
+             $this->privileges = array();
+             $_size14 = 0;
+             $_etype17 = 0;
+             $xfer += $input->readListBegin($_etype17, $_size14);
+             for ($_i18 = 0; $_i18 < $_size14; ++$_i18)
+             {
+               $elem19 = null;
+               $elem19 = new \metastore\HiveObjectPrivilege();
+               $xfer += $elem19->read($input);
+               $this->privileges []= $elem19;
+             }
+             $xfer += $input->readListEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('PrivilegeBag');
+     if ($this->privileges !== null) {
+       if (!is_array($this->privileges)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('privileges', TType::LST, 1);
+       {
+         $output->writeListBegin(TType::STRUCT, count($this->privileges));
+         {
+           foreach ($this->privileges as $iter20)
+           {
+             $xfer += $iter20->write($output);
+           }
+         }
+         $output->writeListEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class PrincipalPrivilegeSet {
+   static $_TSPEC;
+ 
+   /**
+    * @var array
+    */
+   public $userPrivileges = null;
+   /**
+    * @var array
+    */
+   public $groupPrivileges = null;
+   /**
+    * @var array
+    */
+   public $rolePrivileges = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'userPrivileges',
+           'type' => TType::MAP,
+           'ktype' => TType::STRING,
+           'vtype' => TType::LST,
+           'key' => array(
+             'type' => TType::STRING,
+           ),
+           'val' => array(
+             'type' => TType::LST,
+             'etype' => TType::STRUCT,
+             'elem' => array(
+               'type' => TType::STRUCT,
+               'class' => '\metastore\PrivilegeGrantInfo',
+               ),
+             ),
+           ),
+         2 => array(
+           'var' => 'groupPrivileges',
+           'type' => TType::MAP,
+           'ktype' => TType::STRING,
+           'vtype' => TType::LST,
+           'key' => array(
+             'type' => TType::STRING,
+           ),
+           'val' => array(
+             'type' => TType::LST,
+             'etype' => TType::STRUCT,
+             'elem' => array(
+               'type' => TType::STRUCT,
+               'class' => '\metastore\PrivilegeGrantInfo',
+               ),
+             ),
+           ),
+         3 => array(
+           'var' => 'rolePrivileges',
+           'type' => TType::MAP,
+           'ktype' => TType::STRING,
+           'vtype' => TType::LST,
+           'key' => array(
+             'type' => TType::STRING,
+           ),
+           'val' => array(
+             'type' => TType::LST,
+             'etype' => TType::STRUCT,
+             'elem' => array(
+               'type' => TType::STRUCT,
+               'class' => '\metastore\PrivilegeGrantInfo',
+               ),
+             ),
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['userPrivileges'])) {
+         $this->userPrivileges = $vals['userPrivileges'];
+       }
+       if (isset($vals['groupPrivileges'])) {
+         $this->groupPrivileges = $vals['groupPrivileges'];
+       }
+       if (isset($vals['rolePrivileges'])) {
+         $this->rolePrivileges = $vals['rolePrivileges'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'PrincipalPrivilegeSet';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::MAP) {
+             $this->userPrivileges = array();
+             $_size21 = 0;
+             $_ktype22 = 0;
+             $_vtype23 = 0;
+             $xfer += $input->readMapBegin($_ktype22, $_vtype23, $_size21);
+             for ($_i25 = 0; $_i25 < $_size21; ++$_i25)
+             {
+               $key26 = '';
+               $val27 = array();
+               $xfer += $input->readString($key26);
+               $val27 = array();
+               $_size28 = 0;
+               $_etype31 = 0;
+               $xfer += $input->readListBegin($_etype31, $_size28);
+               for ($_i32 = 0; $_i32 < $_size28; ++$_i32)
+               {
+                 $elem33 = null;
+                 $elem33 = new \metastore\PrivilegeGrantInfo();
+                 $xfer += $elem33->read($input);
+                 $val27 []= $elem33;
+               }
+               $xfer += $input->readListEnd();
+               $this->userPrivileges[$key26] = $val27;
+             }
+             $xfer += $input->readMapEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::MAP) {
+             $this->groupPrivileges = array();
+             $_size34 = 0;
+             $_ktype35 = 0;
+             $_vtype36 = 0;
+             $xfer += $input->readMapBegin($_ktype35, $_vtype36, $_size34);
+             for ($_i38 = 0; $_i38 < $_size34; ++$_i38)
+             {
+               $key39 = '';
+               $val40 = array();
+               $xfer += $input->readString($key39);
+               $val40 = array();
+               $_size41 = 0;
+               $_etype44 = 0;
+               $xfer += $input->readListBegin($_etype44, $_size41);
+               for ($_i45 = 0; $_i45 < $_size41; ++$_i45)
+               {
+                 $elem46 = null;
+                 $elem46 = new \metastore\PrivilegeGrantInfo();
+                 $xfer += $elem46->read($input);
+                 $val40 []= $elem46;
+               }
+               $xfer += $input->readListEnd();
+               $this->groupPrivileges[$key39] = $val40;
+             }
+             $xfer += $input->readMapEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::MAP) {
+             $this->rolePrivileges = array();
+             $_size47 = 0;
+             $_ktype48 = 0;
+             $_vtype49 = 0;
+             $xfer += $input->readMapBegin($_ktype48, $_vtype49, $_size47);
+             for ($_i51 = 0; $_i51 < $_size47; ++$_i51)
+             {
+               $key52 = '';
+               $val53 = array();
+               $xfer += $input->readString($key52);
+               $val53 = array();
+               $_size54 = 0;
+               $_etype57 = 0;
+               $xfer += $input->readListBegin($_etype57, $_size54);
+               for ($_i58 = 0; $_i58 < $_size54; ++$_i58)
+               {
+                 $elem59 = null;
+                 $elem59 = new \metastore\PrivilegeGrantInfo();
+                 $xfer += $elem59->read($input);
+                 $val53 []= $elem59;
+               }
+               $xfer += $input->readListEnd();
+               $this->rolePrivileges[$key52] = $val53;
+             }
+             $xfer += $input->readMapEnd();
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('PrincipalPrivilegeSet');
+     if ($this->userPrivileges !== null) {
+       if (!is_array($this->userPrivileges)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('userPrivileges', TType::MAP, 1);
+       {
+         $output->writeMapBegin(TType::STRING, TType::LST, count($this->userPrivileges));
+         {
+           foreach ($this->userPrivileges as $kiter60 => $viter61)
+           {
+             $xfer += $output->writeString($kiter60);
+             {
+               $output->writeListBegin(TType::STRUCT, count($viter61));
+               {
+                 foreach ($viter61 as $iter62)
+                 {
+                   $xfer += $iter62->write($output);
+                 }
+               }
+               $output->writeListEnd();
+             }
+           }
+         }
+         $output->writeMapEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->groupPrivileges !== null) {
+       if (!is_array($this->groupPrivileges)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('groupPrivileges', TType::MAP, 2);
+       {
+         $output->writeMapBegin(TType::STRING, TType::LST, count($this->groupPrivileges));
+         {
+           foreach ($this->groupPrivileges as $kiter63 => $viter64)
+           {
+             $xfer += $output->writeString($kiter63);
+             {
+               $output->writeListBegin(TType::STRUCT, count($viter64));
+               {
+                 foreach ($viter64 as $iter65)
+                 {
+                   $xfer += $iter65->write($output);
+                 }
+               }
+               $output->writeListEnd();
+             }
+           }
+         }
+         $output->writeMapEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->rolePrivileges !== null) {
+       if (!is_array($this->rolePrivileges)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('rolePrivileges', TType::MAP, 3);
+       {
+         $output->writeMapBegin(TType::STRING, TType::LST, count($this->rolePrivileges));
+         {
+           foreach ($this->rolePrivileges as $kiter66 => $viter67)
+           {
+             $xfer += $output->writeString($kiter66);
+             {
+               $output->writeListBegin(TType::STRUCT, count($viter67));
+               {
+                 foreach ($viter67 as $iter68)
+                 {
+                   $xfer += $iter68->write($output);
+                 }
+               }
+               $output->writeListEnd();
+             }
+           }
+         }
+         $output->writeMapEnd();
+       }
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class GrantRevokePrivilegeRequest {
+   static $_TSPEC;
+ 
+   /**
+    * @var int
+    */
+   public $requestType = null;
+   /**
+    * @var \metastore\PrivilegeBag
+    */
+   public $privileges = null;
+   /**
+    * @var bool
+    */
+   public $revokeGrantOption = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'requestType',
+           'type' => TType::I32,
+           ),
+         2 => array(
+           'var' => 'privileges',
+           'type' => TType::STRUCT,
+           'class' => '\metastore\PrivilegeBag',
+           ),
+         3 => array(
+           'var' => 'revokeGrantOption',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['requestType'])) {
+         $this->requestType = $vals['requestType'];
+       }
+       if (isset($vals['privileges'])) {
+         $this->privileges = $vals['privileges'];
+       }
+       if (isset($vals['revokeGrantOption'])) {
+         $this->revokeGrantOption = $vals['revokeGrantOption'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'GrantRevokePrivilegeRequest';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->requestType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRUCT) {
+             $this->privileges = new \metastore\PrivilegeBag();
+             $xfer += $this->privileges->read($input);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->revokeGrantOption);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('GrantRevokePrivilegeRequest');
+     if ($this->requestType !== null) {
+       $xfer += $output->writeFieldBegin('requestType', TType::I32, 1);
+       $xfer += $output->writeI32($this->requestType);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->privileges !== null) {
+       if (!is_object($this->privileges)) {
+         throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
+       }
+       $xfer += $output->writeFieldBegin('privileges', TType::STRUCT, 2);
+       $xfer += $this->privileges->write($output);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->revokeGrantOption !== null) {
+       $xfer += $output->writeFieldBegin('revokeGrantOption', TType::BOOL, 3);
+       $xfer += $output->writeBool($this->revokeGrantOption);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class GrantRevokePrivilegeResponse {
+   static $_TSPEC;
+ 
+   /**
+    * @var bool
+    */
+   public $success = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'success',
+           'type' => TType::BOOL,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['success'])) {
+         $this->success = $vals['success'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'GrantRevokePrivilegeResponse';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->success);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('GrantRevokePrivilegeResponse');
+     if ($this->success !== null) {
+       $xfer += $output->writeFieldBegin('success', TType::BOOL, 1);
+       $xfer += $output->writeBool($this->success);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class Role {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $roleName = null;
+   /**
+    * @var int
+    */
+   public $createTime = null;
+   /**
+    * @var string
+    */
+   public $ownerName = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'roleName',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'createTime',
+           'type' => TType::I32,
+           ),
+         3 => array(
+           'var' => 'ownerName',
+           'type' => TType::STRING,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['roleName'])) {
+         $this->roleName = $vals['roleName'];
+       }
+       if (isset($vals['createTime'])) {
+         $this->createTime = $vals['createTime'];
+       }
+       if (isset($vals['ownerName'])) {
+         $this->ownerName = $vals['ownerName'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'Role';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->roleName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->createTime);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->ownerName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('Role');
+     if ($this->roleName !== null) {
+       $xfer += $output->writeFieldBegin('roleName', TType::STRING, 1);
+       $xfer += $output->writeString($this->roleName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->createTime !== null) {
+       $xfer += $output->writeFieldBegin('createTime', TType::I32, 2);
+       $xfer += $output->writeI32($this->createTime);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->ownerName !== null) {
+       $xfer += $output->writeFieldBegin('ownerName', TType::STRING, 3);
+       $xfer += $output->writeString($this->ownerName);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class RolePrincipalGrant {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $roleName = null;
+   /**
+    * @var string
+    */
+   public $principalName = null;
+   /**
+    * @var int
+    */
+   public $principalType = null;
+   /**
+    * @var bool
+    */
+   public $grantOption = null;
+   /**
+    * @var int
+    */
+   public $grantTime = null;
+   /**
+    * @var string
+    */
+   public $grantorName = null;
+   /**
+    * @var int
+    */
+   public $grantorPrincipalType = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'roleName',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'principalName',
+           'type' => TType::STRING,
+           ),
+         3 => array(
+           'var' => 'principalType',
+           'type' => TType::I32,
+           ),
+         4 => array(
+           'var' => 'grantOption',
+           'type' => TType::BOOL,
+           ),
+         5 => array(
+           'var' => 'grantTime',
+           'type' => TType::I32,
+           ),
+         6 => array(
+           'var' => 'grantorName',
+           'type' => TType::STRING,
+           ),
+         7 => array(
+           'var' => 'grantorPrincipalType',
+           'type' => TType::I32,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['roleName'])) {
+         $this->roleName = $vals['roleName'];
+       }
+       if (isset($vals['principalName'])) {
+         $this->principalName = $vals['principalName'];
+       }
+       if (isset($vals['principalType'])) {
+         $this->principalType = $vals['principalType'];
+       }
+       if (isset($vals['grantOption'])) {
+         $this->grantOption = $vals['grantOption'];
+       }
+       if (isset($vals['grantTime'])) {
+         $this->grantTime = $vals['grantTime'];
+       }
+       if (isset($vals['grantorName'])) {
+         $this->grantorName = $vals['grantorName'];
+       }
+       if (isset($vals['grantorPrincipalType'])) {
+         $this->grantorPrincipalType = $vals['grantorPrincipalType'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'RolePrincipalGrant';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->roleName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->principalName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 3:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->principalType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 4:
+           if ($ftype == TType::BOOL) {
+             $xfer += $input->readBool($this->grantOption);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 5:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->grantTime);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 6:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->grantorName);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 7:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->grantorPrincipalType);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStructBegin('RolePrincipalGrant');
+     if ($this->roleName !== null) {
+       $xfer += $output->writeFieldBegin('roleName', TType::STRING, 1);
+       $xfer += $output->writeString($this->roleName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->principalName !== null) {
+       $xfer += $output->writeFieldBegin('principalName', TType::STRING, 2);
+       $xfer += $output->writeString($this->principalName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->principalType !== null) {
+       $xfer += $output->writeFieldBegin('principalType', TType::I32, 3);
+       $xfer += $output->writeI32($this->principalType);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantOption !== null) {
+       $xfer += $output->writeFieldBegin('grantOption', TType::BOOL, 4);
+       $xfer += $output->writeBool($this->grantOption);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantTime !== null) {
+       $xfer += $output->writeFieldBegin('grantTime', TType::I32, 5);
+       $xfer += $output->writeI32($this->grantTime);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantorName !== null) {
+       $xfer += $output->writeFieldBegin('grantorName', TType::STRING, 6);
+       $xfer += $output->writeString($this->grantorName);
+       $xfer += $output->writeFieldEnd();
+     }
+     if ($this->grantorPrincipalType !== null) {
+       $xfer += $output->writeFieldBegin('grantorPrincipalType', TType::I32, 7);
+       $xfer += $output->writeI32($this->grantorPrincipalType);
+       $xfer += $output->writeFieldEnd();
+     }
+     $xfer += $output->writeFieldStop();
+     $xfer += $output->writeStructEnd();
+     return $xfer;
+   }
+ 
+ }
+ 
+ class GetRoleGrantsForPrincipalRequest {
+   static $_TSPEC;
+ 
+   /**
+    * @var string
+    */
+   public $principal_name = null;
+   /**
+    * @var int
+    */
+   public $principal_type = null;
+ 
+   public function __construct($vals=null) {
+     if (!isset(self::$_TSPEC)) {
+       self::$_TSPEC = array(
+         1 => array(
+           'var' => 'principal_name',
+           'type' => TType::STRING,
+           ),
+         2 => array(
+           'var' => 'principal_type',
+           'type' => TType::I32,
+           ),
+         );
+     }
+     if (is_array($vals)) {
+       if (isset($vals['principal_name'])) {
+         $this->principal_name = $vals['principal_name'];
+       }
+       if (isset($vals['principal_type'])) {
+         $this->principal_type = $vals['principal_type'];
+       }
+     }
+   }
+ 
+   public function getName() {
+     return 'GetRoleGrantsForPrincipalRequest';
+   }
+ 
+   public function read($input)
+   {
+     $xfer = 0;
+     $fname = null;
+     $ftype = 0;
+     $fid = 0;
+     $xfer += $input->readStructBegin($fname);
+     while (true)
+     {
+       $xfer += $input->readFieldBegin($fname, $ftype, $fid);
+       if ($ftype == TType::STOP) {
+         break;
+       }
+       switch ($fid)
+       {
+         case 1:
+           if ($ftype == TType::STRING) {
+             $xfer += $input->readString($this->principal_name);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         case 2:
+           if ($ftype == TType::I32) {
+             $xfer += $input->readI32($this->principal_type);
+           } else {
+             $xfer += $input->skip($ftype);
+           }
+           break;
+         default:
+           $xfer += $input->skip($ftype);
+           break;
+       }
+       $xfer += $input->readFieldEnd();
+     }
+     $xfer += $input->readStructEnd();
+     return $xfer;
+   }
+ 
+   public function write($output) {
+     $xfer = 0;
+     $xfer += $output->writeStru

<TRUNCATED>

Mime
View raw message