Uses of Class
org.ntnu.idi.idatt2106.sparesti.sparestibackend.exception.challenge.ChallengeNotFoundException
Packages that use ChallengeNotFoundException
Package
Description
-
Uses of ChallengeNotFoundException in org.ntnu.idi.idatt2106.sparesti.sparestibackend.controller
Methods in org.ntnu.idi.idatt2106.sparesti.sparestibackend.controller that throw ChallengeNotFoundExceptionModifier and TypeMethodDescriptionorg.springframework.http.ResponseEntity
<ChallengeDTO> ChallengeController.createChallenge
(ChallengeCreateDTO challengeCreateDTO, org.springframework.security.core.userdetails.UserDetails userDetails) Creates a saving challengeorg.springframework.http.ResponseEntity
<Void> ChallengeController.deleteChallenge
(@NotNull Long id, org.springframework.security.core.userdetails.UserDetails userDetails) Deletes a challengeorg.springframework.http.ResponseEntity
<ChallengeDTO> ChallengeController.getUserChallenge
(org.springframework.security.core.userdetails.UserDetails userDetails, Long id) Gets a specific user challengeorg.springframework.http.ResponseEntity
<org.springframework.data.domain.Page<ChallengeDTO>> ChallengeController.getUserChallenges
(org.springframework.data.domain.Pageable pageable, org.springframework.security.core.userdetails.UserDetails userDetails) Gets a page of a user's saving challengesorg.springframework.http.ResponseEntity
<ChallengeDTO> ChallengeController.updateChallenge
(Long id, ChallengeUpdateDTO challengeUpdateDTO, org.springframework.security.core.userdetails.UserDetails userDetails) Updates a challenge -
Uses of ChallengeNotFoundException in org.ntnu.idi.idatt2106.sparesti.sparestibackend.service
Methods in org.ntnu.idi.idatt2106.sparesti.sparestibackend.service that throw ChallengeNotFoundExceptionModifier and TypeMethodDescriptionvoid
ChallengeService.deleteChallenge
(Long challengeId, User user) Deletes a challenge by ID and user, ensuring it is no longer present in the database.ChallengeService.getChallenge
(Long challengeId, User user) Retrieves a specific challenge by ID and user.org.springframework.data.domain.Page
<ChallengeDTO> ChallengeService.getChallengesByUser
(User user, org.springframework.data.domain.Pageable pageable) Retrieves all challenges associated with a specific user and paginates the results.ChallengeService.save
(ChallengeCreateDTO challengeCreateDTO, User user) Creates and persists a new challenge based on provided DTO and user details.ChallengeService.updateChallenge
(Long id, ChallengeUpdateDTO challengeUpdateDTO, User user) Updates an existing challenge with new data from a provided DTO if the challenge has not been completed.