ValidatingAdmissionPolicySpec class
ValidatingAdmissionPolicySpec is the specification of the desired behavior of the AdmissionPolicy.
Constructors
-
ValidatingAdmissionPolicySpec({List<
AuditAnnotation> ? auditAnnotations, String? failurePolicy, List<MatchCondition> ? matchConditions, MatchResources? matchConstraints, ParamKind? paramKind, List<Validation> ? validations}) -
Default constructor.
const
-
ValidatingAdmissionPolicySpec.fromJson(Map<
String, dynamic> json) -
Creates a ValidatingAdmissionPolicySpec from JSON data.
factory
Properties
-
auditAnnotations
→ List<
AuditAnnotation> ? -
auditAnnotations contains CEL expressions which are used to produce audit annotations for the audit event of the API request. validations and auditAnnotations may not both be empty; a least one of validations or auditAnnotations is required.
final
- failurePolicy → String?
-
failurePolicy defines how to handle failures for the admission policy. Failures can occur from CEL expression parse errors, type check errors, runtime errors and invalid or mis-configured policy definitions or bindings.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
matchConditions
→ List<
MatchCondition> ? -
MatchConditions is a list of conditions that must be met for a request to be validated. Match conditions filter requests that have already been matched by the rules, namespaceSelector, and objectSelector. An empty list of matchConditions matches all requests. There are a maximum of 64 match conditions allowed.
final
- matchConstraints → MatchResources?
-
MatchConstraints specifies what resources this policy is designed to validate. The AdmissionPolicy cares about a request if it matches all Constraints. However, in order to prevent clusters from being put into an unstable state that cannot be recovered from via the API ValidatingAdmissionPolicy cannot match ValidatingAdmissionPolicy and ValidatingAdmissionPolicyBinding. Required.
final
- paramKind → ParamKind?
-
ParamKind specifies the kind of resources used to parameterize this policy. If absent, there are no parameters for this policy and the param CEL variable will not be provided to validation expressions. If ParamKind refers to a non-existent kind, this policy definition is mis-configured and the FailurePolicy is applied. If paramKind is specified but paramRef is unset in ValidatingAdmissionPolicyBinding, the params variable will be null.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
-
validations
→ List<
Validation> ? -
Validations contain CEL expressions which is used to apply the validation. Validations and AuditAnnotations may not both be empty; a minimum of one Validations or AuditAnnotations is required.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toJson(
) → Map< String, Object> - Converts a ValidatingAdmissionPolicySpec instance to JSON data.
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited