Optional. RouteMatch defines the predicate used to match requests to a
given action. Multiple match types are "OR"ed for evaluation. If no
routeMatch field is specified, this rule will unconditionally match
traffic.
Optional. RouteMatch defines the predicate used to match requests to a
given action. Multiple match types are "OR"ed for evaluation. If no
routeMatch field is specified, this rule will unconditionally match
traffic.
Optional. RouteMatch defines the predicate used to match requests to a
given action. Multiple match types are "OR"ed for evaluation. If no
routeMatch field is specified, this rule will unconditionally match
traffic.
Optional. RouteMatch defines the predicate used to match requests to a
given action. Multiple match types are "OR"ed for evaluation. If no
routeMatch field is specified, this rule will unconditionally match
traffic.
Optional. RouteMatch defines the predicate used to match requests to a
given action. Multiple match types are "OR"ed for evaluation. If no
routeMatch field is specified, this rule will unconditionally match
traffic.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Hard to understand","hardToUnderstand","thumb-down"],["Incorrect information or sample code","incorrectInformationOrSampleCode","thumb-down"],["Missing the information/samples I need","missingTheInformationSamplesINeed","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2025-08-07 UTC."],[],[],null,["# Interface TcpRoute.RouteRuleOrBuilder (0.16.0)\n\nVersion latestkeyboard_arrow_down\n\n- [0.16.0 (latest)](/java/docs/reference/google-cloudevent-types/latest/com.google.events.cloud.networkservices.v1.TcpRoute.RouteRuleOrBuilder)\n- [0.15.0](/java/docs/reference/google-cloudevent-types/0.15.0/com.google.events.cloud.networkservices.v1.TcpRoute.RouteRuleOrBuilder)\n- [0.14.1](/java/docs/reference/google-cloudevent-types/0.14.1/com.google.events.cloud.networkservices.v1.TcpRoute.RouteRuleOrBuilder) \n\n public static interface TcpRoute.RouteRuleOrBuilder extends MessageOrBuilder\n\nImplements\n----------\n\n[MessageOrBuilder](https://cloud.google.com/java/docs/reference/protobuf/latest/com.google.protobuf.MessageOrBuilder.html)\n\nMethods\n-------\n\n### getAction()\n\n public abstract TcpRoute.RouteAction getAction()\n\nRequired. The detailed rule defining how to route matched traffic.\n\n`.google.events.cloud.networkservices.v1.TcpRoute.RouteAction action = 2;`\n\n### getActionOrBuilder()\n\n public abstract TcpRoute.RouteActionOrBuilder getActionOrBuilder()\n\nRequired. The detailed rule defining how to route matched traffic.\n\n`.google.events.cloud.networkservices.v1.TcpRoute.RouteAction action = 2;`\n\n### getMatches(int index)\n\n public abstract TcpRoute.RouteMatch getMatches(int index)\n\nOptional. RouteMatch defines the predicate used to match requests to a\ngiven action. Multiple match types are \"OR\"ed for evaluation. If no\nrouteMatch field is specified, this rule will unconditionally match\ntraffic.\n\n`repeated .google.events.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1;\n`\n\n### getMatchesCount()\n\n public abstract int getMatchesCount()\n\nOptional. RouteMatch defines the predicate used to match requests to a\ngiven action. Multiple match types are \"OR\"ed for evaluation. If no\nrouteMatch field is specified, this rule will unconditionally match\ntraffic.\n\n`repeated .google.events.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1;\n`\n\n### getMatchesList()\n\n public abstract List\u003cTcpRoute.RouteMatch\u003e getMatchesList()\n\nOptional. RouteMatch defines the predicate used to match requests to a\ngiven action. Multiple match types are \"OR\"ed for evaluation. If no\nrouteMatch field is specified, this rule will unconditionally match\ntraffic.\n\n`repeated .google.events.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1;\n`\n\n### getMatchesOrBuilder(int index)\n\n public abstract TcpRoute.RouteMatchOrBuilder getMatchesOrBuilder(int index)\n\nOptional. RouteMatch defines the predicate used to match requests to a\ngiven action. Multiple match types are \"OR\"ed for evaluation. If no\nrouteMatch field is specified, this rule will unconditionally match\ntraffic.\n\n`repeated .google.events.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1;\n`\n\n### getMatchesOrBuilderList()\n\n public abstract List\u003c? extends TcpRoute.RouteMatchOrBuilder\u003e getMatchesOrBuilderList()\n\nOptional. RouteMatch defines the predicate used to match requests to a\ngiven action. Multiple match types are \"OR\"ed for evaluation. If no\nrouteMatch field is specified, this rule will unconditionally match\ntraffic.\n\n`repeated .google.events.cloud.networkservices.v1.TcpRoute.RouteMatch matches = 1;\n`\n\n### hasAction()\n\n public abstract boolean hasAction()\n\nRequired. The detailed rule defining how to route matched traffic.\n\n`.google.events.cloud.networkservices.v1.TcpRoute.RouteAction action = 2;`"]]