kusalk commented on PR #865:
URL: https://github.com/apache/struts/pull/865#issuecomment-1914890075

   @lukaszlenart
   
   I was hoping you could clear up some confusion of mine as I'm not well 
versed in how the Struts TypeConversion functionality behaves. I'm trying to 
understand whether it is possible to set a collection of Model class objects on 
an Action where only a setter exists?
   
   For example - for the following action,
   ```
   public class ExampleAction {
       // Configured with some TypeConverter
       public void setModels(List<Model> models) {
           this.models = models;
       }
   
       public static class Model {
           public String name;
       }
   }
   ```
   is it possible to configure a TypeConverter that would allow the following 
request to execute as intended?
   `example.action?models[0].name=kusal&models[1].name=lukasz`
   
   If so, I may need to tweak the StrutsParameter mechanism to also recognise 
annotations on Setters (which is what this draft PR does).


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to