Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 4 of 4 for NewCompiler (0.13 sec)

  1. staging/src/k8s.io/apiserver/pkg/admission/plugin/cel/compile_test.go

    		IntroducedVersion: version.MajorMinor(1, 999),
    		EnvOptions:        []celgo.EnvOption{library.Test()},
    	})
    	if err != nil {
    		t.Fatal(err)
    	}
    	compiler := NewCompiler(extended)
    
    	for _, tc := range cases {
    		envType := tc.envType
    		if envType == "" {
    			envType = environment.NewExpressions
    		}
    		t.Run(tc.name, func(t *testing.T) {
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 10.8K bytes
    - Viewed (0)
  2. staging/src/k8s.io/apiserver/pkg/admission/plugin/cel/compile.go

    	CompileCELExpression(expressionAccessor ExpressionAccessor, options OptionalVariableDeclarations, mode environment.Type) CompilationResult
    }
    
    type compiler struct {
    	varEnvs variableDeclEnvs
    }
    
    func NewCompiler(env *environment.EnvSet) Compiler {
    	return &compiler{varEnvs: mustBuildEnvs(env)}
    }
    
    type variableDeclEnvs map[OptionalVariableDeclarations]*environment.EnvSet
    
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 10.5K bytes
    - Viewed (0)
  3. staging/src/k8s.io/apiserver/pkg/admission/plugin/cel/filter_test.go

    				},
    			},
    		},
    	}
    
    	for _, tc := range cases {
    		t.Run(tc.name, func(t *testing.T) {
    			c := filterCompiler{compiler: NewCompiler(environment.MustBaseEnvSet(environment.DefaultCompatibilityVersion(), true))}
    			e := c.Compile(tc.validation, OptionalVariableDeclarations{HasParams: false, HasAuthorizer: false, StrictCost: true}, environment.NewExpressions)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 40.4K bytes
    - Viewed (0)
  4. staging/src/k8s.io/apiserver/pkg/apis/apiserver/validation/validation.go

    	var allErrs field.ErrorList
    
    	// strictCost is set to true which enables the strict cost for CEL validation.
    	compiler := authenticationcel.NewCompiler(environment.MustBaseEnvSet(environment.DefaultCompatibilityVersion(), true))
    	state := &validationState{}
    
    	allErrs = append(allErrs, validateIssuer(authenticator.Issuer, disallowedIssuers, fldPath.Child("issuer"))...)
    Registered: Sat Jun 15 01:39:40 UTC 2024
    - Last Modified: Fri May 10 22:07:40 UTC 2024
    - 31.3K bytes
    - Viewed (0)
Back to top