GoCollections/exceptions/NPE.go

17 lines
255 B
Go
Raw Normal View History

2021-05-21 11:14:07 +08:00
package exceptions
type NPE struct {
RuntimeException
}
2022-03-23 10:15:18 +08:00
func NewNPE(message any, config *ExceptionConfig) *NPE {
2022-03-21 11:02:41 +08:00
config.AddSkipStack(1)
return &NPE{
2021-05-21 11:14:07 +08:00
NewRuntimeException(
message,
"exception caused NullPointerException:",
2022-03-21 11:02:41 +08:00
config,
2021-05-21 11:14:07 +08:00
),
}
}