Page History
...
- Add private properties
- Add a get/set method
- Add get and set to the class DSpaceObjectRest
- To exclude a property from JSON representation, add @JsonIgnore to the get method or to the property
...
- wrap the linked REST resource inside a DSpaceResource (so to have the identifier, self link, and links to other resources). The wrapper is actually created by the Repository responsible of the specific resource (ItemRepository, BitstreamRepository, etc.)
- https://github.com/DSpace/DSpace/blob/rest7master/dspace-spring-rest/src/main/java/org/dspace/app/rest/model/hateoas/DSpaceResource.java#L58
This give a chance to add custom logic for extra links in specific resource
- https://github.com/DSpace/DSpace/blob/rest7master/dspace-spring-rest/src/main/java/org/dspace/app/rest/model/hateoas/DSpaceResource.java#L58
- put the wrapper in the embedded section
- clean the attribute (not sure if useful/required/right):
Converter Object: org.dspace.app.rest.converter.DSpaceObjectConverter
...
- In the fromModel() function, map all object attributes from the persistence/hibernate model to the rest model
Repository Object: org.dspace.app.rest.repository.DSpaceRestRepository
...
Overview
Content Tools