Class ServiceSecurityConstraintOrError
java.lang.Object
org.ek9lang.compiler.common.RuleSupport
org.ek9lang.compiler.common.TypedSymbolAccess
org.ek9lang.compiler.phase5.ServiceSecurityConstraintOrError
- All Implemented Interfaces:
Consumer<EK9Parser.ServiceDeclarationContext>
final class ServiceSecurityConstraintOrError
extends TypedSymbolAccess
implements Consumer<EK9Parser.ServiceDeclarationContext>
Validates that every service declaration has a security posture: either 'open'
or 'constrain by X [and Y]'. When constrain-by references are present, validates
that they resolve to functions extending SecurityGate or CORSPolicy, and that
a two-reference clause does not have duplicate roles (both gates or both policies).
-
Field Summary
Fields inherited from class RuleSupport
errorListener, symbolsAndScopes -
Constructor Summary
ConstructorsConstructorDescriptionServiceSecurityConstraintOrError(SymbolsAndScopes symbolsAndScopes, ErrorListener errorListener, ParsedModule parsedModule) -
Method Summary
Modifier and TypeMethodDescriptionvoid(package private) voidCheck security constraint on a service operation declaration.Methods inherited from class TypedSymbolAccess
getRecordedAndTypedSymbol, isProcessingScopePure, recordATypedSymbol
-
Constructor Details
-
ServiceSecurityConstraintOrError
ServiceSecurityConstraintOrError(SymbolsAndScopes symbolsAndScopes, ErrorListener errorListener, ParsedModule parsedModule)
-
-
Method Details
-
accept
- Specified by:
acceptin interfaceConsumer<EK9Parser.ServiceDeclarationContext>
-
checkOperation
Check security constraint on a service operation declaration. Service operations can also have their own constraint overriding the service level.
-