Vita Rara: A Life Uncommon

Just wondering

Mark,

Just wondering; why don't you rely on OGNL to instantiate the VRContext object ? I believe OGNL can also set fields (but I'm not sure it's enabled in S2). Wouldn't you agree that providing getters and setters on the VRContext for exactly this purpose is a good idea ?
Is there a reason why you're not relying on the XWork validation ? It would give you a lot more control, and it's completely seperated from your Action.

If you apply both tips, you'll find your Action to be another 40 lines (if not more) shorter, and a lot cleaner (of course, you'll have to create an additional validation file ..).

Cheers,

Phil

Reply

Please solve the math problem above and type in the result. e.g. for 1+1, type 2
  • Allowed HTML tags: <a> <img> <em> <strong> <cite> <code> <ul> <ol> <li> <dl> <dt> <dd> <pre> <h1> <h2> <h3>
  • Lines and paragraphs break automatically.
More information about formatting options