mirror of
https://github.com/Sheldan/abstracto.git
synced 2026-03-06 16:26:31 +00:00
refactored channel exception to have a unified interface to form the exception message
replaced getOne with findById in order to get optionals and handle those some places still have the general abstracto run time exception
This commit is contained in:
@@ -3,6 +3,7 @@ package dev.sheldan.abstracto.experience.service.management;
|
||||
import dev.sheldan.abstracto.experience.models.database.AExperienceLevel;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Optional;
|
||||
|
||||
/**
|
||||
* Service responsible to create and retrieve {@link AExperienceLevel} objects in the database.
|
||||
@@ -26,9 +27,9 @@ public interface ExperienceLevelManagementService {
|
||||
/**
|
||||
* Retrieves a {@link AExperienceLevel} according to the given level.
|
||||
* @param level The level of the wanted {@link AExperienceLevel} to look for
|
||||
* @return If the level exists, returns the {@link AExperienceLevel}, if it does not exists, returns null.
|
||||
* @return Returns an optional containing the {@link AExperienceLevel} if it exists, and null otherwise
|
||||
*/
|
||||
AExperienceLevel getLevel(Integer level);
|
||||
Optional<AExperienceLevel> getLevel(Integer level);
|
||||
|
||||
/**
|
||||
* Loads the complete level configuration and returns all found {@link AExperienceLevel} objects from the database.
|
||||
|
||||
Reference in New Issue
Block a user