Record Class ServiceRouteDetails.RouteEntry
java.lang.Object
java.lang.Record
org.ek9lang.compiler.ir.data.ServiceRouteDetails.RouteEntry
- Record Components:
methodName- Internal method name (e.g., "_add" or "getById")httpVerb- HTTP method (e.g., "GET", "POST", "PUT", "DELETE", "PATCH", "HEAD")uriPattern- URI path pattern (e.g., "/users/{id}")paramBindings- Parameter extraction bindingsreturnTypeFqn- Return type FQN (e.g., "org.ek9.lang::HTTPResponse")isSanitized- True if any parameter is marked sanitizedsecurityGateFqn- FQN of the SecurityGate function, or null if no gatecorsPolicyFqn- FQN of the CORSPolicy function, or null if no CORS policy
- Enclosing class:
ServiceRouteDetails
public static record ServiceRouteDetails.RouteEntry(String methodName, String httpVerb, String uriPattern, List<ServiceRouteDetails.ParamBinding> paramBindings, String returnTypeFqn, boolean isSanitized, @Nullable String securityGateFqn, @Nullable String corsPolicyFqn)
extends Record
A single service operation's HTTP route metadata.
-
Constructor Summary
ConstructorsConstructorDescriptionRouteEntry(String methodName, String httpVerb, String uriPattern, List<ServiceRouteDetails.ParamBinding> paramBindings, String returnTypeFqn, boolean isSanitized) Convenience constructor without gate/cors (backwards compatibility for tests).RouteEntry(String methodName, String httpVerb, String uriPattern, List<ServiceRouteDetails.ParamBinding> paramBindings, String returnTypeFqn, boolean isSanitized, String securityGateFqn, String corsPolicyFqn) Creates an instance of aRouteEntryrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecorsPolicyFqnrecord component.final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.httpVerb()Returns the value of thehttpVerbrecord component.booleanReturns the value of theisSanitizedrecord component.Returns the value of themethodNamerecord component.Returns the value of theparamBindingsrecord component.Returns the value of thereturnTypeFqnrecord component.Returns the value of thesecurityGateFqnrecord component.final StringtoString()Returns a string representation of this record class.Returns the value of theuriPatternrecord component.
-
Constructor Details
-
RouteEntry
public RouteEntry(String methodName, String httpVerb, String uriPattern, List<ServiceRouteDetails.ParamBinding> paramBindings, String returnTypeFqn, boolean isSanitized, @Nullable String securityGateFqn, @Nullable String corsPolicyFqn) Creates an instance of aRouteEntryrecord class.- Parameters:
methodName- the value for themethodNamerecord componenthttpVerb- the value for thehttpVerbrecord componenturiPattern- the value for theuriPatternrecord componentparamBindings- the value for theparamBindingsrecord componentreturnTypeFqn- the value for thereturnTypeFqnrecord componentisSanitized- the value for theisSanitizedrecord componentsecurityGateFqn- the value for thesecurityGateFqnrecord componentcorsPolicyFqn- the value for thecorsPolicyFqnrecord component
-
RouteEntry
-
-
Method Details
-
toString
-
hashCode
-
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with thecomparemethod from their corresponding wrapper classes. -
methodName
Returns the value of themethodNamerecord component.- Returns:
- the value of the
methodNamerecord component
-
httpVerb
-
uriPattern
Returns the value of theuriPatternrecord component.- Returns:
- the value of the
uriPatternrecord component
-
paramBindings
Returns the value of theparamBindingsrecord component.- Returns:
- the value of the
paramBindingsrecord component
-
returnTypeFqn
Returns the value of thereturnTypeFqnrecord component.- Returns:
- the value of the
returnTypeFqnrecord component
-
isSanitized
public boolean isSanitized()Returns the value of theisSanitizedrecord component.- Returns:
- the value of the
isSanitizedrecord component
-
securityGateFqn
Returns the value of thesecurityGateFqnrecord component.- Returns:
- the value of the
securityGateFqnrecord component
-
corsPolicyFqn
Returns the value of thecorsPolicyFqnrecord component.- Returns:
- the value of the
corsPolicyFqnrecord component
-