ItemService

Service for Items.

Author

Jan Müller
interface ItemService

Functions

createItem
Link copied to clipboard
Creates an Item. Must validate that the Item does not exist and the data is valid.
abstract suspend fun createItem(item: Item): Result<String>
deleteItemById
Link copied to clipboard
Deletes an Item by id. Must validate that the Item exists.
abstract suspend fun deleteItemById(id: String): Result<String>
equals
Link copied to clipboard
open operator override fun equals(other: Any?): Boolean
getAllItems
Link copied to clipboard
Returns all Items.
abstract suspend fun getAllItems(): Result<List<Item>>
getItemById
Link copied to clipboard
Returns the Item with the given id. Must validate that the Item exists.
abstract suspend fun getItemById(id: String): Result<Item>
hashCode
Link copied to clipboard
open override fun hashCode(): Int
toString
Link copied to clipboard
open override fun toString(): String
updateItem
Link copied to clipboard
Updates an Item. Must validate that the Item exists and the data is valid.
abstract suspend fun updateItem(item: Item): Result<String>

Inheritors

DefaultItemService
Link copied to clipboard