This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.
package com.studentmanagement.exception;
/**
* 学生未找到异常,当尝试操作不存在的学生时抛出
*/
public class StudentNotFoundException extends Exception {
* 构造函数
* @param message 异常信息
public StudentNotFoundException(String message) {
super(message);
}
* 构造函数,带学生ID
* @param id 学生ID
public StudentNotFoundException(int id) {
super("学生ID " + id + " 未找到");