MCPcopy
hub / github.com/gofiber/fiber / Route

Method Route

ctx.go:366–379  ·  view source on GitHub ↗

Route returns the matched Route struct.

()

Source from the content-addressed store, hash-verified

364
365// Route returns the matched Route struct.
366func (c *DefaultCtx) Route() *Route {
367 if c.route == nil {
368 // Fallback for fasthttp error handler; equals c.Method() without
369 // the variadic call so Route stays within the inlining budget
370 return &Route{
371 path: c.pathOriginal,
372 Path: c.pathOriginal,
373 Method: c.app.method(c.methodInt),
374 Handlers: emptyRouteHandlers[:],
375 Params: emptyRouteParams[:],
376 }
377 }
378 return c.route
379}
380
381// FullPath returns the matched route path, including any group prefixes.
382func (c *DefaultCtx) FullPath() string {

Callers 1

FullPathMethod · 0.95

Calls 1

methodMethod · 0.80

Tested by

no test coverage detected