• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    迪恩网络公众号

Golang proto.RegisterEnum函数代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Golang中github.com/gogo/protobuf/proto.RegisterEnum函数的典型用法代码示例。如果您正苦于以下问题:Golang RegisterEnum函数的具体用法?Golang RegisterEnum怎么用?Golang RegisterEnum使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。



在下文中一共展示了RegisterEnum函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Golang代码示例。

示例1: init

func init() {
	proto.RegisterEnum("badoo.phproxyd.RequestMsgid", RequestMsgid_name, RequestMsgid_value)
	proto.RegisterEnum("badoo.phproxyd.ResponseMsgid", ResponseMsgid_name, ResponseMsgid_value)
	proto.RegisterEnum("badoo.phproxyd.Errno", Errno_name, Errno_value)
	proto.RegisterEnum("badoo.phproxyd.PhproxydStatusT", PhproxydStatusT_name, PhproxydStatusT_value)
	proto.RegisterEnum("badoo.phproxyd.StoreT", StoreT_name, StoreT_value)
}
开发者ID:badoo,项目名称:thunder,代码行数:7,代码来源:phproxyd.pb.go


示例2: init

func init() {
	proto.RegisterEnum("internal.RPCType", RPCType_name, RPCType_value)
	proto.RegisterEnum("internal.Command_Type", Command_Type_name, Command_Type_value)
	proto.RegisterExtension(E_CreateNodeCommand_Command)
	proto.RegisterExtension(E_DeleteNodeCommand_Command)
	proto.RegisterExtension(E_CreateDatabaseCommand_Command)
	proto.RegisterExtension(E_DropDatabaseCommand_Command)
	proto.RegisterExtension(E_CreateRetentionPolicyCommand_Command)
	proto.RegisterExtension(E_DropRetentionPolicyCommand_Command)
	proto.RegisterExtension(E_SetDefaultRetentionPolicyCommand_Command)
	proto.RegisterExtension(E_UpdateRetentionPolicyCommand_Command)
	proto.RegisterExtension(E_CreateShardGroupCommand_Command)
	proto.RegisterExtension(E_DeleteShardGroupCommand_Command)
	proto.RegisterExtension(E_CreateContinuousQueryCommand_Command)
	proto.RegisterExtension(E_DropContinuousQueryCommand_Command)
	proto.RegisterExtension(E_CreateUserCommand_Command)
	proto.RegisterExtension(E_DropUserCommand_Command)
	proto.RegisterExtension(E_UpdateUserCommand_Command)
	proto.RegisterExtension(E_SetPrivilegeCommand_Command)
	proto.RegisterExtension(E_SetDataCommand_Command)
	proto.RegisterExtension(E_SetAdminPrivilegeCommand_Command)
	proto.RegisterExtension(E_UpdateNodeCommand_Command)
	proto.RegisterExtension(E_CreateSubscriptionCommand_Command)
	proto.RegisterExtension(E_DropSubscriptionCommand_Command)
	proto.RegisterExtension(E_RemovePeerCommand_Command)
}
开发者ID:nickrobinson,项目名称:influxdb,代码行数:26,代码来源:meta.pb.go


示例3: init

func init() {
	proto.RegisterType((*Artist)(nil), "proto2.Artist")
	proto.RegisterType((*Song)(nil), "proto2.Song")
	proto.RegisterType((*Album)(nil), "proto2.Album")
	proto.RegisterEnum("proto2.Instrument", Instrument_name, Instrument_value)
	proto.RegisterEnum("proto2.Genre", Genre_name, Genre_value)
}
开发者ID:bookerzzz,项目名称:letmegrpc,代码行数:7,代码来源:proto2.pb.go


示例4: init

func init() {
	proto.RegisterType((*Content)(nil), "apipb.Content")
	proto.RegisterType((*ContentListRequest)(nil), "apipb.ContentListRequest")
	proto.RegisterType((*ContentListResponse)(nil), "apipb.ContentListResponse")
	proto.RegisterType((*ContentGetRequest)(nil), "apipb.ContentGetRequest")
	proto.RegisterEnum("apipb.ContentListRequest_ListStatus", ContentListRequest_ListStatus_name, ContentListRequest_ListStatus_value)
	proto.RegisterEnum("apipb.ContentListRequest_SortBy", ContentListRequest_SortBy_name, ContentListRequest_SortBy_value)
	proto.RegisterEnum("apipb.ContentListRequest_SortOrder", ContentListRequest_SortOrder_name, ContentListRequest_SortOrder_value)
}
开发者ID:otsimo,项目名称:watch,代码行数:9,代码来源:content.pb.go


示例5: init

func init() {
	proto.RegisterType((*Artist)(nil), "serve.Artist")
	proto.RegisterType((*Song)(nil), "serve.Song")
	proto.RegisterType((*Album)(nil), "serve.Album")
	proto.RegisterType((*EndLess)(nil), "serve.EndLess")
	proto.RegisterType((*Tree)(nil), "serve.Tree")
	proto.RegisterEnum("serve.Instrument", Instrument_name, Instrument_value)
	proto.RegisterEnum("serve.Genre", Genre_name, Genre_value)
}
开发者ID:bookerzzz,项目名称:letmegrpc,代码行数:9,代码来源:serve.pb.go


示例6: init

func init() {
	proto.RegisterType((*TimeSeriesDatapoint)(nil), "cockroach.ts.TimeSeriesDatapoint")
	proto.RegisterType((*TimeSeriesData)(nil), "cockroach.ts.TimeSeriesData")
	proto.RegisterType((*Query)(nil), "cockroach.ts.Query")
	proto.RegisterType((*TimeSeriesQueryRequest)(nil), "cockroach.ts.TimeSeriesQueryRequest")
	proto.RegisterType((*TimeSeriesQueryResponse)(nil), "cockroach.ts.TimeSeriesQueryResponse")
	proto.RegisterType((*TimeSeriesQueryResponse_Result)(nil), "cockroach.ts.TimeSeriesQueryResponse.Result")
	proto.RegisterEnum("cockroach.ts.TimeSeriesQueryAggregator", TimeSeriesQueryAggregator_name, TimeSeriesQueryAggregator_value)
	proto.RegisterEnum("cockroach.ts.TimeSeriesQueryDerivative", TimeSeriesQueryDerivative_name, TimeSeriesQueryDerivative_value)
}
开发者ID:JKhawaja,项目名称:cockroach,代码行数:10,代码来源:timeseries.pb.go


示例7: init

func init() {
	proto.RegisterType((*Type)(nil), "google.protobuf.Type")
	proto.RegisterType((*Field)(nil), "google.protobuf.Field")
	proto.RegisterType((*Enum)(nil), "google.protobuf.Enum")
	proto.RegisterType((*EnumValue)(nil), "google.protobuf.EnumValue")
	proto.RegisterType((*Option)(nil), "google.protobuf.Option")
	proto.RegisterEnum("google.protobuf.Syntax", Syntax_name, Syntax_value)
	proto.RegisterEnum("google.protobuf.Field_Kind", Field_Kind_name, Field_Kind_value)
	proto.RegisterEnum("google.protobuf.Field_Cardinality", Field_Cardinality_name, Field_Cardinality_value)
}
开发者ID:peter-edge,项目名称:pb,代码行数:10,代码来源:type.pb.go


示例8: init

func init() {
	proto.RegisterType((*CatalogItem)(nil), "apipb.CatalogItem")
	proto.RegisterType((*Catalog)(nil), "apipb.Catalog")
	proto.RegisterType((*CatalogPullRequest)(nil), "apipb.CatalogPullRequest")
	proto.RegisterType((*CatalogListRequest)(nil), "apipb.CatalogListRequest")
	proto.RegisterType((*CatalogListResponse)(nil), "apipb.CatalogListResponse")
	proto.RegisterType((*CatalogApproveRequest)(nil), "apipb.CatalogApproveRequest")
	proto.RegisterEnum("apipb.CatalogCategory", CatalogCategory_name, CatalogCategory_value)
	proto.RegisterEnum("apipb.CatalogStatus", CatalogStatus_name, CatalogStatus_value)
	proto.RegisterEnum("apipb.CatalogListRequest_ListStatus", CatalogListRequest_ListStatus_name, CatalogListRequest_ListStatus_value)
}
开发者ID:otsimo,项目名称:otsimoctl,代码行数:11,代码来源:catalog.pb.go


示例9: init

func init() {
	proto.RegisterEnum("my.test.HatType", HatType_name, HatType_value)
	proto.RegisterEnum("my.test.Days", Days_name, Days_value)
	proto.RegisterEnum("my.test.Request_Color", Request_Color_name, Request_Color_value)
	proto.RegisterEnum("my.test.Reply_Entry_Game", Reply_Entry_Game_name, Reply_Entry_Game_value)
	proto.RegisterExtension(E_ReplyExtensions_Time)
	proto.RegisterExtension(E_ReplyExtensions_Carrot)
	proto.RegisterExtension(E_ReplyExtensions_Donut)
	proto.RegisterExtension(E_Tag)
	proto.RegisterExtension(E_Donut)
}
开发者ID:yunkai,项目名称:protobuf,代码行数:11,代码来源:test.pb.go


示例10: init

func init() {
	proto.RegisterType((*Trace)(nil), "google.devtools.cloudtrace.v1.Trace")
	proto.RegisterType((*Traces)(nil), "google.devtools.cloudtrace.v1.Traces")
	proto.RegisterType((*TraceSpan)(nil), "google.devtools.cloudtrace.v1.TraceSpan")
	proto.RegisterType((*ListTracesRequest)(nil), "google.devtools.cloudtrace.v1.ListTracesRequest")
	proto.RegisterType((*ListTracesResponse)(nil), "google.devtools.cloudtrace.v1.ListTracesResponse")
	proto.RegisterType((*GetTraceRequest)(nil), "google.devtools.cloudtrace.v1.GetTraceRequest")
	proto.RegisterType((*PatchTracesRequest)(nil), "google.devtools.cloudtrace.v1.PatchTracesRequest")
	proto.RegisterEnum("google.devtools.cloudtrace.v1.TraceSpan_SpanKind", TraceSpan_SpanKind_name, TraceSpan_SpanKind_value)
	proto.RegisterEnum("google.devtools.cloudtrace.v1.ListTracesRequest_ViewType", ListTracesRequest_ViewType_name, ListTracesRequest_ViewType_value)
}
开发者ID:peter-edge,项目名称:protoeasy-go,代码行数:11,代码来源:trace.pb.go


示例11: init

func init() {
	proto.RegisterType((*Entry)(nil), "raftpb.Entry")
	proto.RegisterType((*SnapshotMetadata)(nil), "raftpb.SnapshotMetadata")
	proto.RegisterType((*Snapshot)(nil), "raftpb.Snapshot")
	proto.RegisterType((*Message)(nil), "raftpb.Message")
	proto.RegisterType((*HardState)(nil), "raftpb.HardState")
	proto.RegisterType((*ConfState)(nil), "raftpb.ConfState")
	proto.RegisterType((*ConfChange)(nil), "raftpb.ConfChange")
	proto.RegisterEnum("raftpb.EntryType", EntryType_name, EntryType_value)
	proto.RegisterEnum("raftpb.MessageType", MessageType_name, MessageType_value)
	proto.RegisterEnum("raftpb.ConfChangeType", ConfChangeType_name, ConfChangeType_value)
}
开发者ID:achanda,项目名称:etcd,代码行数:12,代码来源:raft.pb.go


示例12: init

func init() {
	proto.RegisterEnum("ZStackOTASysIDs", ZStackOTASysIDs_name, ZStackOTASysIDs_value)
	proto.RegisterEnum("OtaMgrCmdIdT", OtaMgrCmdIdT_name, OtaMgrCmdIdT_value)
	proto.RegisterEnum("AddressMode", AddressMode_name, AddressMode_value)
	proto.RegisterEnum("GenericStatus", GenericStatus_name, GenericStatus_value)
	proto.RegisterEnum("OtaStatus", OtaStatus_name, OtaStatus_value)
	proto.RegisterEnum("OtaExecuteType", OtaExecuteType_name, OtaExecuteType_value)
	proto.RegisterEnum("OtaNotificationType", OtaNotificationType_name, OtaNotificationType_value)
	proto.RegisterEnum("OtaUpdateCnfStatus", OtaUpdateCnfStatus_name, OtaUpdateCnfStatus_value)
	proto.RegisterEnum("OtaEnableModes", OtaEnableModes_name, OtaEnableModes_value)
}
开发者ID:jemkzheng,项目名称:go-zigbee,代码行数:11,代码来源:otasrvr.pb.go


示例13: init

func init() {
	proto.RegisterEnum("main.AltarPlastic", AltarPlastic_name, AltarPlastic_value)
	proto.RegisterEnum("main.ArchBubble", ArchBubble_name, ArchBubble_value)
	proto.RegisterEnum("main.PlasticBagCertificate", PlasticBagCertificate_name, PlasticBagCertificate_value)
	proto.RegisterEnum("main.WineMicroscope", WineMicroscope_name, WineMicroscope_value)
	proto.RegisterEnum("main.MicrobeMiser", MicrobeMiser_name, MicrobeMiser_value)
	proto.RegisterEnum("main.CancerUserExperience", CancerUserExperience_name, CancerUserExperience_value)
	proto.RegisterEnum("main.EnzymeLift", EnzymeLift_name, EnzymeLift_value)
	proto.RegisterEnum("main.RadarBox", RadarBox_name, RadarBox_value)
	proto.RegisterEnum("main.AccountantPowder", AccountantPowder_name, AccountantPowder_value)
}
开发者ID:katydid,项目名称:v0.1,代码行数:11,代码来源:puddingmilkshake.pb.go


示例14: init

func init() {
	proto.RegisterEnum("main.TreeGrowthCategory", TreeGrowthCategory_name, TreeGrowthCategory_value)
	proto.RegisterEnum("main.GeneralAppearance", GeneralAppearance_name, GeneralAppearance_value)
	proto.RegisterEnum("main.TrunkStemming", TrunkStemming_name, TrunkStemming_value)
	proto.RegisterEnum("main.Ground", Ground_name, Ground_value)
	proto.RegisterEnum("main.Lean", Lean_name, Lean_value)
	proto.RegisterEnum("main.DeadBranches", DeadBranches_name, DeadBranches_value)
	proto.RegisterEnum("main.StormDamage", StormDamage_name, StormDamage_value)
	proto.RegisterEnum("main.PastManagement", PastManagement_name, PastManagement_value)
	proto.RegisterEnum("main.NotSureBool", NotSureBool_name, NotSureBool_value)
}
开发者ID:katydid,项目名称:v0.1,代码行数:11,代码来源:treeregister.pb.go


示例15: init

func init() {
	proto.RegisterType((*Country)(nil), "pb.geo.Country")
	proto.RegisterType((*LatLng)(nil), "pb.geo.LatLng")
	proto.RegisterType((*PostalAddress)(nil), "pb.geo.PostalAddress")
	proto.RegisterType((*SimplePostalAddress)(nil), "pb.geo.SimplePostalAddress")
	proto.RegisterEnum("pb.geo.StreetDirection", StreetDirection_name, StreetDirection_value)
}
开发者ID:peter-edge,项目名称:pb,代码行数:7,代码来源:geo.pb.go


示例16: init

func init() {
	proto.RegisterType((*NidOptEnum)(nil), "enumstringer.NidOptEnum")
	proto.RegisterType((*NinOptEnum)(nil), "enumstringer.NinOptEnum")
	proto.RegisterType((*NidRepEnum)(nil), "enumstringer.NidRepEnum")
	proto.RegisterType((*NinRepEnum)(nil), "enumstringer.NinRepEnum")
	proto.RegisterEnum("enumstringer.TheTestEnum", TheTestEnum_name, TheTestEnum_value)
}
开发者ID:stevvooe,项目名称:protobuf,代码行数:7,代码来源:enumstringer.pb.go


示例17: init

func init() {
	proto.RegisterType((*Column)(nil), "apipb.Column")
	proto.RegisterType((*TimeOfDay)(nil), "apipb.TimeOfDay")
	proto.RegisterType((*RowValue)(nil), "apipb.RowValue")
	proto.RegisterType((*Row)(nil), "apipb.Row")
	proto.RegisterType((*DataSet)(nil), "apipb.DataSet")
	proto.RegisterEnum("apipb.Column_Type", Column_Type_name, Column_Type_value)
}
开发者ID:otsimo,项目名称:otsimoctl,代码行数:8,代码来源:datasetmodels.pb.go


示例18: init

func init() {
	proto.RegisterType((*EmitRequest)(nil), "apipb.EmitRequest")
	proto.RegisterType((*EmitResponse)(nil), "apipb.EmitResponse")
	proto.RegisterType((*WatchRequest)(nil), "apipb.WatchRequest")
	proto.RegisterType((*WatchEvent)(nil), "apipb.WatchEvent")
	proto.RegisterType((*WatchResponse)(nil), "apipb.WatchResponse")
	proto.RegisterEnum("apipb.WatchEvent_EventType", WatchEvent_EventType_name, WatchEvent_EventType_value)
}
开发者ID:otsimo,项目名称:watch,代码行数:8,代码来源:watch.pb.go


示例19: init

func init() {
	proto.RegisterType((*GCPolicy)(nil), "cockroach.config.GCPolicy")
	proto.RegisterType((*Constraint)(nil), "cockroach.config.Constraint")
	proto.RegisterType((*Constraints)(nil), "cockroach.config.Constraints")
	proto.RegisterType((*ZoneConfig)(nil), "cockroach.config.ZoneConfig")
	proto.RegisterType((*SystemConfig)(nil), "cockroach.config.SystemConfig")
	proto.RegisterEnum("cockroach.config.Constraint_Type", Constraint_Type_name, Constraint_Type_value)
}
开发者ID:hvaara,项目名称:cockroach,代码行数:8,代码来源:config.pb.go


示例20: init

func init() {
	proto.RegisterType((*Message)(nil), "proto3_proto.Message")
	proto.RegisterType((*Nested)(nil), "proto3_proto.Nested")
	proto.RegisterType((*MessageWithMap)(nil), "proto3_proto.MessageWithMap")
	proto.RegisterType((*IntMap)(nil), "proto3_proto.IntMap")
	proto.RegisterType((*IntMaps)(nil), "proto3_proto.IntMaps")
	proto.RegisterEnum("proto3_proto.Message_Humour", Message_Humour_name, Message_Humour_value)
}
开发者ID:pascaldekloe,项目名称:colfer,代码行数:8,代码来源:proto3.pb.go



注:本文中的github.com/gogo/protobuf/proto.RegisterEnum函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Golang proto.RegisterExtension函数代码示例发布时间:2022-05-23
下一篇:
Golang proto.NewRequiredNotSetError函数代码示例发布时间:2022-05-23
热门推荐
热门话题
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap