WordPress\AiClient\Tools\DTO
FunctionCall::__construct
Constructor.
Method of the class: FunctionCall{}
No Hooks.
Returns
null. Nothing (null).
Usage
$FunctionCall = new FunctionCall(); $FunctionCall->__construct( ?string $id, ?string $name, $args );
- ?string $id
- .
Default:null - ?string $name
- .
Default:null - $args(mixed)
- The arguments to pass to the function.
Default:null
Changelog
| Since 0.1.0 | Introduced. |
FunctionCall::__construct() FunctionCall:: construct code WP 7.0
public function __construct(?string $id = null, ?string $name = null, $args = null)
{
if ($id === null && $name === null) {
throw new InvalidArgumentException('At least one of id or name must be provided.');
}
$this->id = $id;
$this->name = $name;
$this->args = $args;
}