yii\mail\MessageInterface::setTo PHP Method

setTo() public method

Sets the message recipient(s).
public setTo ( string | array $to )
$to string | array receiver email address. You may pass an array of addresses if multiple recipients should receive this message. You may also specify receiver name in addition to email address using format: `[email => name]`.
    public function setTo($to);