Automattic\WooCommerce\Internal\ProductAttributesLookup

LookupDataStore::create_data_for()privateWC 1.0

Create lookup table data for a given product.

Метод класса: LookupDataStore{}

No Hooks.

Return

null. Nothing.

Usage

// private - for code of main (parent) class only
$result = $this->create_data_for( $product );
$product(\WC_Product) (required)
The product to create the data for.

Код LookupDataStore::create_data_for() WC 7.1.0

private function create_data_for( \WC_Product $product ) {
	if ( $this->is_variation( $product ) ) {
		$this->create_data_for_variation( $product );
	} elseif ( $this->is_variable_product( $product ) ) {
		$this->create_data_for_variable_product( $product );
	} else {
		$this->create_data_for_simple_product( $product );
	}
}