This is a plugin for Jackson which can serialize cyclic object graphs in the JSOG format. At the moment it can only serialize, not deserialize, but this is adequate for sending data to JavaScript clients.
The official repository is (https://github.com/jsog/jsog-jackson)
This plugin is available in Maven Central:
<dependency>
<groupId>com.voodoodyne.jackson.jsog</groupId>
<artifactId>jackson-jsog</artifactId>
<version>please look up latest version</version>
<scope>compile</scope>
</dependency>
It can be downloaded directly from [http://search.maven.org/]
To use this plugin, annotate any classes which may contain references with @JsonIdentityInfo(generator=JSOGGenerator.class).
@JsonIdentityInfo(generator=JSOGGenerator.class)
public class Person {
String name;
Person secretSanta;
}
- Jeff Schnitzer (jeff@infohazard.org)
This software is provided under the MIT license