List.createFiltered method

1 out of 7 rated this helpful - Rate this topic

Creates a live filtered projection over this list. As the list changes, the filtered projection reacts to those changes and may also change.

Syntax


var filteredListProjection = list.createFiltered(predicate);

Parameters

predicate

Type: Function

A function that accepts a single argument. The createFiltered function calls the callback with each element in the list. If the function returns true, that element will be included in the filtered list.

This function must always return the same results, given the same inputs. The results should not depend on values that are subject to change. You must call notifyMutated each time an item changes. Do not batch change notifications.

Return value

Type: FilteredListProjection

A filtered projection over the list.

Requirements

Namespace

WinJS.Binding

Library

Base.js

See also

List

 

 

Build date: 12/5/2012

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.