SpringWebFlow
すぐ上のモデルにvalidatorメソッドを付けると、入力バリデーションはいけるけど、DBとのデータの、たとえばすでに同じ名前が登録されているかなどのバリデーションが難しい。 そのためモデル名validatorを@Component作成してDIを利用してチェックするのが良…
クラス内に以下の名前のパブリックメソッドを用意すると自動で実行される。 validate${state} flowの中で以下のようにview-stateを設定しているとき、 UserRegistrationBeanWebflowFormクラス内に以下のようなメソッドがあると 遷移前このメソッドが呼び出さ…
まだ よくわかっていない感じです。https://github.com/SpringSource/spring-webflow-samples http://static.springsource.org/spring-webflow/docs/2.3.x/reference/html/index.html
※メモ書き動作まだ見てないので注意flow.xmlの中に以下のように書く externalContext.sessionMap.user これでhttpSessionに"user"として登録したものを取り出せる登録したとき request.getSession(true).setAttribute("user", user);
FormActionクラスをxml内にbeanで定義して 受け渡しをするHTMLのフォームの内容とJavaのクラスをマッピングする。 validatorやregisteryEditorを使ってHTMLのフォームデータをjavaのクラスに設定する。context.xmlの中は、これでクラスNpoBeanWebflowFormをH…
spring-web-flowのcontext.xml spring security の xmlの中身 flow定義のxmlの中にロールがROLE_USERとして
spring web flow 2.0系では action-stateのaction タグがevaluateになったようです。http://static.springsource.org/spring-webflow/docs/2.0.x/reference/htmlsingle/spring-webflow-reference.html#actions 以前のaction-stateのactionタグでの設定XML部…