Discover Packages
gitee.com/xvliang/ratchet
ratchet-examples
example4
packages
package
Version:
v0.0.0-...-52cbd5f
Opens a new window with list of versions in this module.
Published: Nov 8, 2022
License: MIT
Opens a new window with license information.
Imports: 4
Opens a new window with list of imports.
Imported by: 0
Opens a new window with list of known importers.
Documentation
Documentation
¶
View Source
const (
Query1Helper = "query1"
Query2Helper = "query2"
)
func NewMyTransformer() *myTransformer
Expose our DataProcessor for clients to use
type ReceivedData1 struct {
TypeHelper string `json:"type_helper,omitempty"`
ID int `json:"id,omitempty"`
Name string `json:"name,omitempty"`
}
type ReceivedData2 struct {
TypeHelper string `json:"type_helper,omitempty"`
ID int `json:"id,omitempty"`
City string `json:"city,omitempty"`
State string `json:"state,omitempty"`
}
type TransformedData struct {
UserID int `json:"user_id"`
Name string `json:"name"`
City string `json:"city"`
}
Source Files
¶
Click to show internal directories.
Click to hide internal directories.