Withing the Geomajas spatial application framework, we have released some some generally usable code as separate projects. These projects have no dependencies on other parts of Geomajas and can easily be reused. To facilitate the adoption, these projects are released using the Apache License v2.
The Geometry project contains a DTO class for representing a geometry and services for manipulating these geometries. These objects can be used in various environments, including GWT. They can also easily be serialized to and from JSON.
The API project contains some annotations which can be used to indicate which parts (which classes and which (public) methods or fields) are considered as API. This is particularly useful for projects where you want to mark the API without the need to refactor everything to interfaces and factories.
The SLD project contains DTOclasses and services to convert between these SLD objects and the XML representation. The DTO classes can be used in various environments, including GWT. They can also easily be serialized to and from JSON.
Version 1.0.0 of all three projects is now available on maven central.