Automattic\WooCommerce\Internal\Api\Autogenerated\GraphQLTypes\Enums
ProductType{}
No Hooks.
Usage
$ProductType = new ProductType(); // use class methods
Methods
- public static get()
- ERROR: no method name found on line ``
ProductType{} ProductType{} code WC 10.9.1
class ProductType {
private static ?EnumType $instance = null;
public static function get(): EnumType {
if ( null === self::$instance ) {
self::$instance = new EnumType(
array(
'name' => 'ProductType',
'description' => __( 'The type of a WooCommerce product.', 'woocommerce' ),
'values' => array(
'SIMPLE' => array(
'value' => ProductTypeEnum::Simple,
'description' => __( 'A simple product.', 'woocommerce' ),
),
'GROUPED' => array(
'value' => ProductTypeEnum::Grouped,
'description' => __( 'A grouped product.', 'woocommerce' ),
),
'EXTERNAL' => array(
'value' => ProductTypeEnum::External,
'description' => __( 'An external/affiliate product.', 'woocommerce' ),
),
'VARIABLE' => array(
'value' => ProductTypeEnum::Variable,
'description' => __( 'A variable product with variations.', 'woocommerce' ),
),
'VARIATION' => array(
'value' => ProductTypeEnum::Variation,
'description' => __( 'A product variation.', 'woocommerce' ),
),
'OTHER' => array(
'value' => ProductTypeEnum::Other,
'description' => __( 'The product type is not one of the standard WooCommerce values (e.g. added by a plugin). Inspect raw_product_type for the underlying value.', 'woocommerce' ),
),
),
)
);
}
return self::$instance;
}
}