Skip to content

Commit

Permalink
generate swift code
Browse files Browse the repository at this point in the history
  • Loading branch information
orkunkl committed Mar 11, 2020
1 parent 3f6a693 commit 03a2fec
Show file tree
Hide file tree
Showing 28 changed files with 18,812 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
// DO NOT EDIT.
//
// Generated by the Swift generator plugin for the protocol buffer compiler.
// Source: app/results.proto
//
// For information on using the generated types, please see the documentation:
// https://github.com/apple/swift-protobuf/

import Foundation
import SwiftProtobuf

// If the compiler emits an error on this type, it is because this file
// was generated by a version of the `protoc` Swift plug-in that is
// incompatible with the version of SwiftProtobuf to which you are linking.
// Please ensure that your are building against the same version of the API
// that was used to generate this file.
fileprivate struct _GeneratedWithProtocGenSwiftVersion: SwiftProtobuf.ProtobufAPIVersionCheck {
struct _2: SwiftProtobuf.ProtobufAPIVersion_2 {}
typealias Version = _2
}

/// ResultSet contains a list of keys or values
struct App_ResultSet {
// SwiftProtobuf.Message conformance is added in an extension below. See the
// `Message` and `Message+*Additions` files in the SwiftProtobuf library for
// methods supported on all messages.

var results: [Data] = []

var unknownFields = SwiftProtobuf.UnknownStorage()

init() {}
}

// MARK: - Code below here is support for the SwiftProtobuf runtime.

fileprivate let _protobuf_package = "app"

extension App_ResultSet: SwiftProtobuf.Message, SwiftProtobuf._MessageImplementationBase, SwiftProtobuf._ProtoNameProviding {
static let protoMessageName: String = _protobuf_package + ".ResultSet"
static let _protobuf_nameMap: SwiftProtobuf._NameMap = [
1: .same(proto: "results"),
]

mutating func decodeMessage<D: SwiftProtobuf.Decoder>(decoder: inout D) throws {
while let fieldNumber = try decoder.nextFieldNumber() {
switch fieldNumber {
case 1: try decoder.decodeRepeatedBytesField(value: &self.results)
default: break
}
}
}

func traverse<V: SwiftProtobuf.Visitor>(visitor: inout V) throws {
if !self.results.isEmpty {
try visitor.visitRepeatedBytesField(value: self.results, fieldNumber: 1)
}
try unknownFields.traverse(visitor: &visitor)
}

static func ==(lhs: App_ResultSet, rhs: App_ResultSet) -> Bool {
if lhs.results != rhs.results {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
Loading

0 comments on commit 03a2fec

Please sign in to comment.