メソッドは次のように定義されます。
public static void checkNotNull<T extends Throwable>(Object value, String name, Class<T> exceptionClass)
{
}
次に、コンパイラはいくつかのエラーをスローします。
**この行に複数のマーカー
- void is an invalid type for the variable checkNotNull
- Duplicate field ValidationUtility.value
- Syntax error on token ">", Identifier expected after this token
- The type Class is not generic; it cannot be parameterized with
arguments <T>
- The type Class is not visible
- Duplicate field ValidationUtility.exceptionClass
- T cannot be resolved to a type
- Syntax error, insert ";" to complete FieldDeclaration
- Duplicate field ValidationUtility.String**
何か問題がありますか?助けてください、ありがとう。