refactor(ivy): rename LQuery to LQueries and associated renames (#21857)

PR Close #21857
This commit is contained in:
Pawel Kozlowski
2018-01-29 14:51:37 +01:00
committed by Jason Aden
parent 285dd6be34
commit 7305e8b45e
7 changed files with 58 additions and 58 deletions

View File

@ -8,7 +8,7 @@
import {ComponentTemplate} from './definition';
import {LElementNode, LViewNode} from './node';
import {LQuery} from './query';
import {LQueries} from './query';
import {LView, TView} from './view';
@ -79,7 +79,7 @@ export interface LContainer {
* Queries active for this container - all the views inserted to / removed from
* this container are reported to queries referenced here.
*/
query: LQuery|null;
queries: LQueries|null;
}
/**

View File

@ -7,10 +7,9 @@
*/
import {LContainer, TContainer} from './container';
import {DirectiveDef} from './definition';
import {LInjector} from './injector';
import {LProjection} from './projection';
import {LQuery} from './query';
import {LQueries} from './query';
import {RElement, RNode, RText} from './renderer';
import {LView, TData, TView} from './view';
@ -116,11 +115,11 @@ export interface LNode {
nodeInjector: LInjector|null;
/**
* Optional `QueryState` used for tracking queries.
* Optional set of queries that track query-related events for this node.
*
* If present the node creation/updates are reported to the `QueryState`.
* If present the node creation/updates are reported to the `LQueries`.
*/
query: LQuery|null;
queries: LQueries|null;
/**
* If this node is projected, pointer to the next node in the same projection parent

View File

@ -12,36 +12,36 @@ import {LNode} from './node';
/** Used for tracking queries (e.g. ViewChild, ContentChild). */
export interface LQuery {
export interface LQueries {
/**
* Used to ask query if it should be cloned to the child element.
* Used to ask queries if those should be cloned to the child element.
*
* For example in the case of deep queries the `child()` returns
* query for the child node. In case of shallow queries it returns
* queries for the child node. In case of shallow queries it returns
* `null`.
*/
child(): LQuery|null;
child(): LQueries|null;
/**
* Notify `LQuery` that a new `LNode` has been created and needs to be added to query results
* Notify `LQueries` that a new `LNode` has been created and needs to be added to query results
* if matching query predicate.
*/
addNode(node: LNode): void;
/**
* Notify `LQuery` that a `LNode` has been created and needs to be added to query results
* Notify `LQueries` that a `LNode` has been created and needs to be added to query results
* if matching query predicate.
*/
container(): LQuery|null;
container(): LQueries|null;
/**
* Notify `LQuery` that a new view was created and is being entered in the creation mode.
* Notify `LQueries` that a new view was created and is being entered in the creation mode.
* This allow queries to prepare space for matching nodes from views.
*/
enterView(newViewIndex: number): LQuery|null;
enterView(newViewIndex: number): LQueries|null;
/**
* Notify `LQuery` that an `LViewNode` has been removed from `LContainerNode`. As a result all
* Notify `LQueries` that an `LViewNode` has been removed from `LContainerNode`. As a result all
* the matching nodes from this view should be removed from container's queries.
*/
removeView(removeIndex: number): void;

View File

@ -9,7 +9,7 @@
import {LContainer} from './container';
import {ComponentTemplate, DirectiveDef} from './definition';
import {LElementNode, LViewNode, TNode} from './node';
import {LQuery} from './query';
import {LQueries} from './query';
import {Renderer3} from './renderer';
@ -175,7 +175,7 @@ export interface LView {
/**
* Queries active for this view - nodes from a view are reported to those queries
*/
query: LQuery|null;
queries: LQueries|null;
}
/** Interface necessary to work with view tree traversal */