blob: 3629b510f30ed4009e919f5cf80c55bf75c6f9c5 [file] [log] [blame]
<?php
namespace Airavata\Model\User;
/**
* Autogenerated by Thrift Compiler (0.10.0)
*
* 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 Status {
const ACTIVE = 0;
const CONFIRMED = 1;
const APPROVED = 2;
const DELETED = 3;
const DUPLICATE = 4;
const GRACE_PERIOD = 5;
const INVITED = 6;
const DENIED = 7;
const PENDING = 8;
const PENDING_APPROVAL = 9;
const PENDING_CONFIRMATION = 10;
const SUSPENDED = 11;
const DECLINED = 12;
const EXPIRED = 13;
static public $__names = array(
0 => 'ACTIVE',
1 => 'CONFIRMED',
2 => 'APPROVED',
3 => 'DELETED',
4 => 'DUPLICATE',
5 => 'GRACE_PERIOD',
6 => 'INVITED',
7 => 'DENIED',
8 => 'PENDING',
9 => 'PENDING_APPROVAL',
10 => 'PENDING_CONFIRMATION',
11 => 'SUSPENDED',
12 => 'DECLINED',
13 => 'EXPIRED',
);
}
/**
* U.S. Citizen (see: http://en.wikipedia.org/wiki/ISO_3166-1_alpha-2)
*
*/
final class USCitizenship {
const US_CITIZEN = 0;
const US_PERMANENT_RESIDENT = 1;
const OTHER_NON_US_CITIZEN = 2;
static public $__names = array(
0 => 'US_CITIZEN',
1 => 'US_PERMANENT_RESIDENT',
2 => 'OTHER_NON_US_CITIZEN',
);
}
/**
* Hispanic or Latino - a person of Mexican, Puerto Rican, Cuban, South or
* Central American, or other Spanish culture or origin, regardless of race.
*
*/
final class ethnicity {
const HISPANIC_LATINO = 0;
const NOT_HISPANIC_LATINO = 1;
static public $__names = array(
0 => 'HISPANIC_LATINO',
1 => 'NOT_HISPANIC_LATINO',
);
}
/**
* * Asian - a person having origins in any of the original peoples of the Far East,
* * Southeast Asia, or the Indian subcontinent including, for example, Cambodia,
* * China, India, Japan, Korea, Malaysia, Pakistan, the Philippine Islands,
* * Thailand, and Vietnam.
* * American Indian or Alaskan Native - a person having origins in any of the original
* * peoples of North and South America (including Central America), and who maintains
* * tribal affiliation or community attachment.
* * Black or African American - a person having origins in any of the black racial groups
* * of Africa.
* * Native Hawaiian or Pacific Islander - a person having origins in any of the original
* * peoples of Hawaii, Guan, Samoa, or other Pacific Islands.
* * White - a person having origins in any of the original peoples of Europe, the Middle East, or North Africa.
* *
*/
final class race {
const ASIAN = 0;
const AMERICAN_INDIAN_OR_ALASKAN_NATIVE = 1;
const BLACK_OR_AFRICAN_AMERICAN = 2;
const NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER = 3;
const WHITE = 4;
static public $__names = array(
0 => 'ASIAN',
1 => 'AMERICAN_INDIAN_OR_ALASKAN_NATIVE',
2 => 'BLACK_OR_AFRICAN_AMERICAN',
3 => 'NATIVE_HAWAIIAN_OR_PACIFIC_ISLANDER',
4 => 'WHITE',
);
}
final class disability {
const HEARING_IMAPAIRED = 0;
const VISUAL_IMPAIRED = 1;
const MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT = 2;
const OTHER_IMPAIRMENT = 3;
static public $__names = array(
0 => 'HEARING_IMAPAIRED',
1 => 'VISUAL_IMPAIRED',
2 => 'MOBILITY_OR_ORTHOPEDIC_IMPAIRMENT',
3 => 'OTHER_IMPAIRMENT',
);
}
/**
* A structure holding the NSF Demographic information.
*
*
*/
class NSFDemographics {
static $_TSPEC;
/**
* @var string
*/
public $airavataInternalUserId = "DO_NOT_SET_AT_CLIENTS";
/**
* @var string
*/
public $gender = null;
/**
* @var int
*/
public $usCitizenship = null;
/**
* @var int[]
*/
public $ethnicities = null;
/**
* @var int[]
*/
public $races = null;
/**
* @var int[]
*/
public $disabilities = null;
public function __construct($vals=null) {
if (!isset(self::$_TSPEC)) {
self::$_TSPEC = array(
1 => array(
'var' => 'airavataInternalUserId',
'type' => TType::STRING,
),
2 => array(
'var' => 'gender',
'type' => TType::STRING,
),
3 => array(
'var' => 'usCitizenship',
'type' => TType::I32,
),
4 => array(
'var' => 'ethnicities',
'type' => TType::LST,
'etype' => TType::I32,
'elem' => array(
'type' => TType::I32,
),
),
5 => array(
'var' => 'races',
'type' => TType::LST,
'etype' => TType::I32,
'elem' => array(
'type' => TType::I32,
),
),
6 => array(
'var' => 'disabilities',
'type' => TType::LST,
'etype' => TType::I32,
'elem' => array(
'type' => TType::I32,
),
),
);
}
if (is_array($vals)) {
if (isset($vals['airavataInternalUserId'])) {
$this->airavataInternalUserId = $vals['airavataInternalUserId'];
}
if (isset($vals['gender'])) {
$this->gender = $vals['gender'];
}
if (isset($vals['usCitizenship'])) {
$this->usCitizenship = $vals['usCitizenship'];
}
if (isset($vals['ethnicities'])) {
$this->ethnicities = $vals['ethnicities'];
}
if (isset($vals['races'])) {
$this->races = $vals['races'];
}
if (isset($vals['disabilities'])) {
$this->disabilities = $vals['disabilities'];
}
}
}
public function getName() {
return 'NSFDemographics';
}
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->airavataInternalUserId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 2:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->gender);
} else {
$xfer += $input->skip($ftype);
}
break;
case 3:
if ($ftype == TType::I32) {
$xfer += $input->readI32($this->usCitizenship);
} else {
$xfer += $input->skip($ftype);
}
break;
case 4:
if ($ftype == TType::LST) {
$this->ethnicities = array();
$_size0 = 0;
$_etype3 = 0;
$xfer += $input->readListBegin($_etype3, $_size0);
for ($_i4 = 0; $_i4 < $_size0; ++$_i4)
{
$elem5 = null;
$xfer += $input->readI32($elem5);
$this->ethnicities []= $elem5;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 5:
if ($ftype == TType::LST) {
$this->races = array();
$_size6 = 0;
$_etype9 = 0;
$xfer += $input->readListBegin($_etype9, $_size6);
for ($_i10 = 0; $_i10 < $_size6; ++$_i10)
{
$elem11 = null;
$xfer += $input->readI32($elem11);
$this->races []= $elem11;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 6:
if ($ftype == TType::LST) {
$this->disabilities = array();
$_size12 = 0;
$_etype15 = 0;
$xfer += $input->readListBegin($_etype15, $_size12);
for ($_i16 = 0; $_i16 < $_size12; ++$_i16)
{
$elem17 = null;
$xfer += $input->readI32($elem17);
$this->disabilities []= $elem17;
}
$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('NSFDemographics');
if ($this->airavataInternalUserId !== null) {
$xfer += $output->writeFieldBegin('airavataInternalUserId', TType::STRING, 1);
$xfer += $output->writeString($this->airavataInternalUserId);
$xfer += $output->writeFieldEnd();
}
if ($this->gender !== null) {
$xfer += $output->writeFieldBegin('gender', TType::STRING, 2);
$xfer += $output->writeString($this->gender);
$xfer += $output->writeFieldEnd();
}
if ($this->usCitizenship !== null) {
$xfer += $output->writeFieldBegin('usCitizenship', TType::I32, 3);
$xfer += $output->writeI32($this->usCitizenship);
$xfer += $output->writeFieldEnd();
}
if ($this->ethnicities !== null) {
if (!is_array($this->ethnicities)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('ethnicities', TType::LST, 4);
{
$output->writeListBegin(TType::I32, count($this->ethnicities));
{
foreach ($this->ethnicities as $iter18)
{
$xfer += $output->writeI32($iter18);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->races !== null) {
if (!is_array($this->races)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('races', TType::LST, 5);
{
$output->writeListBegin(TType::I32, count($this->races));
{
foreach ($this->races as $iter19)
{
$xfer += $output->writeI32($iter19);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->disabilities !== null) {
if (!is_array($this->disabilities)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('disabilities', TType::LST, 6);
{
$output->writeListBegin(TType::I32, count($this->disabilities));
{
foreach ($this->disabilities as $iter20)
{
$xfer += $output->writeI32($iter20);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
$xfer += $output->writeFieldStop();
$xfer += $output->writeStructEnd();
return $xfer;
}
}
/**
* A structure holding the cutomized admin dashboard information.
*
*
*/
class CustomDashboard {
static $_TSPEC;
/**
* @var string
*/
public $airavataInternalUserId = "DO_NOT_SET_AT_CLIENTS";
/**
* @var string
*/
public $experimentId = null;
/**
* @var string
*/
public $name = null;
/**
* @var string
*/
public $description = null;
/**
* @var string
*/
public $project = null;
/**
* @var string
*/
public $owner = null;
/**
* @var string
*/
public $application = null;
/**
* @var string
*/
public $computeResource = null;
/**
* @var string
*/
public $jobName = null;
/**
* @var string
*/
public $jobId = null;
/**
* @var string
*/
public $jobStatus = null;
/**
* @var string
*/
public $jobCreationTime = null;
/**
* @var string
*/
public $notificationsTo = null;
/**
* @var string
*/
public $workingDir = null;
/**
* @var string
*/
public $jobDescription = null;
/**
* @var string
*/
public $creationTime = null;
/**
* @var string
*/
public $lastModifiedTime = null;
/**
* @var string
*/
public $wallTime = null;
/**
* @var string
*/
public $cpuCount = null;
/**
* @var string
*/
public $nodeCount = null;
/**
* @var string
*/
public $queue = null;
/**
* @var string
*/
public $inputs = null;
/**
* @var string
*/
public $outputs = null;
/**
* @var string
*/
public $storageDir = null;
/**
* @var string
*/
public $errors = null;
public function __construct($vals=null) {
if (!isset(self::$_TSPEC)) {
self::$_TSPEC = array(
1 => array(
'var' => 'airavataInternalUserId',
'type' => TType::STRING,
),
2 => array(
'var' => 'experimentId',
'type' => TType::STRING,
),
3 => array(
'var' => 'name',
'type' => TType::STRING,
),
4 => array(
'var' => 'description',
'type' => TType::STRING,
),
5 => array(
'var' => 'project',
'type' => TType::STRING,
),
6 => array(
'var' => 'owner',
'type' => TType::STRING,
),
7 => array(
'var' => 'application',
'type' => TType::STRING,
),
8 => array(
'var' => 'computeResource',
'type' => TType::STRING,
),
9 => array(
'var' => 'jobName',
'type' => TType::STRING,
),
10 => array(
'var' => 'jobId',
'type' => TType::STRING,
),
11 => array(
'var' => 'jobStatus',
'type' => TType::STRING,
),
12 => array(
'var' => 'jobCreationTime',
'type' => TType::STRING,
),
13 => array(
'var' => 'notificationsTo',
'type' => TType::STRING,
),
14 => array(
'var' => 'workingDir',
'type' => TType::STRING,
),
15 => array(
'var' => 'jobDescription',
'type' => TType::STRING,
),
16 => array(
'var' => 'creationTime',
'type' => TType::STRING,
),
17 => array(
'var' => 'lastModifiedTime',
'type' => TType::STRING,
),
18 => array(
'var' => 'wallTime',
'type' => TType::STRING,
),
19 => array(
'var' => 'cpuCount',
'type' => TType::STRING,
),
20 => array(
'var' => 'nodeCount',
'type' => TType::STRING,
),
21 => array(
'var' => 'queue',
'type' => TType::STRING,
),
22 => array(
'var' => 'inputs',
'type' => TType::STRING,
),
23 => array(
'var' => 'outputs',
'type' => TType::STRING,
),
24 => array(
'var' => 'storageDir',
'type' => TType::STRING,
),
25 => array(
'var' => 'errors',
'type' => TType::STRING,
),
);
}
if (is_array($vals)) {
if (isset($vals['airavataInternalUserId'])) {
$this->airavataInternalUserId = $vals['airavataInternalUserId'];
}
if (isset($vals['experimentId'])) {
$this->experimentId = $vals['experimentId'];
}
if (isset($vals['name'])) {
$this->name = $vals['name'];
}
if (isset($vals['description'])) {
$this->description = $vals['description'];
}
if (isset($vals['project'])) {
$this->project = $vals['project'];
}
if (isset($vals['owner'])) {
$this->owner = $vals['owner'];
}
if (isset($vals['application'])) {
$this->application = $vals['application'];
}
if (isset($vals['computeResource'])) {
$this->computeResource = $vals['computeResource'];
}
if (isset($vals['jobName'])) {
$this->jobName = $vals['jobName'];
}
if (isset($vals['jobId'])) {
$this->jobId = $vals['jobId'];
}
if (isset($vals['jobStatus'])) {
$this->jobStatus = $vals['jobStatus'];
}
if (isset($vals['jobCreationTime'])) {
$this->jobCreationTime = $vals['jobCreationTime'];
}
if (isset($vals['notificationsTo'])) {
$this->notificationsTo = $vals['notificationsTo'];
}
if (isset($vals['workingDir'])) {
$this->workingDir = $vals['workingDir'];
}
if (isset($vals['jobDescription'])) {
$this->jobDescription = $vals['jobDescription'];
}
if (isset($vals['creationTime'])) {
$this->creationTime = $vals['creationTime'];
}
if (isset($vals['lastModifiedTime'])) {
$this->lastModifiedTime = $vals['lastModifiedTime'];
}
if (isset($vals['wallTime'])) {
$this->wallTime = $vals['wallTime'];
}
if (isset($vals['cpuCount'])) {
$this->cpuCount = $vals['cpuCount'];
}
if (isset($vals['nodeCount'])) {
$this->nodeCount = $vals['nodeCount'];
}
if (isset($vals['queue'])) {
$this->queue = $vals['queue'];
}
if (isset($vals['inputs'])) {
$this->inputs = $vals['inputs'];
}
if (isset($vals['outputs'])) {
$this->outputs = $vals['outputs'];
}
if (isset($vals['storageDir'])) {
$this->storageDir = $vals['storageDir'];
}
if (isset($vals['errors'])) {
$this->errors = $vals['errors'];
}
}
}
public function getName() {
return 'CustomDashboard';
}
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->airavataInternalUserId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 2:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->experimentId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 3:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->name);
} else {
$xfer += $input->skip($ftype);
}
break;
case 4:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->description);
} else {
$xfer += $input->skip($ftype);
}
break;
case 5:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->project);
} else {
$xfer += $input->skip($ftype);
}
break;
case 6:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->owner);
} else {
$xfer += $input->skip($ftype);
}
break;
case 7:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->application);
} else {
$xfer += $input->skip($ftype);
}
break;
case 8:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->computeResource);
} else {
$xfer += $input->skip($ftype);
}
break;
case 9:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->jobName);
} else {
$xfer += $input->skip($ftype);
}
break;
case 10:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->jobId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 11:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->jobStatus);
} else {
$xfer += $input->skip($ftype);
}
break;
case 12:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->jobCreationTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 13:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->notificationsTo);
} else {
$xfer += $input->skip($ftype);
}
break;
case 14:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->workingDir);
} else {
$xfer += $input->skip($ftype);
}
break;
case 15:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->jobDescription);
} else {
$xfer += $input->skip($ftype);
}
break;
case 16:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->creationTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 17:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->lastModifiedTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 18:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->wallTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 19:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->cpuCount);
} else {
$xfer += $input->skip($ftype);
}
break;
case 20:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->nodeCount);
} else {
$xfer += $input->skip($ftype);
}
break;
case 21:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->queue);
} else {
$xfer += $input->skip($ftype);
}
break;
case 22:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->inputs);
} else {
$xfer += $input->skip($ftype);
}
break;
case 23:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->outputs);
} else {
$xfer += $input->skip($ftype);
}
break;
case 24:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->storageDir);
} else {
$xfer += $input->skip($ftype);
}
break;
case 25:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->errors);
} 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('CustomDashboard');
if ($this->airavataInternalUserId !== null) {
$xfer += $output->writeFieldBegin('airavataInternalUserId', TType::STRING, 1);
$xfer += $output->writeString($this->airavataInternalUserId);
$xfer += $output->writeFieldEnd();
}
if ($this->experimentId !== null) {
$xfer += $output->writeFieldBegin('experimentId', TType::STRING, 2);
$xfer += $output->writeString($this->experimentId);
$xfer += $output->writeFieldEnd();
}
if ($this->name !== null) {
$xfer += $output->writeFieldBegin('name', TType::STRING, 3);
$xfer += $output->writeString($this->name);
$xfer += $output->writeFieldEnd();
}
if ($this->description !== null) {
$xfer += $output->writeFieldBegin('description', TType::STRING, 4);
$xfer += $output->writeString($this->description);
$xfer += $output->writeFieldEnd();
}
if ($this->project !== null) {
$xfer += $output->writeFieldBegin('project', TType::STRING, 5);
$xfer += $output->writeString($this->project);
$xfer += $output->writeFieldEnd();
}
if ($this->owner !== null) {
$xfer += $output->writeFieldBegin('owner', TType::STRING, 6);
$xfer += $output->writeString($this->owner);
$xfer += $output->writeFieldEnd();
}
if ($this->application !== null) {
$xfer += $output->writeFieldBegin('application', TType::STRING, 7);
$xfer += $output->writeString($this->application);
$xfer += $output->writeFieldEnd();
}
if ($this->computeResource !== null) {
$xfer += $output->writeFieldBegin('computeResource', TType::STRING, 8);
$xfer += $output->writeString($this->computeResource);
$xfer += $output->writeFieldEnd();
}
if ($this->jobName !== null) {
$xfer += $output->writeFieldBegin('jobName', TType::STRING, 9);
$xfer += $output->writeString($this->jobName);
$xfer += $output->writeFieldEnd();
}
if ($this->jobId !== null) {
$xfer += $output->writeFieldBegin('jobId', TType::STRING, 10);
$xfer += $output->writeString($this->jobId);
$xfer += $output->writeFieldEnd();
}
if ($this->jobStatus !== null) {
$xfer += $output->writeFieldBegin('jobStatus', TType::STRING, 11);
$xfer += $output->writeString($this->jobStatus);
$xfer += $output->writeFieldEnd();
}
if ($this->jobCreationTime !== null) {
$xfer += $output->writeFieldBegin('jobCreationTime', TType::STRING, 12);
$xfer += $output->writeString($this->jobCreationTime);
$xfer += $output->writeFieldEnd();
}
if ($this->notificationsTo !== null) {
$xfer += $output->writeFieldBegin('notificationsTo', TType::STRING, 13);
$xfer += $output->writeString($this->notificationsTo);
$xfer += $output->writeFieldEnd();
}
if ($this->workingDir !== null) {
$xfer += $output->writeFieldBegin('workingDir', TType::STRING, 14);
$xfer += $output->writeString($this->workingDir);
$xfer += $output->writeFieldEnd();
}
if ($this->jobDescription !== null) {
$xfer += $output->writeFieldBegin('jobDescription', TType::STRING, 15);
$xfer += $output->writeString($this->jobDescription);
$xfer += $output->writeFieldEnd();
}
if ($this->creationTime !== null) {
$xfer += $output->writeFieldBegin('creationTime', TType::STRING, 16);
$xfer += $output->writeString($this->creationTime);
$xfer += $output->writeFieldEnd();
}
if ($this->lastModifiedTime !== null) {
$xfer += $output->writeFieldBegin('lastModifiedTime', TType::STRING, 17);
$xfer += $output->writeString($this->lastModifiedTime);
$xfer += $output->writeFieldEnd();
}
if ($this->wallTime !== null) {
$xfer += $output->writeFieldBegin('wallTime', TType::STRING, 18);
$xfer += $output->writeString($this->wallTime);
$xfer += $output->writeFieldEnd();
}
if ($this->cpuCount !== null) {
$xfer += $output->writeFieldBegin('cpuCount', TType::STRING, 19);
$xfer += $output->writeString($this->cpuCount);
$xfer += $output->writeFieldEnd();
}
if ($this->nodeCount !== null) {
$xfer += $output->writeFieldBegin('nodeCount', TType::STRING, 20);
$xfer += $output->writeString($this->nodeCount);
$xfer += $output->writeFieldEnd();
}
if ($this->queue !== null) {
$xfer += $output->writeFieldBegin('queue', TType::STRING, 21);
$xfer += $output->writeString($this->queue);
$xfer += $output->writeFieldEnd();
}
if ($this->inputs !== null) {
$xfer += $output->writeFieldBegin('inputs', TType::STRING, 22);
$xfer += $output->writeString($this->inputs);
$xfer += $output->writeFieldEnd();
}
if ($this->outputs !== null) {
$xfer += $output->writeFieldBegin('outputs', TType::STRING, 23);
$xfer += $output->writeString($this->outputs);
$xfer += $output->writeFieldEnd();
}
if ($this->storageDir !== null) {
$xfer += $output->writeFieldBegin('storageDir', TType::STRING, 24);
$xfer += $output->writeString($this->storageDir);
$xfer += $output->writeFieldEnd();
}
if ($this->errors !== null) {
$xfer += $output->writeFieldBegin('errors', TType::STRING, 25);
$xfer += $output->writeString($this->errors);
$xfer += $output->writeFieldEnd();
}
$xfer += $output->writeFieldStop();
$xfer += $output->writeStructEnd();
return $xfer;
}
}
/**
* * A structure holding the user profile and its child models.
* *
* * Notes:
* * The model does not include passwords as it is assumed an external identity provider is used to authenticate user.
* * References:
* * NSF Demographic Information - http://www.nsf.gov/pubs/2000/00form1225/00form1225.doc
* * LDAP Schema - https://tools.ietf.org/html/rfc4519
* * SCIM 2.0 - https://tools.ietf.org/html/rfc7643
* *
* * userModelVersion:
* * Version number of profile
* *
* * airavataInternalUserId:
* * internal to Airavata, not intended to be used outside of the Airavata platform or possibly by gateways
* * (that is, never shown to users), never reassigned, REQUIRED
* *
* * userId:
* * Externally assertable unique identifier. SAML (primarly in higher education, academic) tends to keep
* * user name less opaque. OpenID Connect maintains them to be opaque.
* *
* * firstName, middleName, lastName:
* * First and Last names as assertede by the user
* *
* * namePrefix, nameSuffix:
* * prefix and suffix to the users name as asserted by the user
* *
* * emails:
* * Email identifier are Verified, REQUIRED and MULTIVALUED
* *
* * userName:
* * Name-based identifiers can be multivalues. To keep it simple, Airavata will make it a string.
* * In the future these can be enumerated as:
* * Official name (as asserted possibly by some external identity provider)
* * Prefered name (as asserted or suggested by user directly)
* * Components:
* * givenName
* * surname (familyName)
* * displayName (often asserted by user to handle things like middle names, suffix, prefix, and the like)
* *
* * orcidId: ORCID ID - http://orcid.org/about/what-is-orcid)
* *
* * phones: Telephone MULTIVALUED
* *
* * country: Country of Residance
* *
* * nationality Countries of citizenship
* *
* * comments:
* * Free-form information (treated as opaque by Airavata and simply passed to resource).
* *
* * labeledURI:
* * Google Scholar, Web of Science, ACS, e.t.c
* *
* * timeZone:
* * User’s preferred timezone - IANA Timezone Databases - http://www.iana.org/time-zones.
* *
*/
class UserProfile {
static $_TSPEC;
/**
* @var string
*/
public $userModelVersion = "1.0";
/**
* @var string
*/
public $airavataInternalUserId = "DO_NOT_SET_AT_CLIENTS";
/**
* @var string
*/
public $userId = null;
/**
* @var string
*/
public $gatewayId = null;
/**
* @var string[]
*/
public $emails = null;
/**
* @var string
*/
public $firstName = null;
/**
* @var string
*/
public $lastName = null;
/**
* @var string
*/
public $middleName = null;
/**
* @var string
*/
public $namePrefix = null;
/**
* @var string
*/
public $nameSuffix = null;
/**
* @var string
*/
public $orcidId = null;
/**
* @var string[]
*/
public $phones = null;
/**
* @var string
*/
public $country = null;
/**
* @var string[]
*/
public $nationality = null;
/**
* @var string
*/
public $homeOrganization = null;
/**
* @var string
*/
public $orginationAffiliation = null;
/**
* @var int
*/
public $creationTime = null;
/**
* @var int
*/
public $lastAccessTime = null;
/**
* @var int
*/
public $validUntil = null;
/**
* @var int
*/
public $State = null;
/**
* @var string
*/
public $comments = null;
/**
* @var string[]
*/
public $labeledURI = null;
/**
* @var string
*/
public $gpgKey = null;
/**
* @var string
*/
public $timeZone = null;
/**
* @var \Airavata\Model\User\NSFDemographics
*/
public $nsfDemographics = null;
/**
* @var \Airavata\Model\User\CustomDashboard
*/
public $customDashboard = null;
public function __construct($vals=null) {
if (!isset(self::$_TSPEC)) {
self::$_TSPEC = array(
1 => array(
'var' => 'userModelVersion',
'type' => TType::STRING,
),
2 => array(
'var' => 'airavataInternalUserId',
'type' => TType::STRING,
),
3 => array(
'var' => 'userId',
'type' => TType::STRING,
),
4 => array(
'var' => 'gatewayId',
'type' => TType::STRING,
),
5 => array(
'var' => 'emails',
'type' => TType::LST,
'etype' => TType::STRING,
'elem' => array(
'type' => TType::STRING,
),
),
6 => array(
'var' => 'firstName',
'type' => TType::STRING,
),
7 => array(
'var' => 'lastName',
'type' => TType::STRING,
),
8 => array(
'var' => 'middleName',
'type' => TType::STRING,
),
9 => array(
'var' => 'namePrefix',
'type' => TType::STRING,
),
10 => array(
'var' => 'nameSuffix',
'type' => TType::STRING,
),
11 => array(
'var' => 'orcidId',
'type' => TType::STRING,
),
12 => array(
'var' => 'phones',
'type' => TType::LST,
'etype' => TType::STRING,
'elem' => array(
'type' => TType::STRING,
),
),
13 => array(
'var' => 'country',
'type' => TType::STRING,
),
14 => array(
'var' => 'nationality',
'type' => TType::LST,
'etype' => TType::STRING,
'elem' => array(
'type' => TType::STRING,
),
),
15 => array(
'var' => 'homeOrganization',
'type' => TType::STRING,
),
16 => array(
'var' => 'orginationAffiliation',
'type' => TType::STRING,
),
17 => array(
'var' => 'creationTime',
'type' => TType::I64,
),
18 => array(
'var' => 'lastAccessTime',
'type' => TType::I64,
),
19 => array(
'var' => 'validUntil',
'type' => TType::I64,
),
20 => array(
'var' => 'State',
'type' => TType::I32,
),
21 => array(
'var' => 'comments',
'type' => TType::STRING,
),
22 => array(
'var' => 'labeledURI',
'type' => TType::LST,
'etype' => TType::STRING,
'elem' => array(
'type' => TType::STRING,
),
),
23 => array(
'var' => 'gpgKey',
'type' => TType::STRING,
),
24 => array(
'var' => 'timeZone',
'type' => TType::STRING,
),
25 => array(
'var' => 'nsfDemographics',
'type' => TType::STRUCT,
'class' => '\Airavata\Model\User\NSFDemographics',
),
26 => array(
'var' => 'customDashboard',
'type' => TType::STRUCT,
'class' => '\Airavata\Model\User\CustomDashboard',
),
);
}
if (is_array($vals)) {
if (isset($vals['userModelVersion'])) {
$this->userModelVersion = $vals['userModelVersion'];
}
if (isset($vals['airavataInternalUserId'])) {
$this->airavataInternalUserId = $vals['airavataInternalUserId'];
}
if (isset($vals['userId'])) {
$this->userId = $vals['userId'];
}
if (isset($vals['gatewayId'])) {
$this->gatewayId = $vals['gatewayId'];
}
if (isset($vals['emails'])) {
$this->emails = $vals['emails'];
}
if (isset($vals['firstName'])) {
$this->firstName = $vals['firstName'];
}
if (isset($vals['lastName'])) {
$this->lastName = $vals['lastName'];
}
if (isset($vals['middleName'])) {
$this->middleName = $vals['middleName'];
}
if (isset($vals['namePrefix'])) {
$this->namePrefix = $vals['namePrefix'];
}
if (isset($vals['nameSuffix'])) {
$this->nameSuffix = $vals['nameSuffix'];
}
if (isset($vals['orcidId'])) {
$this->orcidId = $vals['orcidId'];
}
if (isset($vals['phones'])) {
$this->phones = $vals['phones'];
}
if (isset($vals['country'])) {
$this->country = $vals['country'];
}
if (isset($vals['nationality'])) {
$this->nationality = $vals['nationality'];
}
if (isset($vals['homeOrganization'])) {
$this->homeOrganization = $vals['homeOrganization'];
}
if (isset($vals['orginationAffiliation'])) {
$this->orginationAffiliation = $vals['orginationAffiliation'];
}
if (isset($vals['creationTime'])) {
$this->creationTime = $vals['creationTime'];
}
if (isset($vals['lastAccessTime'])) {
$this->lastAccessTime = $vals['lastAccessTime'];
}
if (isset($vals['validUntil'])) {
$this->validUntil = $vals['validUntil'];
}
if (isset($vals['State'])) {
$this->State = $vals['State'];
}
if (isset($vals['comments'])) {
$this->comments = $vals['comments'];
}
if (isset($vals['labeledURI'])) {
$this->labeledURI = $vals['labeledURI'];
}
if (isset($vals['gpgKey'])) {
$this->gpgKey = $vals['gpgKey'];
}
if (isset($vals['timeZone'])) {
$this->timeZone = $vals['timeZone'];
}
if (isset($vals['nsfDemographics'])) {
$this->nsfDemographics = $vals['nsfDemographics'];
}
if (isset($vals['customDashboard'])) {
$this->customDashboard = $vals['customDashboard'];
}
}
}
public function getName() {
return 'UserProfile';
}
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->userModelVersion);
} else {
$xfer += $input->skip($ftype);
}
break;
case 2:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->airavataInternalUserId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 3:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->userId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 4:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->gatewayId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 5:
if ($ftype == TType::LST) {
$this->emails = array();
$_size21 = 0;
$_etype24 = 0;
$xfer += $input->readListBegin($_etype24, $_size21);
for ($_i25 = 0; $_i25 < $_size21; ++$_i25)
{
$elem26 = null;
$xfer += $input->readString($elem26);
$this->emails []= $elem26;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 6:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->firstName);
} else {
$xfer += $input->skip($ftype);
}
break;
case 7:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->lastName);
} else {
$xfer += $input->skip($ftype);
}
break;
case 8:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->middleName);
} else {
$xfer += $input->skip($ftype);
}
break;
case 9:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->namePrefix);
} else {
$xfer += $input->skip($ftype);
}
break;
case 10:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->nameSuffix);
} else {
$xfer += $input->skip($ftype);
}
break;
case 11:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->orcidId);
} else {
$xfer += $input->skip($ftype);
}
break;
case 12:
if ($ftype == TType::LST) {
$this->phones = array();
$_size27 = 0;
$_etype30 = 0;
$xfer += $input->readListBegin($_etype30, $_size27);
for ($_i31 = 0; $_i31 < $_size27; ++$_i31)
{
$elem32 = null;
$xfer += $input->readString($elem32);
$this->phones []= $elem32;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 13:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->country);
} else {
$xfer += $input->skip($ftype);
}
break;
case 14:
if ($ftype == TType::LST) {
$this->nationality = array();
$_size33 = 0;
$_etype36 = 0;
$xfer += $input->readListBegin($_etype36, $_size33);
for ($_i37 = 0; $_i37 < $_size33; ++$_i37)
{
$elem38 = null;
$xfer += $input->readString($elem38);
$this->nationality []= $elem38;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 15:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->homeOrganization);
} else {
$xfer += $input->skip($ftype);
}
break;
case 16:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->orginationAffiliation);
} else {
$xfer += $input->skip($ftype);
}
break;
case 17:
if ($ftype == TType::I64) {
$xfer += $input->readI64($this->creationTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 18:
if ($ftype == TType::I64) {
$xfer += $input->readI64($this->lastAccessTime);
} else {
$xfer += $input->skip($ftype);
}
break;
case 19:
if ($ftype == TType::I64) {
$xfer += $input->readI64($this->validUntil);
} else {
$xfer += $input->skip($ftype);
}
break;
case 20:
if ($ftype == TType::I32) {
$xfer += $input->readI32($this->State);
} else {
$xfer += $input->skip($ftype);
}
break;
case 21:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->comments);
} else {
$xfer += $input->skip($ftype);
}
break;
case 22:
if ($ftype == TType::LST) {
$this->labeledURI = array();
$_size39 = 0;
$_etype42 = 0;
$xfer += $input->readListBegin($_etype42, $_size39);
for ($_i43 = 0; $_i43 < $_size39; ++$_i43)
{
$elem44 = null;
$xfer += $input->readString($elem44);
$this->labeledURI []= $elem44;
}
$xfer += $input->readListEnd();
} else {
$xfer += $input->skip($ftype);
}
break;
case 23:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->gpgKey);
} else {
$xfer += $input->skip($ftype);
}
break;
case 24:
if ($ftype == TType::STRING) {
$xfer += $input->readString($this->timeZone);
} else {
$xfer += $input->skip($ftype);
}
break;
case 25:
if ($ftype == TType::STRUCT) {
$this->nsfDemographics = new \Airavata\Model\User\NSFDemographics();
$xfer += $this->nsfDemographics->read($input);
} else {
$xfer += $input->skip($ftype);
}
break;
case 26:
if ($ftype == TType::STRUCT) {
$this->customDashboard = new \Airavata\Model\User\CustomDashboard();
$xfer += $this->customDashboard->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('UserProfile');
if ($this->userModelVersion !== null) {
$xfer += $output->writeFieldBegin('userModelVersion', TType::STRING, 1);
$xfer += $output->writeString($this->userModelVersion);
$xfer += $output->writeFieldEnd();
}
if ($this->airavataInternalUserId !== null) {
$xfer += $output->writeFieldBegin('airavataInternalUserId', TType::STRING, 2);
$xfer += $output->writeString($this->airavataInternalUserId);
$xfer += $output->writeFieldEnd();
}
if ($this->userId !== null) {
$xfer += $output->writeFieldBegin('userId', TType::STRING, 3);
$xfer += $output->writeString($this->userId);
$xfer += $output->writeFieldEnd();
}
if ($this->gatewayId !== null) {
$xfer += $output->writeFieldBegin('gatewayId', TType::STRING, 4);
$xfer += $output->writeString($this->gatewayId);
$xfer += $output->writeFieldEnd();
}
if ($this->emails !== null) {
if (!is_array($this->emails)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('emails', TType::LST, 5);
{
$output->writeListBegin(TType::STRING, count($this->emails));
{
foreach ($this->emails as $iter45)
{
$xfer += $output->writeString($iter45);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->firstName !== null) {
$xfer += $output->writeFieldBegin('firstName', TType::STRING, 6);
$xfer += $output->writeString($this->firstName);
$xfer += $output->writeFieldEnd();
}
if ($this->lastName !== null) {
$xfer += $output->writeFieldBegin('lastName', TType::STRING, 7);
$xfer += $output->writeString($this->lastName);
$xfer += $output->writeFieldEnd();
}
if ($this->middleName !== null) {
$xfer += $output->writeFieldBegin('middleName', TType::STRING, 8);
$xfer += $output->writeString($this->middleName);
$xfer += $output->writeFieldEnd();
}
if ($this->namePrefix !== null) {
$xfer += $output->writeFieldBegin('namePrefix', TType::STRING, 9);
$xfer += $output->writeString($this->namePrefix);
$xfer += $output->writeFieldEnd();
}
if ($this->nameSuffix !== null) {
$xfer += $output->writeFieldBegin('nameSuffix', TType::STRING, 10);
$xfer += $output->writeString($this->nameSuffix);
$xfer += $output->writeFieldEnd();
}
if ($this->orcidId !== null) {
$xfer += $output->writeFieldBegin('orcidId', TType::STRING, 11);
$xfer += $output->writeString($this->orcidId);
$xfer += $output->writeFieldEnd();
}
if ($this->phones !== null) {
if (!is_array($this->phones)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('phones', TType::LST, 12);
{
$output->writeListBegin(TType::STRING, count($this->phones));
{
foreach ($this->phones as $iter46)
{
$xfer += $output->writeString($iter46);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->country !== null) {
$xfer += $output->writeFieldBegin('country', TType::STRING, 13);
$xfer += $output->writeString($this->country);
$xfer += $output->writeFieldEnd();
}
if ($this->nationality !== null) {
if (!is_array($this->nationality)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('nationality', TType::LST, 14);
{
$output->writeListBegin(TType::STRING, count($this->nationality));
{
foreach ($this->nationality as $iter47)
{
$xfer += $output->writeString($iter47);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->homeOrganization !== null) {
$xfer += $output->writeFieldBegin('homeOrganization', TType::STRING, 15);
$xfer += $output->writeString($this->homeOrganization);
$xfer += $output->writeFieldEnd();
}
if ($this->orginationAffiliation !== null) {
$xfer += $output->writeFieldBegin('orginationAffiliation', TType::STRING, 16);
$xfer += $output->writeString($this->orginationAffiliation);
$xfer += $output->writeFieldEnd();
}
if ($this->creationTime !== null) {
$xfer += $output->writeFieldBegin('creationTime', TType::I64, 17);
$xfer += $output->writeI64($this->creationTime);
$xfer += $output->writeFieldEnd();
}
if ($this->lastAccessTime !== null) {
$xfer += $output->writeFieldBegin('lastAccessTime', TType::I64, 18);
$xfer += $output->writeI64($this->lastAccessTime);
$xfer += $output->writeFieldEnd();
}
if ($this->validUntil !== null) {
$xfer += $output->writeFieldBegin('validUntil', TType::I64, 19);
$xfer += $output->writeI64($this->validUntil);
$xfer += $output->writeFieldEnd();
}
if ($this->State !== null) {
$xfer += $output->writeFieldBegin('State', TType::I32, 20);
$xfer += $output->writeI32($this->State);
$xfer += $output->writeFieldEnd();
}
if ($this->comments !== null) {
$xfer += $output->writeFieldBegin('comments', TType::STRING, 21);
$xfer += $output->writeString($this->comments);
$xfer += $output->writeFieldEnd();
}
if ($this->labeledURI !== null) {
if (!is_array($this->labeledURI)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('labeledURI', TType::LST, 22);
{
$output->writeListBegin(TType::STRING, count($this->labeledURI));
{
foreach ($this->labeledURI as $iter48)
{
$xfer += $output->writeString($iter48);
}
}
$output->writeListEnd();
}
$xfer += $output->writeFieldEnd();
}
if ($this->gpgKey !== null) {
$xfer += $output->writeFieldBegin('gpgKey', TType::STRING, 23);
$xfer += $output->writeString($this->gpgKey);
$xfer += $output->writeFieldEnd();
}
if ($this->timeZone !== null) {
$xfer += $output->writeFieldBegin('timeZone', TType::STRING, 24);
$xfer += $output->writeString($this->timeZone);
$xfer += $output->writeFieldEnd();
}
if ($this->nsfDemographics !== null) {
if (!is_object($this->nsfDemographics)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('nsfDemographics', TType::STRUCT, 25);
$xfer += $this->nsfDemographics->write($output);
$xfer += $output->writeFieldEnd();
}
if ($this->customDashboard !== null) {
if (!is_object($this->customDashboard)) {
throw new TProtocolException('Bad type in structure.', TProtocolException::INVALID_DATA);
}
$xfer += $output->writeFieldBegin('customDashboard', TType::STRUCT, 26);
$xfer += $this->customDashboard->write($output);
$xfer += $output->writeFieldEnd();
}
$xfer += $output->writeFieldStop();
$xfer += $output->writeStructEnd();
return $xfer;
}
}
final class Constant extends \Thrift\Type\TConstant {
static protected $USER_PROFILE_VERSION;
static protected function init_USER_PROFILE_VERSION() {
return "1.0";
}
}