rest - SpringBoot java Collection annotation for Swagger -


i have problem annotations , generating documentation (spring-boot, springfox-swagger2).

what should proper annotation string collection in technologydto?

does swagger support java.util.collection?


after generation have:

model schema:

{     "technologies": {},     "userguid": "string" } 

model:

technologydto {     technologies (collection«string»): user main technology names,     userguid (string): user guid }  collection«string» { }  

my technologydto:

public class technologydto {     private final string userguid;     private final collection<string> technologies;      public technologydto(string userguid, collection<string> technologies) {         this.userguid = userguid;         this.technologies = technologies;     }      @apimodelproperty(notes = "user guid", datatype="string", required = true)     public string getuserguid() {         return userguid;     }      @apimodelproperty(notes = "user main technology names", required = true)     public collection<string> gettechnologies() {         return technologies;     }      public static technologydto createemptydto() {         return new technologydto(null, null);     } } 


Comments