Automattic\WooCommerce\Internal\StockNotifications\Frontend
SignupResult{}
A class for representing the result of a signup.
No Hooks.
Usage
$SignupResult = new SignupResult(); // use class methods
Methods
- public __construct( string $code, ?Notification $notification = null )
- public get_code()
- public get_notification()
SignupResult{} SignupResult{} code WC 10.3.6
class SignupResult {
/**
* The signup code.
*
* @var string
*/
private string $code;
/**
* The notification.
*
* @var Notification|null
*/
private ?Notification $notification;
/**
* Constructor.
*
* @param string $code The signup code.
* @param Notification|null $notification The notification.
*/
public function __construct( string $code, ?Notification $notification = null ) {
$this->code = $code;
$this->notification = $notification;
}
/**
* Get the signup code.
*
* @return string
*/
public function get_code(): string {
return $this->code;
}
/**
* Get the notification.
*
* @return Notification|null
*/
public function get_notification(): ?Notification {
return $this->notification;
}
}