3
PlayFrameworkとデータバインディングの検証を使用して、いくつかのフィールドのバインドを避けるために(おそらく)デコレータを介して可能でしょうか?例えばいくつかのフィールドのバインドを回避するにはどうすればよいですか?
、私はこのモデルがあります:
class User extends Model {
@Required
@Email
public String email;
// I'd like to avoid setting this
public String password;
}
を、私のモデルに:
Store store = new Store();
Binder.bindBean(params.getRootParamNode(), store, null);
validation.valid(store);
ユーザーPOSTのメールアドレスとパスワードは、パスワードも設定されますが、私はしないでくださいをしたい。
どうすればいいですか?