Home / Function/ Benchmark_Route_Match_Star() — fiber Function Reference

Benchmark_Route_Match_Star() — fiber Function Reference

Architecture documentation for the Benchmark_Route_Match_Star() function in router_test.go from the fiber codebase.

Entity Profile

Dependency Diagram

graph TD
  fb2a4cc2_d458_58cd_faa9_3810fbe18216["Benchmark_Route_Match_Star()"]
  326d7e00_9e4f_d854_0c78_b9c0c93e5537["router_test.go"]
  fb2a4cc2_d458_58cd_faa9_3810fbe18216 -->|defined in| 326d7e00_9e4f_d854_0c78_b9c0c93e5537
  style fb2a4cc2_d458_58cd_faa9_3810fbe18216 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

router_test.go lines 1775–1801

func Benchmark_Route_Match_Star(b *testing.B) {
	var match bool
	var params [maxParams]string

	parsed := parseRoute("/*")
	route := &Route{
		use:         false,
		root:        false,
		star:        true,
		routeParser: parsed,
		Params:      parsed.params,
		path:        "/user/keys/bla",

		Path:   "/user/keys/bla",
		Method: "DELETE",
	}
	route.Handlers = append(route.Handlers, func(_ Ctx) error {
		return nil
	})

	for b.Loop() {
		match = route.match("/user/keys/bla", "/user/keys/bla", &params)
	}

	require.True(b, match)
	require.Equal(b, []string{"user/keys/bla"}, params[0:len(parsed.params)])
}

Domain

Subdomains

Defined In

Frequently Asked Questions

What does Benchmark_Route_Match_Star() do?
Benchmark_Route_Match_Star() is a function in the fiber codebase, defined in router_test.go.
Where is Benchmark_Route_Match_Star() defined?
Benchmark_Route_Match_Star() is defined in router_test.go at line 1775.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free