Automattic\WooCommerce\StoreApi\Schemas\V1
CheckoutSchema::__construct
Constructor.
Method of the class: CheckoutSchema{}
No Hooks.
Returns
null. Nothing (null).
Usage
$CheckoutSchema = new CheckoutSchema(); $CheckoutSchema->__construct( $extend, $controller );
- $extend(ExtendSchema) (required)
- Rest Extending instance.
- $controller(SchemaController) (required)
- Schema Controller instance.
CheckoutSchema::__construct() CheckoutSchema:: construct code WC 10.6.2
public function __construct( ExtendSchema $extend, SchemaController $controller ) {
parent::__construct( $extend, $controller );
$this->billing_address_schema = $this->controller->get( BillingAddressSchema::IDENTIFIER );
$this->shipping_address_schema = $this->controller->get( ShippingAddressSchema::IDENTIFIER );
$this->image_attachment_schema = $this->controller->get( ImageAttachmentSchema::IDENTIFIER );
$this->cart_schema = $this->controller->get( CartSchema::IDENTIFIER );
$this->additional_fields_controller = Package::container()->get( CheckoutFields::class );
}