Documentation ¶
Index ¶
- Constants
- func BoolEmpty(val interface{}) string
- func BytesBase64Empty(val interface{}) string
- func Float32Empty(val interface{}) string
- func Float64Empty(val interface{}) string
- func Int32Empty(val interface{}) string
- func Int64Empty(val interface{}) string
- func StringEmpty(val interface{}) string
- func Uint32Empty(val interface{}) string
- func Uint64Empty(val interface{}) string
- type Constructor
- type ErrUndefinedSpecs
- type Manager
Constants ¶
const Name = "form-urlencoded"
Name represents the codec
Variables ¶
This section is empty.
Functions ¶
func BoolEmpty ¶
func BoolEmpty(val interface{}) string
BoolEmpty returns the given value as a bool or a empty bool if the value is nil
func BytesBase64Empty ¶
func BytesBase64Empty(val interface{}) string
BytesBase64Empty returns the given bytes buffer as a base64 string or a empty string if the value is nil
func Float32Empty ¶
func Float32Empty(val interface{}) string
Float32Empty returns the given value as a float32 or a empty float32 if the value is nil
func Float64Empty ¶
func Float64Empty(val interface{}) string
Float64Empty returns the given value as a float64 or a empty float64 if the value is nil
func Int32Empty ¶
func Int32Empty(val interface{}) string
Int32Empty returns the given value as a int32 or a empty int32 if the value is nil
func Int64Empty ¶
func Int64Empty(val interface{}) string
Int64Empty returns the given value as a int64 or a empty int64 if the value is nil
func StringEmpty ¶
func StringEmpty(val interface{}) string
StringEmpty returns the given value as a string or a empty string if the value is nil
func Uint32Empty ¶
func Uint32Empty(val interface{}) string
Uint32Empty returns the given value as a uint32 or a empty uint32 if the value is nil
func Uint64Empty ¶
func Uint64Empty(val interface{}) string
Uint64Empty returns the given value as a uint64 or a empty uint64 if the value is nil
Types ¶
type Constructor ¶
type Constructor struct { }
Constructor is capable of constructing new codec managers for the given resource and specs
func NewConstructor ¶
func NewConstructor() *Constructor
NewConstructor constructs a new www-form-urlencoded constructor
func (*Constructor) Name ¶
func (constructor *Constructor) Name() string
Name returns the name of the www-form-urlencoded codec constructor
func (*Constructor) New ¶
func (constructor *Constructor) New(resource string, specs *specs.ParameterMap) (codec.Manager, error)
New constructs a new www-form-urlencoded codec manager
type ErrUndefinedSpecs ¶
type ErrUndefinedSpecs struct{}
ErrUndefinedSpecs occurs when spacs are nil
func (ErrUndefinedSpecs) Error ¶
func (e ErrUndefinedSpecs) Error() string
Error returns a description of the given error as a string
func (ErrUndefinedSpecs) Prettify ¶
func (e ErrUndefinedSpecs) Prettify() prettyerr.Error
Prettify returns the prettified version of the given error
type Manager ¶
type Manager struct {
// contains filtered or unexported fields
}
Manager manages a specs object and allows to encode/decode messages
func (*Manager) Marshal ¶
Marshal marshals the given reference store into a www-form-urlencoded message. This method is called during runtime to encode a new message with the values stored inside the given reference store
func (*Manager) Property ¶
Property returns the manager property which is used to marshal and unmarshal data
func (*Manager) Unmarshal ¶
Unmarshal the given www-form-urlencoded io reader into the given reference store. This method is called during runtime to decode a new message and store it inside the given reference store.
Note: it does not work yet and returns error "not implemented yet" for every call.