Hi everyone, Simple question: In struts1 I had read that we should use String datatype for properties (in actionform). Is the same true for properties we use in struts2 now? Eg. if we have a variable in our backend say int age.. for struts property should we use int or string?
posted 9 years ago
Struts 2 is much better at handling conversion to/from different data types than Struts 1 was. It's not foolproof, but with a simple type such as int, S2 can handle the conversion quite well.