<?php
declare(strict_types=1);

// THIS FILE IS AUTO-GENERATED. DO NOT EDIT MANUALLY.

namespace Automattic\WooCommerce\Internal\Api\Autogenerated\GraphQLTypes\Enums;

use Automattic\WooCommerce\Api\Enums\Coupons\DiscountType as DiscountTypeEnum;
use Automattic\WooCommerce\Api\Infrastructure\Schema\EnumType;

class DiscountType {
	private static ?EnumType $instance = null;

	public static function get(): EnumType {
		if ( null === self::$instance ) {
			self::$instance = new EnumType(
				array(
					'name'        => 'DiscountType',
					'description' => __( 'The type of discount for a coupon.', 'woocommerce' ),
					'values'      => array(
						'PERCENT'       => array(
							'value'       => DiscountTypeEnum::Percent,
							'description' => __( 'A percentage discount.', 'woocommerce' ),
						),
						'FIXED_CART'    => array(
							'value'       => DiscountTypeEnum::FixedCart,
							'description' => __( 'A fixed amount discount applied to the cart.', 'woocommerce' ),
						),
						'FIXED_PRODUCT' => array(
							'value'       => DiscountTypeEnum::FixedProduct,
							'description' => __( 'A fixed amount discount applied to each eligible product.', 'woocommerce' ),
						),
						'OTHER'         => array(
							'value'       => DiscountTypeEnum::Other,
							'description' => __( 'The discount type is not one of the standard WooCommerce values (e.g. added by a plugin). Inspect raw_discount_type for the underlying value.', 'woocommerce' ),
						),
					),
				)
			);
		}
		return self::$instance;
	}
}
