com.cc.framework.convert
Interface StatefullConverter

All Superinterfaces:
Converter
All Known Implementing Classes:
DateTimeConverter, NumberConverter

public interface StatefullConverter
extends Converter

Base Class for Converters that need to save their state between requests.

Version:
$Revision$
Author:
Harald Schulz

Method Summary
 void restoreState(RequestContext ctx, java.lang.Object obj)
          Perform any processing required to restore the state from the entries in the state Object.
 java.lang.Object saveState(RequestContext ctx)
          Gets the state of the instance as a Serializable Object.
 
Methods inherited from interface com.cc.framework.convert.Converter
getAsObject, getAsString
 

Method Detail

saveState

public java.lang.Object saveState(RequestContext ctx)
Gets the state of the instance as a Serializable Object. This method must not alter the state of the implementing object. In other words, after executing this code:
 Object state = component.saveState(ctx);
 
Component should be the same as before executing it.

Parameters:
ctx - The RequestContext object
Returns:
The return from this method must be Serializable

restoreState

public void restoreState(RequestContext ctx,
                         java.lang.Object obj)
Perform any processing required to restore the state from the entries in the state Object.

Parameters:
ctx - The RequestContext object
obj - the serialized state


Copyright © 2000-2005 SCC Informationssysteme GmbH. All Rights Reserved.