com.opensymphony.xwork.util
Annotation Type Key
public @interface Key
Sets the Key for type conversion.
Annotation usage:
The Key annotation must be applied at field level.
Annotation parameters:
Parameter |
Required |
Default |
Description |
value |
no |
java.lang.Object.class |
The key property value. |
Example code:
// The key property for User objects within the users collection is the userName
attribute.
@Key( value = java.lang.Long.class )
private Map userMap;
- Version:
- $Id: Key.java 920 2006-03-21 18:39:15 +0100 (Tue, 21 Mar 2006) rainerh $
- Author:
- Rainer Hermanns
Optional Element Summary |
Class |
value
The Key value. |
value
public abstract Class value
- The Key value.
Defaults to java.lang.Object.class.
- Default:
- java.lang.Object.class