Documentation ¶
Index ¶
- Variables
- func CheckNotNull(data []byte) bool
- func GetIDParameter(paramName string, reqForm url.Values) (bson.ObjectId, bool, error)
- func GetIntParameter(paramName string, reqForm url.Values) (int, bool, error)
- func GetStringParameter(paramName string, reqForm url.Values) (string, bool)
- func ParseRequestContent(request *http.Request) (int, error)
Constants ¶
This section is empty.
Variables ¶
View Source
var ( // ErrNoContent shows that the underlying HTTP request doesn't contain any data/content ErrNoContent = errors.New("No content has been received") // ErrInvalidFormFormat shows that the underlying HTTP request has its data or form in a incorrect or unparsable format ErrInvalidFormFormat = errors.New("The request form has an invalid format") )
Functions ¶
func CheckNotNull ¶
CheckNotNull verifies if the given []byte data is nil or represents the word "null". In the above stated cases, the method returns false
func GetIDParameter ¶
GetIDParameter extracts a bson.ObjectID value from url paramters, based on its name
func GetIntParameter ¶
GetIntParameter extracts an integer value from url paramters, based on its name
func GetStringParameter ¶
GetStringParameter extracts a string value from url paramters, based on its name
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.