Skip to content
Pieter Verschaffelt edited this page Apr 14, 2019 · 1 revision

An entity is defined as a single item that is returned by a system's API. Good examples of entities are users, posts, articles, etc. Every type of information that's returned by a REST API and that should be consumed by a concrete instance of Service needs an associated Entity-class to function properly. The fields in a class that inherits from Entity, annotated with a specific decorator, specify to the Service which fields are returned by your to-be-consumed REST API.

The abstract Entity defines one property, id, that's always assumed to be present on objects returned by your REST API. This property is annotated with a Read and Update decorator by default.

Clone this wiki locally