switch ($xmlrpcVal->kindOf()) {
case 'scalar':
if (in_array('extension_api', $options)) {
- $val = reset($xmlrpcVal->me);
- $typ = key($xmlrpcVal->me);
+ $val = $xmlrpcVal->scalarVal();
+ $typ = $xmlrpcVal->scalarTyp();
switch ($typ) {
case 'dateTime.iso8601':
$xmlrpcVal = array(
return $this->val;
}
+ /**
+ * @return string
+ */
+ public function valueType()
+ {
+ return $this->valtyp;
+ }
+
/**
* Returns an array with the cookies received from the server.
* Array has the form: $cookiename => array ('value' => $val, $attr1 => $val1, $attr2 => $val2, ...)
/** @var Value[]|mixed */
public $me = array();
/**
- * @var int
+ * @var int 0 for undef, 1 for scalar, 2 for array, 3 for struct
* @internal
*/
public $mytype = 0;
$expect_array = array('ctLeftAngleBrackets', 'ctRightAngleBrackets', 'ctAmpersands', 'ctApostrophes', 'ctQuotes');
foreach($expect_array as $val) {
$b = $v->structmem($val);
- $got .= $b->me['int'];
+ $got .= $b->scalarVal();
}
$this->assertEquals($expected, $got);
}