Same name and namespace in other branches
  1. 6.x-3.x includes/view.inc \views_object_types()

Provide a list of object types used in a view, with some info about them.

Related topics

33 calls to views_object_types()
view::destroy in includes/view.inc
Unset references so that a $view object may be properly garbage collected.
view::fix_missing_relationships in includes/view.inc
Attempt to discover if the view has handlers missing relationships.
view::init_handlers in includes/view.inc
Acquire and attach all of the handlers.
view::_post_execute in includes/view.inc
Run the post_execute() on all active handlers.
view::_pre_query in includes/view.inc
Run the pre_query() on all active handlers.

... See full list

File

includes/view.inc, line 2657
views_objects Objects that represent a View or part of a view

Code

function views_object_types() {
  static $retval = NULL;

  // Statically cache this so t() doesn't run a bajillion times.
  if (!isset($retval)) {
    $retval = array(
      'field' => array(
        // Title.
        'title' => t('Fields'),
        // Lowercase title for mid-sentence.
        'ltitle' => t('fields'),
        // Singular title.
        'stitle' => t('Field'),
        // Lingular lowercase title for mid sentence.
        'lstitle' => t('field'),
        'plural' => 'fields',
      ),
      'argument' => array(
        'title' => t('Contextual filters'),
        'ltitle' => t('contextual filters'),
        'stitle' => t('Contextual filter'),
        'lstitle' => t('contextual filter'),
        'plural' => 'arguments',
      ),
      'sort' => array(
        'title' => t('Sort criteria'),
        'ltitle' => t('sort criteria'),
        'stitle' => t('Sort criterion'),
        'lstitle' => t('sort criterion'),
        'plural' => 'sorts',
      ),
      'filter' => array(
        'title' => t('Filter criteria'),
        'ltitle' => t('filter criteria'),
        'stitle' => t('Filter criterion'),
        'lstitle' => t('filter criterion'),
        'plural' => 'filters',
      ),
      'relationship' => array(
        'title' => t('Relationships'),
        'ltitle' => t('relationships'),
        'stitle' => t('Relationship'),
        'lstitle' => t('Relationship'),
        'plural' => 'relationships',
      ),
      'header' => array(
        'title' => t('Header'),
        'ltitle' => t('header'),
        'stitle' => t('Header'),
        'lstitle' => t('Header'),
        'plural' => 'header',
        'type' => 'area',
      ),
      'footer' => array(
        'title' => t('Footer'),
        'ltitle' => t('footer'),
        'stitle' => t('Footer'),
        'lstitle' => t('Footer'),
        'plural' => 'footer',
        'type' => 'area',
      ),
      'empty' => array(
        'title' => t('No results behavior'),
        'ltitle' => t('no results behavior'),
        'stitle' => t('No results behavior'),
        'lstitle' => t('No results behavior'),
        'plural' => 'empty',
        'type' => 'area',
      ),
    );
  }
  return $retval;
}