Package org.apache.avro.util
Interface ClassSecurityValidator.ClassSecurityPredicate
- All Known Implementing Classes:
ClassSecurityValidator.SystemPropertiesPredicate
- Enclosing class:
ClassSecurityValidator
public static interface ClassSecurityValidator.ClassSecurityPredicate
A predicate that checks if a class is trusted to be included in Avro schemas.
-
Method Summary
Modifier and TypeMethodDescriptiondefault voidforbiddenClass(String className) Throws aSecurityExceptionwith a message indicating that the class is not trusted to be included in Avro schemas.booleanChecks if the class is trusted to be included in Avro schemas.
-
Method Details
-
isTrusted
Checks if the class is trusted to be included in Avro schemas.- Parameters:
clazz- the class to check- Returns:
- true if the class is trusted, false otherwise
-
forbiddenClass
Throws aSecurityExceptionwith a message indicating that the class is not trusted to be included in Avro schemas.- Parameters:
className- the name of the class that is not trusted
-