Page MenuHomeGitPull.it
Diviner Javelin Docs JX.TypeaheadSource

class JX.TypeaheadSource
Javelin Documentation ()

This class is not documented.

Tasks

Builtin Events

  • invoke(type, more) — Invoke a class event, notifying all listeners. You must declare the events your class invokes when you install it; see @{function:JX.install} for documentation. Any arguments you provide will be passed to listener callbacks.
  • static listen(type, callback) — Static listen interface for listening to events produced by any instance of this class. See @{method:listen} for documentation.

Other Methods

Methods

invoke(type, more)
Inherited

JX.Base

Invoke a class event, notifying all listeners. You must declare the events your class invokes when you install it; see JX.install() for documentation. Any arguments you provide will be passed to listener callbacks.

Parameters
stringtypeEvent type, must be declared when class is installed.
...moreZero or more arguments.
Return
JX.EventEvent object which was dispatched.

static listen(type, callback)
Inherited

JX.Base

Listen for events emitted by this object instance. You can also use the static flavor of this method to listen to events emitted by any instance of this object.

See also listen() in JX.Stratcom.

JX.Base

Static listen interface for listening to events produced by any instance of this class. See listen() for documentation.

Parameters
stringtypeType of event to listen for.
functioncallbackFunction to call when this event occurs.
Return
objectA reference to the installed listener. You can later remove the listener by calling this object's remove() method.
This method is not documented.

bindToTypeahead(typeahead)

Optional function which is used to filter results before display. Inputs are the input string and a list of matches. The function should return a list of matches to display. This is the minimum useful implementation:

function(value, list) {
  return list;
}
Parameters
functiontypeahead
This method is not documented.
This method is not documented.
This method is not documented.
This method is not documented.
This method is not documented.
Parameters
id
This method is not documented.
Parameters
id
This method is not documented.
Parameters
obj
This method is not documented.

Get the raw state of a result by its ID. A number of other events and mechanisms give a list of result IDs and limited additional data; if you need to act on the full result data you can look it up here.

Parameters
scalaridResult ID.
Return
dictCorresponding raw result.

matchResults(value, partial)

This method is not documented.
Parameters
value
partial

filterAndSortHits(value, hits)

This method is not documented.
Parameters
value
hits

renderNodes(value, hits)

This method is not documented.
Parameters
value
hits
This method is not documented.
Parameters
data
This method is not documented.
Parameters
str
This method is not documented.
Parameters
str
This method is not documented.

private _defaultTransformer(object)

This method is not documented.
Parameters
object