You are here

function search_api_extract_inner_type in Search API 7

Utility function for extracting the contained primitive type of a list type.

Parameters

$type: A string containing the list type to process.

Return value

string A string containing the primitive type contained within the list, e.g. "text" for "list<text>" (or for "list<list<text>>"). If $type is no list type, it is returned unchanged.

11 calls to search_api_extract_inner_type()
SearchApiAlterAddHierarchy::configurationFormSubmit in includes/callback_add_hierarchy.inc
Implements SearchApiAlterCallbackInterface::configurationFormSubmit().
SearchApiAlterAddHierarchy::getHierarchicalFields in includes/callback_add_hierarchy.inc
Finds all hierarchical fields for the current index.
SearchApiAlterAddHierarchy::propertyInfo in includes/callback_add_hierarchy.inc
Implements SearchApiAlterCallbackInterface::propertyInfo().
SearchApiIndex::getFields in includes/index_entity.inc
Returns a list of all known fields for this index.
SearchApiIndex::index in includes/index_entity.inc
Indexes items on this index.

... See full list

File

./search_api.module, line 2401
Provides a flexible framework for implementing search services.

Code

function search_api_extract_inner_type($type) {
  while (search_api_is_list_type($type)) {
    $type = substr($type, 5, -1);
  }
  return $type;
}