Automattic\WooCommerce\Internal\ProductAttributesLookup

LookupDataStore::is_variation()privateWC 1.0

Check if a given product is a variation.

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

No Hooks.

Return

true|false. True if it's a variation, false otherwise.

Usage

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

Код LookupDataStore::is_variation() WC 7.1.0

private function is_variation( \WC_Product $product ) {
	return is_a( $product, \WC_Product_Variation::class );
}