IWriter<T, K>

Interface for data processing components that can create, update and delete data items.

Description

The IWriter interface is used by data processng components that can create, update and delete data items.

Instance methods

create

Creates a data item.

T create(IContext context, T entity) throws ApplicationException

  • context: IContext - (optional) a context to trace execution through a call chain.
  • entity: T - item to be created.
  • returns: T - created item

update

Updates a data item.

T update(IContext context, T entity) throws ApplicationException

  • context: IContext - (optional) a context to trace execution through a call chain.
  • entity: T - item to be updated.
  • returns: T - updated item

deleteById

Updates a data item.

T deleteById(IContext context, K id) throws ApplicationException

  • context: IContext - (optional) a context to trace execution through a call chain.
  • id: K - id of the item to be deleted
  • returns: T - deleted item.