Home / Function/ Benchmark_Bind_Cookie() — fiber Function Reference

Benchmark_Bind_Cookie() — fiber Function Reference

Architecture documentation for the Benchmark_Bind_Cookie() function in bind_test.go from the fiber codebase.

Entity Profile

Dependency Diagram

graph TD
  f16b674e_7e64_e2b2_cdba_69def5979cd7["Benchmark_Bind_Cookie()"]
  55065b01_f5dc_4e53_5a74_5ecc7aca8f52["bind_test.go"]
  f16b674e_7e64_e2b2_cdba_69def5979cd7 -->|defined in| 55065b01_f5dc_4e53_5a74_5ecc7aca8f52
  style f16b674e_7e64_e2b2_cdba_69def5979cd7 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

bind_test.go lines 1751–1776

func Benchmark_Bind_Cookie(b *testing.B) {
	var err error

	app := New()
	c := app.AcquireCtx(&fasthttp.RequestCtx{})

	type Cookie struct {
		Name  string
		Hobby []string
		ID    int
	}
	c.Request().SetBody([]byte(``))
	c.Request().Header.SetContentType("")

	c.Request().Header.SetCookie("id", "1")
	c.Request().Header.SetCookie("Name", "John Doe")
	c.Request().Header.SetCookie("Hobby", "golang,fiber")

	q := new(Cookie)
	b.ReportAllocs()

	for b.Loop() {
		err = c.Bind().Cookie(q)
	}
	require.NoError(b, err)
}

Domain

Subdomains

Defined In

Frequently Asked Questions

What does Benchmark_Bind_Cookie() do?
Benchmark_Bind_Cookie() is a function in the fiber codebase, defined in bind_test.go.
Where is Benchmark_Bind_Cookie() defined?
Benchmark_Bind_Cookie() is defined in bind_test.go at line 1751.

Analyze Your Own Codebase

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

Try Supermodel Free