empty.pb.swift 2.8 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. // DO NOT EDIT.
  2. //
  3. // Generated by the Swift generator plugin for the protocol buffer compiler.
  4. // Source: src/proto/grpc/testing/empty.proto
  5. //
  6. // For information on using the generated types, please see the documentation:
  7. // https://github.com/apple/swift-protobuf/
  8. // Copyright 2015 gRPC authors.
  9. //
  10. // Licensed under the Apache License, Version 2.0 (the "License");
  11. // you may not use this file except in compliance with the License.
  12. // You may obtain a copy of the License at
  13. //
  14. // http://www.apache.org/licenses/LICENSE-2.0
  15. //
  16. // Unless required by applicable law or agreed to in writing, software
  17. // distributed under the License is distributed on an "AS IS" BASIS,
  18. // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  19. // See the License for the specific language governing permissions and
  20. // limitations under the License.
  21. import Foundation
  22. import SwiftProtobuf
  23. // If the compiler emits an error on this type, it is because this file
  24. // was generated by a version of the `protoc` Swift plug-in that is
  25. // incompatible with the version of SwiftProtobuf to which you are linking.
  26. // Please ensure that you are building against the same version of the API
  27. // that was used to generate this file.
  28. fileprivate struct _GeneratedWithProtocGenSwiftVersion: SwiftProtobuf.ProtobufAPIVersionCheck {
  29. struct _2: SwiftProtobuf.ProtobufAPIVersion_2 {}
  30. typealias Version = _2
  31. }
  32. /// An empty message that you can re-use to avoid defining duplicated empty
  33. /// messages in your project. A typical example is to use it as argument or the
  34. /// return value of a service API. For instance:
  35. ///
  36. /// service Foo {
  37. /// rpc Bar (grpc.testing.Empty) returns (grpc.testing.Empty) { };
  38. /// };
  39. public struct Grpc_Testing_Empty {
  40. // SwiftProtobuf.Message conformance is added in an extension below. See the
  41. // `Message` and `Message+*Additions` files in the SwiftProtobuf library for
  42. // methods supported on all messages.
  43. public var unknownFields = SwiftProtobuf.UnknownStorage()
  44. public init() {}
  45. }
  46. // MARK: - Code below here is support for the SwiftProtobuf runtime.
  47. fileprivate let _protobuf_package = "grpc.testing"
  48. extension Grpc_Testing_Empty: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
  49. public static let protoMessageName: String = _protobuf_package + ".Empty"
  50. public static let _protobuf_nameMap = SwiftProtobuf._NameMap()
  51. public mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
  52. while let _ = try decoder.nextFieldNumber() {
  53. }
  54. }
  55. public func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
  56. try unknownFields.traverse(visitor: &visitor)
  57. }
  58. public static func ==(lhs: Grpc_Testing_Empty, rhs: Grpc_Testing_Empty) -> Bool {
  59. if lhs.unknownFields != rhs.unknownFields {return false}
  60. return true
  61. }
  62. }