Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func MeasureNameValuePairs ¶
func MeasureNameValuePairs(params []*NameValuePair) (n int)
MeasureNameValuePairs calculates memory size, or content length, required for storing or transmitting the specified name-value pairs.
Types ¶
type NameValuePair ¶
type NameValuePair struct { NameLength *vl.VariableLength ValueLength *vl.VariableLength Name []byte Value []byte }
NameValuePair is a name-value pair in accordance to the FastCGI Specification Version 1.1.
func NewNameValuePairFromStream ¶
func NewNameValuePairFromStream(stream io.Reader) (nvp *NameValuePair, err error)
NewNameValuePairFromStream reads a name-value pair from a byte stream.
func NewNameValuePairWithTextValue ¶
func NewNameValuePairWithTextValue(name string, value string) (nvp *NameValuePair, err error)
NewNameValuePairWithTextValue creates a name-value pair using the specified textual arguments.
func NewNameValuePairWithTextValueU ¶
func NewNameValuePairWithTextValueU(name string, value string) (nvp *NameValuePair)
NewNameValuePairWithTextValueU is an unsafe version of the 'NewNameValuePairWithTextValue' function. It is a helper-function for fast creation of a name-value pair using textual arguments. Please note that this function returns a NULL pointer on error.
func (*NameValuePair) Measure ¶
func (nvp *NameValuePair) Measure() (n int)
Measure calculates memory size, or content length, required for storing or transmitting of a single name-value pair as a FastCGI data.
func (*NameValuePair) ToBytes ¶
func (nvp *NameValuePair) ToBytes() (ba []byte, err error)
ToBytes returns the bytes storing the name-value pair in accordance to the FastCGI Specification Version 1.1.