Documentation
¶
Index ¶
- Variables
- func AsBool(source interface{}, state data.Map) (interface{}, error)
- func AsCollection(source interface{}, state data.Map) (interface{}, error)
- func AsData(source interface{}, state data.Map) (interface{}, error)
- func AsFloat(source interface{}, state data.Map) (interface{}, error)
- func AsFloat32(source interface{}, state data.Map) (interface{}, error)
- func AsFloat32Ptr(source interface{}, state data.Map) (interface{}, error)
- func AsInt(source interface{}, state data.Map) (interface{}, error)
- func AsJSON(source interface{}, state data.Map) (interface{}, error)
- func AsMap(source interface{}, state data.Map) (interface{}, error)
- func AsNewLineDelimitedJSON(source interface{}, state data.Map) (interface{}, error)
- func AsNumber(value interface{}, state data.Map) (interface{}, error)
- func AsString(source interface{}, state data.Map) (interface{}, error)
- func AsStringMap(source interface{}, state data.Map) (interface{}, error)
- func Base64Decode(source interface{}, state data.Map) (interface{}, error)
- func Base64DecodeText(source interface{}, state data.Map) (interface{}, error)
- func Base64Encode(source interface{}, state data.Map) (interface{}, error)
- func Base64RawURLDecode(source interface{}, state data.Map) (interface{}, error)
- func Base64RawURLEncode(source interface{}, state data.Map) (interface{}, error)
- func Concat(params interface{}, state data.Map) (interface{}, error)
- func Count(xPath interface{}, state data.Map) (interface{}, error)
- func Elapsed(source interface{}, state data.Map) (interface{}, error)
- func FormatTime(source interface{}, state data.Map) (interface{}, error)
- func IndexOf(source interface{}, state data.Map) (interface{}, error)
- func Join(args interface{}, state data.Map) (interface{}, error)
- func Keys(source interface{}, state data.Map) (interface{}, error)
- func Length(source interface{}, state data.Map) (interface{}, error)
- func LoadJSON(source interface{}, state data.Map) (interface{}, error)
- func Merge(params interface{}, state data.Map) (interface{}, error)
- func QueryEscape(source interface{}, state data.Map) (interface{}, error)
- func QueryUnescape(source interface{}, state data.Map) (interface{}, error)
- func Rand(params interface{}, state data.Map) (interface{}, error)
- func Register(aMap data.Map)
- func Replace(source interface{}, state data.Map) (interface{}, error)
- func Select(params interface{}, state data.Map) (interface{}, error)
- func Split(args interface{}, state data.Map) (interface{}, error)
- func StringKeys(source interface{}, state data.Map) (interface{}, error)
- func Sum(xPath interface{}, state data.Map) (interface{}, error)
- func ToLower(source interface{}, state data.Map) (interface{}, error)
- func ToUpper(source interface{}, state data.Map) (interface{}, error)
- func TrimSpace(source interface{}, state data.Map) (interface{}, error)
- func Type(source interface{}, state data.Map) (interface{}, error)
- func Values(source interface{}, state data.Map) (interface{}, error)
- type Doc
Constants ¶
This section is empty.
Variables ¶
var Predefined = data.Map{ "AsInt": AsInt, "AsString": AsString, "AsFloat": AsFloat, "AsFloat32": AsFloat32, "AsFloat32Ptr": AsFloat32Ptr, "AsBool": AsBool, "AsMap": AsMap, "AsData": AsData, "AsCollection": AsCollection, "AsJSON": AsJSON, "Type": Type, "Join": Join, "Split": Split, "Keys": Keys, "StringKeys": StringKeys, "Values": Values, "Length": Length, "Len": Length, "IndexOf": IndexOf, "FormatTime": FormatTime, "QueryEscape": QueryEscape, "QueryUnescape": QueryUnescape, "Base64Encode": Base64Encode, "Base64Decode": Base64Decode, "Base64RawURLEncode": Base64RawURLEncode, "Base64RawURLDecode": Base64RawURLDecode, "Base64DecodeText": Base64DecodeText, "TrimSpace": TrimSpace, "Elapsed": Elapsed, "Sum": Sum, "Count": Count, "AsNumber": AsNumber, "Select": Select, "Rand": Rand, "Concat": Concat, "Merge": Merge, "AsStringMap": AsStringMap, "Replace": Replace, "ToLower": ToLower, "ToUpper": ToUpper, "AsNewLineDelimitedJSON": AsNewLineDelimitedJSON, "LoadJSON": LoadJSON, }
Functions ¶
func AsBool ¶
AsBool converts source into bool
func AsCollection ¶
AsCollection converts source into a slice
func AsData ¶
AsData converts source into map or slice
func AsFloat ¶
AsFloat converts source into float64
func AsFloat32 ¶ added in v0.19.1
AsFloat32 converts source into float32
func AsFloat32Ptr ¶ added in v0.19.1
AsFloat32 converts source into float32
func AsInt ¶
AsInt converts source into int
func AsJSON ¶ added in v0.7.0
AsJSON converts source to JSON
func AsMap ¶
AsMap converts source into map
func AsNewLineDelimitedJSON ¶ added in v0.31.2
AsNewLineDelimitedJSON convers a slice into new line delimited JSON
func AsNumber ¶ added in v0.15.0
AsNumber return int or float
func AsString ¶
AsInt converts source into int
func AsStringMap ¶ added in v0.18.2
AsStringMap returns map[string]string
func Base64Decode ¶ added in v0.6.6
Base64Decode decodes source using base64.StdEncoding
func Base64DecodeText ¶ added in v0.7.0
Base64DecodeText decodes source using base64.StdEncoding to string
func Base64Encode ¶ added in v0.6.6
Base64Decode encodes source using base64.StdEncoding
func Base64RawURLDecode ¶ added in v0.35.0
Base64RawURLDecode decodes source using base64.RawURLEncoding
func Base64RawURLEncode ¶ added in v0.35.0
Base64RawURLEncode encodes source using base64.RawURLEncoding
func Concat ¶ added in v0.18.0
Concat concatenate supplied parameters, parameters
func Count ¶ added in v0.15.0
Count returns count of matched nodes leaf value
func Elapsed ¶ added in v0.15.0
Elapsed returns elapsed time
func FormatTime ¶
FormatTime return formatted time, it takes an array of arguments, the first is time express, or now followed by java style time format, optional timezone and truncate format .
func IndexOf ¶
IndexOf returns index of the matched slice elements or -1
func Join ¶
Join joins slice by separator
func Keys ¶
Keys returns keys of the supplied map
func Length ¶
Length returns length of slice or string
func LoadJSON ¶ added in v0.32.0
LoadJSON loads new line delimited or regular JSON into data structure
func Merge ¶ added in v0.18.0
Merge creates a new merged map for supplied maps, (mapOrPath1, mapOrPath2, mapOrPathN)
func QueryEscape ¶
QueryEscape returns url escaped text
func QueryUnescape ¶ added in v0.8.1
QueryUnescape returns url escaped text
func Rand ¶ added in v0.17.1
Rand returns random
func Replace ¶ added in v0.29.0
Replace replaces text with old and new fragments
func Select ¶ added in v0.17.0
Select returns all matched attributes from matched nodes, attributes can be alised with sourcePath:alias
func Split ¶ added in v0.23.8
Split split text to build a slice
func StringKeys ¶ added in v0.35.0
Keys returns keys of the supplied map
func Sum ¶ added in v0.15.0
Sum returns sums of matched nodes leaf value
func ToLower ¶ added in v0.31.1
Lower converts string to lower case
func ToUpper ¶ added in v0.31.1
Lower converts string to upper case
func TrimSpace ¶ added in v0.11.1
TrimSpace returns trims spaces from supplied text
func Type ¶ added in v0.7.0
Type returns source type
Types ¶
Source Files
¶
- conversion.go
- doc.go
- load.go
- register.go
- time.go
- util.go