-
Notifications
You must be signed in to change notification settings - Fork 125
Enhance Device with DevicePlatform resolving #25
Enhance Device with DevicePlatform resolving #25
Conversation
Thanks! Have you signed the CLA? |
@royclarkson Ah yes, here is my confirmation number 118920150428025713 |
Great, thanks. Can you clarify the goal of this addition? Is it basically to add the platform property to the device object? It'd help to update the docs too, if you don't mind. |
@royclarkson no problem, Yes it is as you said, a very simple approach to access device platform. We have lots of spring based projects and sometimes accessing device platform is critical. Instead of writing a new resolver for device platform, with using User-Agent header again, spring mobile can do that for us. Here i wrote down only 2 platforms which are most commonly used. Various platforms can be added of course, for example BB and Windows Phone. I am also thinking about refactoring resolve method in the future, it is quite hard to read i think. |
You may have noticed this project isn't receiving much attention these days. Obviously, the industry is favoring responsive design over server side user agent detection. However, it can still be useful in situations. You are correct about the resolve method. It's become unmanageable. I had some ideas for refactoring the resolve method for a 1.2.0 release. Making it modular, where you register several "DeviceResolverStrategy" instances with the DeviceResolver would be really nice. Something like the MessageConverter model used in Spring MVC. If you want to work on that, I'd be happy to facilitate getting the changes into a release. |
Enhance Device with DevicePlatform resolving
Thanks! |
@okohub let me know if you have anything else to include, otherwise I can push out a 1.1.4 release with these changes. Any kind of major changes would probably need to go in a 1.2.0 milestone. |
@royclarkson thanks, I will try to contribute to 1.2.0 release. |
Hi @royclarkson, |
@okohub I can push it out as soon as I update the docs. Would you mind sharing how you are using this project and if you are using other Spring projects? Feel free to email me privately at rclarkson at pivotal dot io, if you like. |
@okohub 1.1.4.RELEASE is published with this change. thanks again. |
fixes #24