Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

The Struts 2 framework determines which option is preselected by using the key attribute's value to call a method on the personBean object. Since the key attribute's value is "personBean.sportssport", the framework calls the personBean object's getSports getSport method. If the value returned by that method matches one of the option values, that option will be marked as "selected".

...