hooks_enabled.go 1.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. // Copyright 2019 The Go Authors. All rights reserved.
  2. // Use of this source code is governed by a BSD-style
  3. // license that can be found in the LICENSE file.
  4. // +build !use_golang_protobuf_v1
  5. package proto
  6. import (
  7. "github.com/golang/protobuf/internal/proto"
  8. )
  9. var (
  10. // Hooks for lib.go.
  11. setDefaultsAlt = proto.SetDefaults
  12. // Hooks for discard.go.
  13. discardUnknownAlt = proto.DiscardUnknown
  14. // Hooks for registry.go.
  15. registerEnumAlt = proto.RegisterEnum
  16. enumValueMapAlt = proto.EnumValueMap
  17. registerTypeAlt = proto.RegisterType
  18. registerMapTypeAlt = proto.RegisterMapType
  19. messageNameAlt = proto.MessageName
  20. messageTypeAlt = proto.MessageType
  21. registerFileAlt = proto.RegisterFile
  22. fileDescriptorAlt = proto.FileDescriptor
  23. registerExtensionAlt = proto.RegisterExtension
  24. registeredExtensionsAlt = proto.RegisteredExtensions
  25. // Hooks for text.go
  26. marshalTextAlt = proto.MarshalText
  27. marshalTextStringAlt = proto.MarshalTextString
  28. compactTextAlt = proto.CompactText
  29. compactTextStringAlt = proto.CompactTextString
  30. // Hooks for text_parser.go
  31. unmarshalTextAlt = proto.UnmarshalText
  32. )
  33. // Hooks for lib.go.
  34. type RequiredNotSetError = proto.RequiredNotSetError
  35. // Hooks for text.go
  36. type TextMarshaler = proto.TextMarshaler