WordPress at Your Fingertips
function is not described

Automattic\WooCommerce\Internal\ProductAttributesLookup

LookupDataStore::get_term_ids_by_slug_cache() private WC 1.0

Get a cache of term ids by slug for a set of taxonomies, with this format:

[ 'taxonomy' => [

'slug_1' => id_1,
'slug_2' => id_2,
...

], ... ]

{} It's a method of the class: LookupDataStore{}

No Hooks.

Return

Array. A dictionary of taxonomies => dictionary of term slug => term id.

Usage

// private - for code of main (parent) class only
$result = $this->get_term_ids_by_slug_cache( $taxonomies );
$taxonomies(array) (required)
List of taxonomies to build the cache for.

Code of LookupDataStore::get_term_ids_by_slug_cache() WC 5.9.0

private function get_term_ids_by_slug_cache( $taxonomies ) {
	$result = array();
	foreach ( $taxonomies as $taxonomy ) {
		$terms               = WC()->call_function(
			'get_terms',
			array(
				'taxonomy'   => $taxonomy,
				'hide_empty' => false,
				'fields'     => 'id=>slug',
			)
		);
		$result[ $taxonomy ] = array_flip( $terms );
	}
	return $result;
}