> ## Documentation Index
> Fetch the complete documentation index at: https://docs.activeviam.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Generic CRUD service

> Reference for the ILimitsAppCrudService interface in Atoti Limits, the generic parent contract for persistence operations, defining create, update, save, and delete methods for limit structures, limits, and incidents

### ILimitsAppCrudService

The `ILimitsAppCrudService` is an interface that defines the generic contract for managing the
persistence of objects in Atoti Limits. It defines methods for creating, updating, and
deleting LimitStructure, Limit, and Incident objects. The types of these objects are defined by the
generic parameters `<LimitStructure>`, `<Limit>`, and `<Incident>`. This interface is designed to be
flexible and can be implemented to work with different types of persistence mechanisms. The specific
implementation will depend on the type of database or datastore you are using in your application.

The `ILimitsAppCrudService` interface provides the following methods:

```java theme={"languages":{"custom":["/engine/python-sdk/0.9/languages/pycon.tmLanguage.json"]}}
  // Limit Structure operations

  ILimitStructure createLimitStructure(ILimitStructure structureToCreate);

  List<ILimitStructure> createLimitStructures(List<ILimitStructure> structuresToCreate);

  ILimitStructure updateLimitStructure(ILimitStructure structureToUpdate);

  List<ILimitStructure> updateLimitStructures(List<ILimitStructure> structuresToUpdate);

  ILimitStructure saveLimitStructure(ILimitStructure structureToSave);

  List<ILimitStructure> saveLimitStructures(List<ILimitStructure> structuresToSave);

  boolean deleteLimitStructure(ILimitStructure structureToDelete);

  boolean deleteLimitStructures(List<ILimitStructure> structuresToDelete);

  boolean deleteAllLimitStructures();

  // Limit operations

  ILimit createLimit(ILimit limitToCreate);

  List<ILimit> createLimits(List<ILimit> limitsToCreate);

  ILimit updateLimit(ILimit limitToUpdate);

  List<ILimit> updateLimits(List<ILimit> limitsToUpdate);

  ILimit saveLimit(ILimit limitToSave);

  List<ILimit> saveLimits(List<ILimit> limitsToSave);

  boolean deleteLimit(ILimit limitToDelete);

  boolean deleteLimits(List<ILimit> limitsToDelete);

  boolean deleteAllLimits();

  // Incident operations

  IIncident createIncident(IIncident incidentToCreate);

  List<IIncident> createIncidents(List<IIncident> incidentsToCreate);

  IIncident updateIncident(IIncident incidentToUpdate);

  List<IIncident> updateIncidents(List<IIncident> incidentsToUpdate);

  IIncident saveIncident(IIncident incidentToSave);

  List<IIncident> saveIncidents(List<IIncident> incidentsToSave);

  boolean deleteIncident(IIncident incidentToDelete);

  boolean deleteIncidents(List<IIncident> incidentsToDelete);

  boolean deleteAllIncidents();
```
