You are here

class FacetapiTestNonterm in Facet API 7.2

Same name and namespace in other branches
  1. 7 tests/facetapi_test.plugins.inc \FacetapiTestNonterm

Plugin for "nonterm" query type.

Hierarchy

Expanded class hierarchy of FacetapiTestNonterm

1 string reference to 'FacetapiTestNonterm'
facetapi_test_facetapi_query_types in tests/facetapi_test.facetapi.inc
Implements hook_facetapi_query_types().

File

tests/facetapi_test.plugins.inc, line 105
Test adapter and plugins.

View source
class FacetapiTestNonterm extends FacetapiQueryType implements FacetapiQueryTypeInterface {

  /**
   * Implements FacetapiQueryTypeInterface::getType().
   */
  public static function getType() {
    return 'nonterm';
  }

  /**
   * Implements FacetapiQueryTypeInterface::execute().
   */
  public function execute($query) {

    // Nothing to do...
  }

  /**
   * Implements FacetapiQueryTypeInterface::build().
   */
  public function build() {
    $build = array();
    $build['testfour'] = array(
      '#count' => 4,
    );
    $build['testsix'] = array(
      '#count' => 6,
    );
    $build['testfive'] = array(
      '#count' => 5,
    );

    // Returns initialized build.
    return $build;
  }

}

Members

Namesort descending Modifiers Type Description Overrides
FacetapiQueryType::$adapter protected property The adapter associated with facet being queried.
FacetapiQueryType::$facet protected property The facet definition as returned by facetapi_facet_load().
FacetapiQueryType::extract public function Adds additional information to the array active items. 2
FacetapiQueryType::getActiveItems public function Returns the facet's active items.
FacetapiQueryType::getSettings public function Convenience method to get the facet's global and per realm settings.
FacetapiQueryType::__construct public function Constructs a FacetapiQueryType object. 1
FacetapiTestNonterm::build public function Implements FacetapiQueryTypeInterface::build(). Overrides FacetapiQueryTypeInterface::build
FacetapiTestNonterm::execute public function Implements FacetapiQueryTypeInterface::execute(). Overrides FacetapiQueryTypeInterface::execute
FacetapiTestNonterm::getType public static function Implements FacetapiQueryTypeInterface::getType(). Overrides FacetapiQueryTypeInterface::getType