org.apache.myfaces.trinidad.change

## Class AttributeDocumentChange

- java.lang.Object
- - org.apache.myfaces.trinidad.change.AttributeDocumentChange

- All Implemented Interfaces:
    DocumentChange

      public class AttributeDocumentChange
      extends Object
      implements DocumentChange

  Change specialization for change in attributes. While applying this Change, the specified attribute state is restored.

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `AttributeDocumentChange(String attributeName, String attributeValueString)` Constructs an AttributeChange with the given attributeName and attributeValue.

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `changeDocument(Node componentNode)` Apply this change to the specied root DOM Node of the component
    `String` | `getAttributeName()` Returns the name of the attribute that represents this Change.
    `Object` | `getAttributeStringValue()` Returns the value of the attribute corresponding to this AttributeChange.
    `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

    - #### AttributeDocumentChange

          public AttributeDocumentChange(String attributeName,
                                 String attributeValueString)

      Constructs an AttributeChange with the given attributeName and attributeValue.
      Parameters:
        `attributeName` - The name of the attribute for which the value needs to be restored.
        `attributeValueString` - The value of the attribute that needs to be restored.
      Throws:
        `IllegalArgumentException` - if specified attributeName were to be null. =-= bts TODO Figure out what to do about non String values

  - ### Method Detail

    - #### getAttributeName

          public String getAttributeName()

      Returns the name of the attribute that represents this Change.

    - #### getAttributeStringValue

          public Object getAttributeStringValue()

      Returns the value of the attribute corresponding to this AttributeChange.

    - #### changeDocument

          public void changeDocument(Node componentNode)

      Apply this change to the specied root DOM Node of the component
      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-2016 The Apache Software Foundation. All Rights Reserved.