本文整理匯總了Golang中github.com/shopgun/matilde/events/event.Event.PublishTimeStamp方法的典型用法代碼示例。如果您正苦於以下問題:Golang Event.PublishTimeStamp方法的具體用法?Golang Event.PublishTimeStamp怎麽用?Golang Event.PublishTimeStamp使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類github.com/shopgun/matilde/events/event.Event
的用法示例。
在下文中一共展示了Event.PublishTimeStamp方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的Golang代碼示例。
示例1: CleanCatalogPages
func CleanCatalogPages(
db db.Connector,
in *event.Event) (out clean.Catalog_pages, err Errors) {
out = clean.Catalog_pages{
Api_Build: in.Api_build,
Api_Version: in.Api,
Api_env: in.ApiEnv(),
App_id: in.App_id.Value,
App_groups: in.AppGroups(db),
Catalog_id: in.Catalog.Value,
Client_addr: in.Ipv4Ipv6(in.IP),
Client_app_version: in.ApiAppVersion(),
Client_user_agent: in.User_agent,
Dealer_id: in.Dealer.Value,
Expires: in.Expires(db),
Is_archive_user: in.Is_archive_user.Value,
Is_dealer_admin: in.Is_Dealer_admin.Value,
Is_user_defined_location: in.Location.GeoCoded(),
Is_uuid_ephemeral: in.Is_uuid_ephemeral.Value,
Query_string: in.Query_string,
Publish: in.PublishTimeStamp(db),
Run_from: in.RunFrom(db),
Server_addr: in.Ipv4Ipv6(in.Server_ip),
Timestamp: in.Times.Timestamp(),
Type: in.Type(),
User_id: in.User.Id.Value,
Uuid: in.User.Uuid.Value,
}
err = eventChecker(in, out)
return out, err
}
示例2: CleanOfferView
/*
CleanScopeAciton converts the input go struct containing the raw but with
surely correct types into the data we really want to keep Conversion errors
hare logged inside each conversion action once the event is cleaned is
checked for fatal missing fields
*/
func CleanOfferView(
db db.Connector,
in *event.Event) (out clean.Offer_View, err Errors) {
out = clean.Offer_View{
Api_Build: in.Api_build,
Api_Version: in.Api,
Api_env: in.ApiEnv(),
App_id: in.App_id.Value,
App_groups: in.AppGroups(db),
Catalog_id: in.GetCatalogId(db),
Client_addr: in.Ipv4Ipv6(in.IP),
Client_app_version: in.ApiAppVersion(),
Client_user_agent: in.User_agent,
Currency: event.CheckCurrency(in.Currency),
Dealer_id: in.Dealer.Value,
Expires: in.Expires(db),
Is_archive_user: in.Is_archive_user.Value,
Is_dealer_admin: in.Is_Dealer_admin.Value,
Is_user_defined_location: in.Location.GeoCoded(),
Is_uuid_ephemeral: in.Is_uuid_ephemeral.Value,
Query_string: in.Query_string,
Offer_id: in.Offer.Value,
Price: in.GetPrice(db),
Publish: in.PublishTimeStamp(db),
Request_geohash: in.Geohash(),
Request_latitude: in.Latitude(),
Request_longitude: in.Longitude(),
Request_radius: in.Location.ReqRadius,
Run_from: in.RunFrom(db),
Server_addr: in.Ipv4Ipv6(in.Server_ip),
Timestamp: in.Times.Timestamp(),
Type: in.Type(),
User_birth_year: in.GetByear(db),
User_gender: in.GetGender(db),
User_id: in.User.Id.Value,
Uuid: in.User.Uuid.Value,
}
err = eventChecker(in, out)
return out, err
}