Automattic\WooCommerce\Internal\Admin\EmailPreview

PreviewOrder::__constructpublicWC 1.0

Constructor.

Method of the class: PreviewOrder{}

No Hooks.

Returns

null. Nothing (null).

Usage

$PreviewOrder = new PreviewOrder();
$PreviewOrder->__construct( $order );
$order(int|object|WC_Order)
Order to read.
Default: 0 (a new, empty order)

PreviewOrder::__construct() code WC 10.9.1

public function __construct( $order = 0 ) {
	parent::__construct( $order );

	foreach ( $this->item_types_to_group as $group ) {
		$this->items[ $group ] = array();
	}
	$this->meta_data = array();
}