WC_Order_Factory::get_class_name_for_order_id()
Gets the class name an order instance should have based on its ID.
Метод класса: WC_Order_Factory{}
Хуков нет.
Возвращает
Строку
. The class name or FALSE if the class does not exist.
Использование
$result = WC_Order_Factory::get_class_name_for_order_id( $order_id );
- $order_id(int) (обязательный)
- The order ID.
Список изменений
С версии 6.9.0 | Введена. |
Код WC_Order_Factory::get_class_name_for_order_id() WC Order Factory::get class name for order id WC 9.4.2
private static function get_class_name_for_order_id( $order_id ) { $classname = self::get_class_names_for_order_ids( array( $order_id ) ); return $classname[ $order_id ] ?? false; }