WordPress как на ладони
Недорогой хостинг для сайтов на WordPress: wordpress.jino.ru
функция не описана

enqueue_package_class() WC 1.0

Adds the version of a package to the $jetpack_packages global array so that the autoloader is able to find it.

Хуков нет.

Возвращает

Null. Ничего.

Использование

enqueue_package_class( $class_name, $version, $path );
$class_name(строка) (обязательный)
Name of the class that you want to autoload.
$version(строка) (обязательный)
Version of the class.
$path(строка) (обязательный)
Absolute path to the class so that we can load it.

Код enqueue package class: woocommerce/packages/woocommerce-admin/vendor/autoload_packages.php WC 4.3.1

<?php
function enqueue_package_class( $class_name, $version, $path ) {
	global $jetpack_packages_classes;

	if ( ! isset( $jetpack_packages_classes[ $class_name ] ) ) {
		$jetpack_packages_classes[ $class_name ] = array(
			'version' => $version,
			'path'    => $path,
		);

		return;
	}
	// If we have a @dev version set always use that one!
	if ( 'dev-' === substr( $jetpack_packages_classes[ $class_name ]['version'], 0, 4 ) ) {
		return;
	}

	// Always favour the @dev version. Since that version is the same as bleeding edge.
	// We need to make sure that we don't do this in production!
	if ( 'dev-' === substr( $version, 0, 4 ) ) {
		$jetpack_packages_classes[ $class_name ] = array(
			'version' => $version,
			'path'    => $path,
		);

		return;
	}
	// Set the latest version!
	if ( version_compare( $jetpack_packages_classes[ $class_name ]['version'], $version, '<' ) ) {
		$jetpack_packages_classes[ $class_name ] = array(
			'version' => $version,
			'path'    => $path,
		);
	}
}