Skip to content

Soap parameter type DateTime on wsdl #52

@fregian

Description

@fregian

Hello,
i have generated class by wsdltophp and all is ok, but now I need to use a method that requires two parameters of type DateTme and defined in the wsdl as:
<xs:element name="arg4" type="xs:dateTime" minOccurs="0" />
<xs:element name="arg5" type="xs:dateTime" minOccurs="0" />
The method generated by wsdltophp defines ar4 and arg5 as string.
Whatever value I pass to the method, the ws receives NULL,
How can I solve?

this is the code on generated class:
/**
* Set arg4 value
* @param string $arg4
* @return \StructType\GetDocumentIdsList
*/
public function setArg4($arg4 = null)
{
// validation for constraint: string
if (!is_null($arg4) && !is_string($arg4)) {
throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($arg4, true), gettype($arg4)), LINE);
}
$this->arg4 = $arg4;
return $this;
}

/**
* Set arg5 value
* @param string $arg5
* @return \StructType\GetDocumentIdsList
*/
public function setArg5($arg5 = null)
{
// validation for constraint: string
if (!is_null($arg5) && !is_string($arg5)) {
throw new \InvalidArgumentException(sprintf('Invalid value %s, please provide a string, %s given', var_export($arg5, true), gettype($arg5)), LINE);
}
$this->arg5 = $arg5;
return $this;
}

Thank you and excuse for my bad english

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions