Overview

Namespaces

  • elasticsearch

Classes

  • Config
  • Defaults
  • Faceting
  • Indexer
  • Searcher
  • Overview
  • Namespace
  • Class
  • Tree

Class Config

This class provides a convenient way of accessing configuration values set through the plugin's admin interface.

Namespace: elasticsearch
License: http://opensource.org/licenses/MIT
Author: Paris Holley <mail@parisholley.com>
Version: 2.0.0
Located at Config.php
Methods summary
public static object
# option( string $name )

Retrieve a specific option from the wordpress database for this plugin. Note: This is cached once per request.

Retrieve a specific option from the wordpress database for this plugin. Note: This is cached once per request.

Parameters

$name
string
$name The name of the option

Returns

object
public static integer
# score( string $type, string $name )

The score given to a data point that determines the impact on search results. May return null if the setttings have not been saved.

The score given to a data point that determines the impact on search results. May return null if the setttings have not been saved.

Parameters

$type
string
$type The type of wordpress object that is being scored (tax|field)
$name
string
$name The slug and/or logical name of that type

Returns

integer
public static array
# ranges( string $field )

The numeric ranges that have been defined for a certain field. Example of output:

array(
        '-10' => array(
                'to' => 10
        ),
        '10-20' => array(
                'from' => 10,
                'to' => 20
        )
)

The numeric ranges that have been defined for a certain field. Example of output:

array(
        '-10' => array(
                'to' => 10
        ),
        '10-20' => array(
                'from' => 10,
                'to' => 20
        )
)

Parameters

$field
string
$field The field name to lookup

Returns

array
An associative array where the keys represent a slug and values are used for configuration.
public static
# apply_filters( )

Behaves exactly like the wordpress apply_filters method except it prefixes every filter with a convention used by this plugin (ie: 'es_').

Behaves exactly like the wordpress apply_filters method except it prefixes every filter with a convention used by this plugin (ie: 'es_').

public static string[]
# fields( )

A list of a fields that are included when indexing data.

A list of a fields that are included when indexing data.

Returns

string[]
field names
public static string[]
# facets( )

A list of data points that are used for faceting.

A list of data points that are used for faceting.

Returns

string[]
field and/or association names
public static string[]
# types( )

A list of wordpress post types that are used for indexing.

A list of wordpress post types that are used for indexing.

Returns

string[]
post type slugs
public static string[]
# taxonomies( )

A list of taxonomies that are used for indexing.

A list of taxonomies that are used for indexing.

Returns

string[]
taxonomy slugs
API documentation generated by ApiGen 2.8.0