attributes

package
v5.3.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 3, 2026 License: MIT Imports: 4 Imported by: 0

Documentation

Overview

Package attributes manages PSR-7-style request attributes stored in the request context, enabling data passing from Go middleware to PHP workers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func All

func All(r *http.Request) map[string][]string

All returns all context attributes.

func Get

func Get(r *http.Request, key string) any

Get gets the value from the request context. It replaces any existing values.

func Init

func Init(r *http.Request) *http.Request

Init returns request with new context and attribute bag.

func Set

func Set(r *http.Request, key string, value string) error

Set sets the key to value. It replaces any existing values. Context-specific.

Types

This section is empty.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL