UNPKG

@spalger/kibana

Version:

Kibana is an open source (Apache Licensed), browser based analytics and search dashboard for Elasticsearch. Kibana is a snap to setup and start using. Kibana strives to be easy to get started with, while also being flexible and powerful, just like Elastic

29 lines (24 loc) 947 B
define(function (require) { return function CourierSegmentedReqHandle(Private) { var _ = require('lodash'); var Events = Private(require('ui/events')); /** * Simple class for creating an object to send to the * requester of a SegmentedRequest. Since the SegmentedRequest * extends AbstractRequest, it wasn't able to be the event * emitter it was born to be. This provides a channel for * setting values on the segmented request, and an event * emitter for the request to speak outwardly * * @param {SegmentedRequest} - req - the requst this handle relates to */ _.class(SegmentedHandle).inherits(Events); function SegmentedHandle(req) { SegmentedHandle.Super.call(this); // export a couple methods from the request this.setDirection = _.bindKey(req, 'setDirection'); this.setSize = _.bindKey(req, 'setSize'); } return SegmentedHandle; }; });