org.apache.myfaces.trinidad.change
Class ReorderChildrenComponentChange

java.lang.Object
  extended by org.apache.myfaces.trinidad.change.ComponentChange
      extended by org.apache.myfaces.trinidad.change.ReorderChildrenComponentChange
All Implemented Interfaces:
java.io.Serializable, DocumentChange

public class ReorderChildrenComponentChange
extends ComponentChange
implements DocumentChange

Change specialization for re-ordering of children. While applying this Change, the specified order of children is restored.

Version:
$Name: $ ($Revision: adfrt/faces/adf-faces-api/src/main/java/oracle/adf/view/faces/change/ReorderChildrenComponentChange.java#0 $) $Date: 10-nov-2005.19:10:01 $
See Also:
Serialized Form

Constructor Summary
ReorderChildrenComponentChange(java.util.List<java.lang.String> childIds)
          Constructs a ReorderChange with the given List of identifiers for children.
 
Method Summary
 void changeComponent(javax.faces.component.UIComponent uiComponent)
          Apply this change to the specied component In case children were to be removed between the time when this Change was added, and the time when it was applied, maybe due to application of a RemoveChildrenChange, such children are not re-instated.
 void changeDocument(org.w3c.dom.Node componentNode)
          Apply this change to the specied root DOM Node of the component In case children were to be removed between the time when this Change was added, and the time when it was applied, maybe due to application of a RemoveChildrenChange, such children are not re-instated.
 java.util.List<java.lang.String> getChildIds()
          Returns an unmodifiable List of the identifiers for the children.
 boolean getForcesDocumentReload()
          Returns true if adding the DocumentChange should force the JSP Document to reload
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReorderChildrenComponentChange

public ReorderChildrenComponentChange(java.util.List<java.lang.String> childIds)
Constructs a ReorderChange with the given List of identifiers for children.

Parameters:
childIds - An in-order collection (List) of Ids (as java.lang.String) of child components. This List implementation should be of type java.io.Serializable in order to be persisted.
Throws:
java.lang.IllegalArgumentException - if supplied childIds were to be null.
Method Detail

getChildIds

public java.util.List<java.lang.String> getChildIds()
Returns an unmodifiable List of the identifiers for the children.


changeComponent

public void changeComponent(javax.faces.component.UIComponent uiComponent)
Apply this change to the specied component In case children were to be removed between the time when this Change was added, and the time when it was applied, maybe due to application of a RemoveChildrenChange, such children are not re-instated. In case children were to be added between the time when this Change was added, and the time when it was applied, maybe due to application of an AddChildChange, such children are appended to the end of the list in preserving the order in which they were added (that is they appear at the end).

Specified by:
changeComponent in class ComponentChange
Parameters:
uiComponent - the UIComponent to apply the change to

changeDocument

public void changeDocument(org.w3c.dom.Node componentNode)
Apply this change to the specied root DOM Node of the component In case children were to be removed between the time when this Change was added, and the time when it was applied, maybe due to application of a RemoveChildrenChange, such children are not re-instated. In case children were to be added between the time when this Change was added, and the time when it was applied, maybe due to application of an AddChildChange, such children are appended to the end of the list in preserving the order in which they were added (that is they appear at the end).

Specified by:
changeDocument in interface DocumentChange
Parameters:
componentNode - DOM node of the component to apply the change to

getForcesDocumentReload

public boolean getForcesDocumentReload()
Returns true if adding the DocumentChange should force the JSP Document to reload

Specified by:
getForcesDocumentReload in interface DocumentChange


Copyright © 2001-2007 Apache Software Foundation. All Rights Reserved.