You are here

protected function Range::defineOptions in Range 8

Same name in this branch
  1. 8 src/Plugin/views/filter/Range.php \Drupal\range\Plugin\views\filter\Range::defineOptions()
  2. 8 src/Plugin/views/argument/Range.php \Drupal\range\Plugin\views\argument\Range::defineOptions()

Information about options for all kinds of purposes will be held here.


'option_name' => array(
 - 'default' => default value,
 - 'contains' => (optional) array of items this contains, with its own
     defaults, etc. If contains is set, the default will be ignored and
     assumed to be array().
 ),

Return value

array Returns the options of this handler/plugin.

Overrides ArgumentPluginBase::defineOptions

File

src/Plugin/views/argument/Range.php, line 23

Class

Range
Range views argument.

Namespace

Drupal\range\Plugin\views\argument

Code

protected function defineOptions() {
  $options = parent::defineOptions();
  $options['operator'] = [
    'default' => 'within',
    'bool' => FALSE,
  ];
  $options['include_endpoints'] = [
    'default' => FALSE,
    'bool' => TRUE,
  ];
  return $options;
}