本文整理汇总了Golang中github.com/gogo/protobuf/proto.RegisterType函数的典型用法代码示例。如果您正苦于以下问题:Golang RegisterType函数的具体用法?Golang RegisterType怎么用?Golang RegisterType使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了RegisterType函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Golang代码示例。
示例1: init
func init() {
proto.RegisterType((*Job)(nil), "k8s.io.kubernetes.pkg.apis.batch.v1.Job")
proto.RegisterType((*JobCondition)(nil), "k8s.io.kubernetes.pkg.apis.batch.v1.JobCondition")
proto.RegisterType((*JobList)(nil), "k8s.io.kubernetes.pkg.apis.batch.v1.JobList")
proto.RegisterType((*JobSpec)(nil), "k8s.io.kubernetes.pkg.apis.batch.v1.JobSpec")
proto.RegisterType((*JobStatus)(nil), "k8s.io.kubernetes.pkg.apis.batch.v1.JobStatus")
}
开发者ID:kubernetes,项目名称:kubernetes,代码行数:7,代码来源:generated.pb.go
示例2: init
func init() {
proto.RegisterType((*CertificateSigningRequest)(nil), "k8s.io.kubernetes.pkg.apis.certificates.v1alpha1.CertificateSigningRequest")
proto.RegisterType((*CertificateSigningRequestCondition)(nil), "k8s.io.kubernetes.pkg.apis.certificates.v1alpha1.CertificateSigningRequestCondition")
proto.RegisterType((*CertificateSigningRequestList)(nil), "k8s.io.kubernetes.pkg.apis.certificates.v1alpha1.CertificateSigningRequestList")
proto.RegisterType((*CertificateSigningRequestSpec)(nil), "k8s.io.kubernetes.pkg.apis.certificates.v1alpha1.CertificateSigningRequestSpec")
proto.RegisterType((*CertificateSigningRequestStatus)(nil), "k8s.io.kubernetes.pkg.apis.certificates.v1alpha1.CertificateSigningRequestStatus")
}
开发者ID:RyanBinfeng,项目名称:kubernetes,代码行数:7,代码来源:generated.pb.go
示例3: init
func init() {
proto.RegisterType((*ProviderGetRequest)(nil), "otsimo.ProviderGetRequest")
proto.RegisterType((*ProviderItem)(nil), "otsimo.ProviderItem")
proto.RegisterType((*ProviderItems)(nil), "otsimo.ProviderItems")
proto.RegisterType((*ProviderInfoRequest)(nil), "otsimo.ProviderInfoRequest")
proto.RegisterType((*ProviderInfo)(nil), "otsimo.ProviderInfo")
}
开发者ID:otsimo,项目名称:catalog,代码行数:7,代码来源:dashprovider.pb.go
示例4: init
func init() {
proto.RegisterType((*RaftCommand)(nil), "cockroach.roachpb.RaftCommand")
proto.RegisterType((*RaftTruncatedState)(nil), "cockroach.roachpb.RaftTruncatedState")
proto.RegisterType((*RaftTombstone)(nil), "cockroach.roachpb.RaftTombstone")
proto.RegisterType((*RaftSnapshotData)(nil), "cockroach.roachpb.RaftSnapshotData")
proto.RegisterType((*RaftSnapshotData_KeyValue)(nil), "cockroach.roachpb.RaftSnapshotData.KeyValue")
}
开发者ID:cuongdo,项目名称:cockroach,代码行数:7,代码来源:internal_raft.pb.go
示例5: 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
示例6: init
func init() {
proto.RegisterType((*BootstrapInfo)(nil), "cockroach.gossip.BootstrapInfo")
proto.RegisterType((*Node)(nil), "cockroach.gossip.Node")
proto.RegisterType((*Request)(nil), "cockroach.gossip.Request")
proto.RegisterType((*Response)(nil), "cockroach.gossip.Response")
proto.RegisterType((*Info)(nil), "cockroach.gossip.Info")
}
开发者ID:billhongs,项目名称:cockroach,代码行数:7,代码来源:gossip.pb.go
示例7: init
func init() {
proto.RegisterType((*ExtraValue)(nil), "k8s.io.kubernetes.pkg.apis.authentication.v1beta1.ExtraValue")
proto.RegisterType((*TokenReview)(nil), "k8s.io.kubernetes.pkg.apis.authentication.v1beta1.TokenReview")
proto.RegisterType((*TokenReviewSpec)(nil), "k8s.io.kubernetes.pkg.apis.authentication.v1beta1.TokenReviewSpec")
proto.RegisterType((*TokenReviewStatus)(nil), "k8s.io.kubernetes.pkg.apis.authentication.v1beta1.TokenReviewStatus")
proto.RegisterType((*UserInfo)(nil), "k8s.io.kubernetes.pkg.apis.authentication.v1beta1.UserInfo")
}
开发者ID:juanluisvaladas,项目名称:origin,代码行数:7,代码来源:generated.pb.go
示例8: init
func init() {
proto.RegisterType((*StoreRequestHeader)(nil), "cockroach.storage.StoreRequestHeader")
proto.RegisterType((*PollFrozenRequest)(nil), "cockroach.storage.PollFrozenRequest")
proto.RegisterType((*PollFrozenResponse)(nil), "cockroach.storage.PollFrozenResponse")
proto.RegisterType((*CollectChecksumRequest)(nil), "cockroach.storage.CollectChecksumRequest")
proto.RegisterType((*CollectChecksumResponse)(nil), "cockroach.storage.CollectChecksumResponse")
}
开发者ID:BramGruneir,项目名称:cockroach,代码行数:7,代码来源:api.pb.go
示例9: init
func init() {
proto.RegisterType((*StoreRequestHeader)(nil), "cockroach.storage.StoreRequestHeader")
proto.RegisterType((*PollFrozenRequest)(nil), "cockroach.storage.PollFrozenRequest")
proto.RegisterType((*PollFrozenResponse)(nil), "cockroach.storage.PollFrozenResponse")
proto.RegisterType((*ReservationRequest)(nil), "cockroach.storage.ReservationRequest")
proto.RegisterType((*ReservationResponse)(nil), "cockroach.storage.ReservationResponse")
}
开发者ID:yaojingguo,项目名称:cockroach,代码行数:7,代码来源:api.pb.go
示例10: init
func init() {
proto.RegisterType((*Authentication)(nil), "google.api.Authentication")
proto.RegisterType((*AuthenticationRule)(nil), "google.api.AuthenticationRule")
proto.RegisterType((*AuthProvider)(nil), "google.api.AuthProvider")
proto.RegisterType((*OAuthRequirements)(nil), "google.api.OAuthRequirements")
proto.RegisterType((*AuthRequirement)(nil), "google.api.AuthRequirement")
}
开发者ID:peter-edge,项目名称:protoeasy-go,代码行数:7,代码来源:auth.pb.go
示例11: init
func init() {
proto.RegisterType((*Project)(nil), "github.com.openshift.origin.pkg.project.api.v1.Project")
proto.RegisterType((*ProjectList)(nil), "github.com.openshift.origin.pkg.project.api.v1.ProjectList")
proto.RegisterType((*ProjectRequest)(nil), "github.com.openshift.origin.pkg.project.api.v1.ProjectRequest")
proto.RegisterType((*ProjectSpec)(nil), "github.com.openshift.origin.pkg.project.api.v1.ProjectSpec")
proto.RegisterType((*ProjectStatus)(nil), "github.com.openshift.origin.pkg.project.api.v1.ProjectStatus")
}
开发者ID:Xmagicer,项目名称:origin,代码行数:7,代码来源:generated.pb.go
示例12: init
func init() {
proto.RegisterType((*Eviction)(nil), "k8s.io.kubernetes.pkg.apis.policy.v1alpha1.Eviction")
proto.RegisterType((*PodDisruptionBudget)(nil), "k8s.io.kubernetes.pkg.apis.policy.v1alpha1.PodDisruptionBudget")
proto.RegisterType((*PodDisruptionBudgetList)(nil), "k8s.io.kubernetes.pkg.apis.policy.v1alpha1.PodDisruptionBudgetList")
proto.RegisterType((*PodDisruptionBudgetSpec)(nil), "k8s.io.kubernetes.pkg.apis.policy.v1alpha1.PodDisruptionBudgetSpec")
proto.RegisterType((*PodDisruptionBudgetStatus)(nil), "k8s.io.kubernetes.pkg.apis.policy.v1alpha1.PodDisruptionBudgetStatus")
}
开发者ID:juanluisvaladas,项目名称:origin,代码行数:7,代码来源:generated.pb.go
示例13: 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
示例14: 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
示例15: 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
示例16: 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
示例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((*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
示例19: 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
示例20: 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
注:本文中的github.com/gogo/protobuf/proto.RegisterType函数示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论