-
Notifications
You must be signed in to change notification settings - Fork 512
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Provide example for mapping into ProtoBuf types #14
Comments
Is there a way to generify the rule that "permissions" will always be "permissionsList" in the proto? (and vice versa). Otherwise I've updated the example from the pr#25 feedback. Thx. |
What do you mean to generify that That can be done by removing the |
Example with protobuf 3 has been added. My comments are not implemented in the example. |
So I have been working through your example and I am at a loss how to get it to work outside of the examples project. Moreso I am using Gradle. This is where I am https://github.com/vordimous/mapstruct-proto I get this error: which I can get around by adding a mapping ignore, however you don't have to do this in your example. Any ideas @filiphr ? |
I am currently using mapstruct (1.3.0beta1) with Kotlin and gRPC (proto3). The example ProtobufAccessorNamingStrategy doesn't work to handle the mapping between "permissions" and "permissionsList" (the getElementName method doesn't even get called at all). I hate to manually map every collection type explicitly using @ValueMapping, thus did an ugly hack like this and got it working for my purposes: public class ProtobufAccessorNamingStrategy extends DefaultAccessorNamingStrategy { |
@filiphr |
No description provided.
The text was updated successfully, but these errors were encountered: