FieldNumbers.swift 1.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748
  1. // Sources/SwiftProtobufPluginLibrary/FieldNumbers.swift - Proto Field numbers
  2. //
  3. // Copyright (c) 2014 - 2017 Apple Inc. and the project authors
  4. // Licensed under Apache License v2.0 with Runtime Library Exception
  5. //
  6. // See LICENSE.txt for license information:
  7. // https://github.com/apple/swift-protobuf/blob/main/LICENSE.txt
  8. //
  9. // -----------------------------------------------------------------------------
  10. ///
  11. /// Field numbers needed by SwiftProtobufPluginLibrary since they currently aren't generated.
  12. ///
  13. // -----------------------------------------------------------------------------
  14. import Foundation
  15. import SwiftProtobuf
  16. extension Google_Protobuf_FileDescriptorProto {
  17. struct FieldNumbers {
  18. static let messageType: Int = 4
  19. static let enumType: Int = 5
  20. static let service: Int = 6
  21. static let `extension`: Int = 7
  22. }
  23. }
  24. extension Google_Protobuf_DescriptorProto {
  25. struct FieldNumbers {
  26. static let field: Int = 2
  27. static let nestedType: Int = 3
  28. static let enumType: Int = 4
  29. static let extensionRange: Int = 4
  30. static let `extension`: Int = 6
  31. static let oneofDecl: Int = 8
  32. }
  33. }
  34. extension Google_Protobuf_EnumDescriptorProto {
  35. struct FieldNumbers {
  36. static let value: Int = 2
  37. }
  38. }
  39. extension Google_Protobuf_ServiceDescriptorProto {
  40. struct FieldNumbers {
  41. static let method: Int = 2
  42. }
  43. }