[02/12] airavata-php-gateway git commit: AIRAVATA-2500 Thrift stub code generation
http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/cf2eae7e/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php -- diff --git a/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php b/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php new file mode 100644 index 000..541abd8 --- /dev/null +++ b/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php @@ -0,0 +1,345 @@ + 'STRING', +1 => 'CRED_STORE_PASSWORD_TOKEN', + ); +} + +class SSHAccountProvisionerConfigParam { + static $_TSPEC; + + /** + * @var string + */ + public $name = null; + /** + * @var int + */ + public $type = 0; + /** + * @var bool + */ + public $isOptional = false; + /** + * @var string + */ + public $description = 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::I32, + ), +3 => array( + 'var' => 'isOptional', + 'type' => TType::BOOL, + ), +4 => array( + 'var' => 'description', + '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['isOptional'])) { +$this->isOptional = $vals['isOptional']; + } + if (isset($vals['description'])) { +$this->description = $vals['description']; + } +} + } + + public function getName() { +return 'SSHAccountProvisionerConfigParam'; + } + + 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::I32) { +$xfer += $input->readI32($this->type); + } else { +$xfer += $input->skip($ftype); + } + break; +case 3: + if ($ftype == TType::BOOL) { +$xfer += $input->readBool($this->isOptional); + } else { +$xfer += $input->skip($ftype); + } + break; +case 4: + if ($ftype == TType::STRING) { +$xfer += $input->readString($this->description); + } 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('SSHAccountProvisionerConfigParam'); +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::I32, 2); + $xfer += $output->writeI32($this->type); + $xfer += $output->writeFieldEnd(); +} +if ($this->isOptional !== null) { + $xfer += $output->writeFieldBegin('isOptional', TType::BOOL, 3); + $xfer += $output->writeBool($this->isOptional); + $xfer += $output->writeFieldEnd(); +} +if ($this->description !== null) { + $xfer += $output->writeFieldBegin('description', TType::STRING, 4); + $xfer += $output->writeString($this->description); + $xfer += $output->writeFieldEnd(); +} +$xfer += $output->writeFieldStop(); +$xfer += $output->writeStructEnd(); +return $xfer; + } + +} + +class SSHAccountProvisioner { + static $_TSPEC; + + /** + * @var string + */ + public $name = null; + /** + * @var bool + */ + public $canCreateAccount = null; + /** + * @var bool + */ + public $canInstallSSHKey = null; + /** + * @var \Airavata\Model\AppCatalog\AccountProvisioning\SSHAccountProvisionerConfigParam[] + */ + public $configParams = null; + + public function __construct($vals=null) { +if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( +1 => array( + 'var' => 'name', + 'type' => TType::STRING, + ), +2 => array( + 'var' =>
[02/12] airavata-php-gateway git commit: AIRAVATA-2500 Thrift stub code generation
http://git-wip-us.apache.org/repos/asf/airavata-php-gateway/blob/cf2eae7e/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php -- diff --git a/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php b/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php new file mode 100644 index 000..541abd8 --- /dev/null +++ b/app/libraries/Airavata/Model/AppCatalog/AccountProvisioning/Types.php @@ -0,0 +1,345 @@ + 'STRING', +1 => 'CRED_STORE_PASSWORD_TOKEN', + ); +} + +class SSHAccountProvisionerConfigParam { + static $_TSPEC; + + /** + * @var string + */ + public $name = null; + /** + * @var int + */ + public $type = 0; + /** + * @var bool + */ + public $isOptional = false; + /** + * @var string + */ + public $description = 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::I32, + ), +3 => array( + 'var' => 'isOptional', + 'type' => TType::BOOL, + ), +4 => array( + 'var' => 'description', + '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['isOptional'])) { +$this->isOptional = $vals['isOptional']; + } + if (isset($vals['description'])) { +$this->description = $vals['description']; + } +} + } + + public function getName() { +return 'SSHAccountProvisionerConfigParam'; + } + + 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::I32) { +$xfer += $input->readI32($this->type); + } else { +$xfer += $input->skip($ftype); + } + break; +case 3: + if ($ftype == TType::BOOL) { +$xfer += $input->readBool($this->isOptional); + } else { +$xfer += $input->skip($ftype); + } + break; +case 4: + if ($ftype == TType::STRING) { +$xfer += $input->readString($this->description); + } 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('SSHAccountProvisionerConfigParam'); +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::I32, 2); + $xfer += $output->writeI32($this->type); + $xfer += $output->writeFieldEnd(); +} +if ($this->isOptional !== null) { + $xfer += $output->writeFieldBegin('isOptional', TType::BOOL, 3); + $xfer += $output->writeBool($this->isOptional); + $xfer += $output->writeFieldEnd(); +} +if ($this->description !== null) { + $xfer += $output->writeFieldBegin('description', TType::STRING, 4); + $xfer += $output->writeString($this->description); + $xfer += $output->writeFieldEnd(); +} +$xfer += $output->writeFieldStop(); +$xfer += $output->writeStructEnd(); +return $xfer; + } + +} + +class SSHAccountProvisioner { + static $_TSPEC; + + /** + * @var string + */ + public $name = null; + /** + * @var bool + */ + public $canCreateAccount = null; + /** + * @var bool + */ + public $canInstallSSHKey = null; + /** + * @var \Airavata\Model\AppCatalog\AccountProvisioning\SSHAccountProvisionerConfigParam[] + */ + public $configParams = null; + + public function __construct($vals=null) { +if (!isset(self::$_TSPEC)) { + self::$_TSPEC = array( +1 => array( + 'var' => 'name', + 'type' => TType::STRING, + ), +2 => array( + 'var' =>