{"action":"created","issue":{"url":"https://api.github.com/repos/mapstruct/mapstruct/issues/677","repository_url":"https://api.github.com/repos/mapstruct/mapstruct","labels_url":"https://api.github.com/repos/mapstruct/mapstruct/issues/677/labels{/name}","comments_url":"https://api.github.com/repos/mapstruct/mapstruct/issues/677/comments","events_url":"https://api.github.com/repos/mapstruct/mapstruct/issues/677/events","html_url":"https://github.com/mapstruct/mapstruct/issues/677","id":114486584,"node_id":"MDU6SXNzdWUxMTQ0ODY1ODQ=","number":677,"title":"Mapping Collection of complex type to collection of primitive/simple type","user":{"login":"gbrehmer","id":1201680,"node_id":"MDQ6VXNlcjEyMDE2ODA=","avatar_url":"https://avatars3.githubusercontent.com/u/1201680?v=4","gravatar_id":"","url":"https://api.github.com/users/gbrehmer","html_url":"https://github.com/gbrehmer","followers_url":"https://api.github.com/users/gbrehmer/followers","following_url":"https://api.github.com/users/gbrehmer/following{/other_user}","gists_url":"https://api.github.com/users/gbrehmer/gists{/gist_id}","starred_url":"https://api.github.com/users/gbrehmer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gbrehmer/subscriptions","organizations_url":"https://api.github.com/users/gbrehmer/orgs","repos_url":"https://api.github.com/users/gbrehmer/repos","events_url":"https://api.github.com/users/gbrehmer/events{/privacy}","received_events_url":"https://api.github.com/users/gbrehmer/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":7,"created_at":"2015-11-01T19:18:06Z","updated_at":"2018-10-26T18:15:50Z","closed_at":null,"author_association":"NONE","body":"Currently it's not possible to automatically map a collection of complex elements to a collection of simple or primitive elements\n\nProposal 1: define nested property for collection mapping\n\n```\n@Mapping(source = \"collectionOfComplex.simpleSource\", target = \"collectionOfSimple\")\n```\n\nProposal 2: don't try to instantiate target type or access inner field if target type is simple or immutable like String or other wrapper types. Introduce a keyword (or leave target empty) to map to entire target element instead of inner field.\n\n```\n@Mapping(source = \"complexElement.simpleSource\", target = \"target\")\nString map(ComplexType complexElement);\n```\n"},"comment":{"url":"https://api.github.com/repos/mapstruct/mapstruct/issues/comments/433498170","html_url":"https://github.com/mapstruct/mapstruct/issues/677#issuecomment-433498170","issue_url":"https://api.github.com/repos/mapstruct/mapstruct/issues/677","id":433498170,"node_id":"MDEyOklzc3VlQ29tbWVudDQzMzQ5ODE3MA==","user":{"login":"filiphr","id":6012094,"node_id":"MDQ6VXNlcjYwMTIwOTQ=","avatar_url":"https://avatars2.githubusercontent.com/u/6012094?v=4","gravatar_id":"","url":"https://api.github.com/users/filiphr","html_url":"https://github.com/filiphr","followers_url":"https://api.github.com/users/filiphr/followers","following_url":"https://api.github.com/users/filiphr/following{/other_user}","gists_url":"https://api.github.com/users/filiphr/gists{/gist_id}","starred_url":"https://api.github.com/users/filiphr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/filiphr/subscriptions","organizations_url":"https://api.github.com/users/filiphr/orgs","repos_url":"https://api.github.com/users/filiphr/repos","events_url":"https://api.github.com/users/filiphr/events{/privacy}","received_events_url":"https://api.github.com/users/filiphr/received_events","type":"User","site_admin":false},"created_at":"2018-10-26T18:15:50Z","updated_at":"2018-10-26T18:15:50Z","author_association":"MEMBER","body":"@jkeruzec I think that if you just do what @gunnarmorling proposed in https://github.com/mapstruct/mapstruct/issues/677#issuecomment-153614044 then you won't need the complex expression.\r\n\r\n@sjaakd I think that we can close this one as it is quite easy to solve this manually"}}
{"actor":{"display_login":"filiphr"}}