WordPress\AiClient\Results\DTO

Candidate::toArraypublicWP 0.1.0

{@inheritDoc}

Method of the class: Candidate{}

No Hooks.

Returns

CandidateArrayShape.

Usage

$Candidate = new Candidate();
$Candidate->toArray(): array;

Changelog

Since 0.1.0 Introduced.

Candidate::toArray() code WP 7.0

public function toArray(): array
{
    return [self::KEY_MESSAGE => $this->message->toArray(), self::KEY_FINISH_REASON => $this->finishReason->value];
}