Homec4science

Begin modularizing typeahead sources

Authored by epriestley <git@epriestley.com> on Feb 14 2014, 19:23.

Description

Begin modularizing typeahead sources

Summary:
Ref T4420. This sets up the basics for modular typeahead sources. Basically, the huge switch() is just replaced with class-based runtime dispatch.

The only clever bit I'm doing here is with CompositeDatasource, which pretty much just combines the results from several other datasources. We can use this to implement some of the weird cases where we need multiple types of results, although I think I can entirely eliminate many of them entirely. It also makes top-level implementation simpler, since more logic can go inside the sources.

Sources are also application-aware, will be responsible for placeholder text, and have a slightly nicer debug view.

Test Plan: {F112859}

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T4420

Differential Revision: https://secure.phabricator.com/D8228

Details

Committed
epriestley <git@epriestley.com>Feb 14 2014, 19:23
Pushed
aubortJan 31 2017, 17:16
Parents
rPH7a96de10f07a: Hide seen transactions by default in all modern applications
Branches
Unknown
Tags
Unknown

Event Timeline

epriestley <git@epriestley.com> committed rPH75c4a185a9f1: Begin modularizing typeahead sources (authored by epriestley <git@epriestley.com>).Feb 14 2014, 19:23