
|
If you were logged in you would be able to see more operations.
|
|
|
XStream
Created: 13/Sep/07 12:26 PM
Updated: 25/Feb/08 05:01 PM
|
|
| Component/s: |
Core
|
| Affects Version/s: |
1.2.2
|
| Fix Version/s: |
1.3
|
|
|
@XStreamAlias("User")
class User {
String name;
String password;
}
xstream.useAttributeFor(String.class);
xstream.omitField(User.class, "password");
Upon serialization I get: (password should not be there!)
<User name="abc" password="pass"/>
However if userAttributeFor is not used I get (Correct password is ignored)
<User>
<name>abc</name>
</User>
|
|
Description
|
@XStreamAlias("User")
class User {
String name;
String password;
}
xstream.useAttributeFor(String.class);
xstream.omitField(User.class, "password");
Upon serialization I get: (password should not be there!)
<User name="abc" password="pass"/>
However if userAttributeFor is not used I get (Correct password is ignored)
<User>
<name>abc</name>
</User> |
Show » |
|