WordPress at Your Fingertips
function is not described

WC_Data::__construct() public WC 1.0

Default constructor.

{} It's a method of the class: WC_Data{}

No Hooks.

Return

null. Nothing.

Usage

$WC_Data = new WC_Data();
$WC_Data->__construct( $read );
$read(int|object|array)
ID to load from the DB (optional) or already queried data.

Code of WC_Data::__construct() WC 5.5.2

<?php
public function __construct( $read = 0 ) {
	$this->data         = array_merge( $this->data, $this->extra_data );
	$this->default_data = $this->data;
}