EN
이 콘텐츠는 한국어로 제공되지 않아 영어 버전으로 표시됩니다.

WinJS.UI.Repeater object

Applies to Windows and Windows Phone

Generates HTML from a set of data. Use this control to generate lists of items.

Syntax


<div 
    data-win-control="WinJS.UI.Repeater">
</div>


var object = new WinJS.UI.Repeater();

Members

The Repeater object has these types of members:

Constructors

The Repeater object has these constructors.

ConstructorDescription
Repeater

Creates a new Repeater control.

 

Events

The Repeater object has these events.

EventDescription
onitemchanged

Raised after an item in the Repeater control's data source changes and after the corresponding DOM element has been updated.

onitemchanging

Raised after an item in the Repeater control's data source changes but before the corresponding DOM element has been updated.

oniteminserted

Raised after an item has been added to the Repeater control's data source and after the corresponding DOM element has been added.

oniteminserting

Raised after an item has been added to the Repeater control's data source but before the corresponding DOM element has been added.

onitemmoved

Raised after an item has been moved from one index to another in the Repeater control's data source and after the corresponding DOM element has been moved.

onitemmoving

Raised after an item has been moved from one index to another in the Repeater control's data source but before the corresponding DOM element has been moved.

onitemremoved

Raised after an item has been removed from the Repeater control's data source and after the corresponding DOM element has been removed.

onitemremoving

Raised after an item has been removed from the Repeater control's data source but before the corresponding DOM element has been removed.

onitemsloaded

Raised when the Repeater has finished loading a new set of data. This event is only fired on construction. This event is only raised when the Repeater is constructed or its data source or template changes.

onitemsreloaded

Raised after the Repeater control's underlying data has been updated and after the updated HTML has been reloaded.

onitemsreloading

Raised after the Repeater control's underlying data has been updated but before the updated HTML has been reloaded.

 

Methods

The Repeater object has these methods.

MethodDescription
addEventListener

Registers an event handler for the specified event.

dispatchEvent

Raises an event of the specified type and with additional properties.

dispose

Releases resources held by this Repeater. Call this method when the Repeater is no longer needed. After calling this method, the Repeater becomes unusable.

elementFromIndex

Returns the HTML element for the item at the specified index.

removeEventListener

Removes an event handler that the addEventListener method registered.

 

Properties

The Repeater object has these properties.

PropertyAccess typeDescription

data

Read/write

Gets or sets the List that provides the Repeater with items to display.

element

Read-only

Gets the DOM element that hosts the Repeater.

length

Read-only

Gets the number of items in the Repeater control.

template

Read/write

Gets or sets a WinJS.Binding.Template or custom rendering function that defines the HTML of each item within the Repeater.

 

Requirements

Minimum supported client

Windows 8.1 [Windows Store apps only]

Minimum supported server

Windows Server 2012 R2 [Windows Store apps only]

Minimum supported phone

Windows Phone 8.1

Namespace

WinJS.UI

Library

Ui.js

 

 

표시:
© 2014 Microsoft