Module com.speedment.common.codegen
Interface HasThrows<T extends HasThrows<T>>
-
- Type Parameters:
T- the extending type
- All Known Subinterfaces:
Constructor,InterfaceMethod,Method
public interface HasThrows<T extends HasThrows<T>>A trait for models that can throw exceptions.- Since:
- 2.0
- Author:
- Emil Forslund
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default Tadd(Type exception)Adds the specified exception reference to thethrows-clause of this model.Set<Type>getExceptions()Returns aSetwith all the exceptions that can be thrown by this model.default Tthrowing(Type exception)Adds the specified exception reference to thethrows-clause of this model.
-
-
-
Method Detail
-
add
default T add(Type exception)
Adds the specified exception reference to thethrows-clause of this model.- Parameters:
exception- the new exception- Returns:
- a reference to this
-
throwing
default T throwing(Type exception)
Adds the specified exception reference to thethrows-clause of this model. This is a synonym ofadd(Type).- Parameters:
exception- the new exception- Returns:
- a reference to this
-
-