DataModelEvent (Java EE 5)

Java EE API


javax.faces.model Class DataModelEvent

java.lang.Object
  extended by java.util.EventObject
      extended by javax.faces.model.DataModelEvent
All Implemented Interfaces:
Serializable

public class DataModelEvent
extends EventObject

Extends: java.util.EventObject

DataModelEvent 表示在指定的 DataModel 上发生了已注册侦听器感兴趣的事件。

英文文档:

DataModelEvent represents an event of interest to registered listeners that occurred on the specified DataModel.

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.util.EventObject
 
Constructor Summary
 
Method Summary
 DataModel
 Object
 int
 
Methods inherited from class java.util.EventObject
 
Methods inherited from class java.lang.Object
 

Constructor Detail

public DataModelEvent(DataModel model, int index, Object data)

构造与指定行索引及其相关数据关联的事件对象。

model 发生此事件的 DataModel
index 发生此事件的行索引(以 0 开始);或者 -1,表示没有关联任何特定行
data 表示 index 所指定的行的数据;或者为 null,表示没有特定行数据
英文文档:

DataModelEvent

public DataModelEvent(DataModel model,
                      int index,
                      Object data)

Construct an event object that is associated with the specified row index and associated data.

Parameters:
model - The DataModel on which this event occurred
index - The zero relative row index for which this event occurred, or -1 for no specific row association
data - Representation of the data for the row specified by index, or null for no particular row data

Method Detail

public DataModel getDataModel()

返回触发此事件的 DataModel

英文文档:

getDataModel

public DataModel getDataModel()

Return the DataModel that fired this event.


public Object getRowData()

返回表示指定行索引的对象;如果没有任何关联的行数据,则返回 null

英文文档:

getRowData

public Object getRowData()

Return the object representing the data for the specified row index, or null for no associated row data.


public int getRowIndex()

返回此事件的行索引;如果没有任何特定行,则返回 -1。

英文文档:

getRowIndex

public int getRowIndex()

Return the row index for this event, or -1 for no specific row.



Submit a bug or feature

Copyright 2007 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms.

一看就知道只有菜鸟才干这么无知的事啦。

PS : 未经我党受权你也可自由散发此文档。 如有任何错误请自行修正;若因此而造成任何损失请直接找人民主席,请勿与本人联系。谢谢!