org.apache.myfaces.trinidad.render

## Class ClientRowKeyManager

- java.lang.Object
- - org.apache.myfaces.trinidad.render.ClientRowKeyManager

- All Implemented Interfaces:
    Serializable

      public abstract class ClientRowKeyManager
      extends Object
      implements Serializable

  This class manages server-side rowkey Objects with client-side string keys. This class must be Serializable as it is state-saved along with the UIComponent state.
  See Also:
    Serialized Form

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `ClientRowKeyManager()`

  - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `abstract String` | `getClientRowKey(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component, Object rowKey)` Gets a string version of a key that identifies the row with the given rowkey.
    `abstract Object` | `getRowKey(javax.faces.context.FacesContext context, javax.faces.component.UIComponent component, String clientRowKey)` Gets the corresponding server-side rowkey object from the given client-side string key.

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### ClientRowKeyManager

          public ClientRowKeyManager()

  - ### Method Detail

    - #### getClientRowKey

          public abstract String getClientRowKey(javax.faces.context.FacesContext context,
                               javax.faces.component.UIComponent component,
                               Object rowKey)

      Gets a string version of a key that identifies the row with the given rowkey. This string key can be used on the client-side to identify the row. If a string key for the given rowkey does not exist, then a new one is created. The lifespan of this string rowkey is entirely upto each implementation. Implementors must ensure that if a particular row is still present on the client-side, then its string key must also continue to be valid.
      Parameters:
        `rowKey` - the rowkey to convert into a client key. Note that null is special and is not allowed.

    - #### getRowKey

          public abstract Object getRowKey(javax.faces.context.FacesContext context,
                         javax.faces.component.UIComponent component,
                         String clientRowKey)

      Gets the corresponding server-side rowkey object from the given client-side string key. If the string key has expired, implementors should return null. However, if any part of a row is still present on the client-side, its corresponding string-key may not expire.
      Parameters:
        `clientRowKey` - the string key
      Returns:
        null, if the string key has expired, or never existed.

Copyright © 2001-2016 The Apache Software Foundation. All Rights Reserved.