Simple Controller
abstract class SimpleController<I : Serializable, E : SimpleEntity<I>, M : SimpleModel<I>, D : SimpleDTO<I>, out Mapper : SimpleMapper<I, E, M, D>, out R : SimpleRepository<I, E>, out S : SimpleService<I, E, M, D, R, Mapper>>(typeName: String, service: S, mapper: Mapper) : CRUDController<I, E, M, D, M, M, D, D, Mapper, Mapper, R, S> (source)
Simple variant of CRUDController where create/update models are just models and create/update DTOs are just DTOs
This is meant to be extended from a @RestController class, ideally also with a @RequestMapping with some path prefix for the endpoints.
Parameters
I
Id type of the data
E
Entity type of the data which is a SimpleEntity
M
Model type of the data which is a SimpleModel
D
DTO type of the data which is a SimpleDTO
Mapper
Mapper type of the data which is a SimpleMapper
R
Repository type of the data which is a SimpleRepository
S
Service type of the data which is a SimpleService