Update protos.

pull/1/head
Matthew Chen 6 years ago
parent 4820af8ea5
commit 994e95a644

@ -234,10 +234,15 @@ message Verified {
message SyncMessage {
message Sent {
optional string destination = 1;
optional uint64 timestamp = 2;
optional DataMessage message = 3;
optional uint64 expirationStartTimestamp = 4;
message UnidentifiedDeliveryStatus {
optional string destination = 1;
optional bool unidentified = 2;
}
optional string destination = 1;
optional uint64 timestamp = 2;
optional DataMessage message = 3;
optional uint64 expirationStartTimestamp = 4;
repeated UnidentifiedDeliveryStatus unidentifiedStatus = 5;
}
message Contacts {

@ -57,7 +57,7 @@ struct FingerprintProtos_LogicalFingerprints {
/// Returns true if `version` has been explicitly set.
var hasVersion: Bool {return _storage._version != nil}
/// Clears the value of `version`. Subsequent reads from it will return its default value.
mutating func clearVersion() {_storage._version = nil}
mutating func clearVersion() {_uniqueStorage()._version = nil}
/// @required
var localFingerprint: FingerprintProtos_LogicalFingerprint {
@ -67,7 +67,7 @@ struct FingerprintProtos_LogicalFingerprints {
/// Returns true if `localFingerprint` has been explicitly set.
var hasLocalFingerprint: Bool {return _storage._localFingerprint != nil}
/// Clears the value of `localFingerprint`. Subsequent reads from it will return its default value.
mutating func clearLocalFingerprint() {_storage._localFingerprint = nil}
mutating func clearLocalFingerprint() {_uniqueStorage()._localFingerprint = nil}
/// @required
var remoteFingerprint: FingerprintProtos_LogicalFingerprint {
@ -77,7 +77,7 @@ struct FingerprintProtos_LogicalFingerprints {
/// Returns true if `remoteFingerprint` has been explicitly set.
var hasRemoteFingerprint: Bool {return _storage._remoteFingerprint != nil}
/// Clears the value of `remoteFingerprint`. Subsequent reads from it will return its default value.
mutating func clearRemoteFingerprint() {_storage._remoteFingerprint = nil}
mutating func clearRemoteFingerprint() {_uniqueStorage()._remoteFingerprint = nil}
var unknownFields = SwiftProtobuf.UnknownStorage()
@ -112,9 +112,9 @@ extension FingerprintProtos_LogicalFingerprint: SwiftProtobuf.Message, SwiftProt
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: FingerprintProtos_LogicalFingerprint) -> Bool {
if self._identityData != other._identityData {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: FingerprintProtos_LogicalFingerprint, rhs: FingerprintProtos_LogicalFingerprint) -> Bool {
if lhs._identityData != rhs._identityData {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
@ -179,19 +179,19 @@ extension FingerprintProtos_LogicalFingerprints: SwiftProtobuf.Message, SwiftPro
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: FingerprintProtos_LogicalFingerprints) -> Bool {
if _storage !== other._storage {
let storagesAreEqual: Bool = withExtendedLifetime((_storage, other._storage)) { (_args: (_StorageClass, _StorageClass)) in
static func ==(lhs: FingerprintProtos_LogicalFingerprints, rhs: FingerprintProtos_LogicalFingerprints) -> Bool {
if lhs._storage !== rhs._storage {
let storagesAreEqual: Bool = withExtendedLifetime((lhs._storage, rhs._storage)) { (_args: (_StorageClass, _StorageClass)) in
let _storage = _args.0
let other_storage = _args.1
if _storage._version != other_storage._version {return false}
if _storage._localFingerprint != other_storage._localFingerprint {return false}
if _storage._remoteFingerprint != other_storage._remoteFingerprint {return false}
let rhs_storage = _args.1
if _storage._version != rhs_storage._version {return false}
if _storage._localFingerprint != rhs_storage._localFingerprint {return false}
if _storage._remoteFingerprint != rhs_storage._remoteFingerprint {return false}
return true
}
if !storagesAreEqual {return false}
}
if unknownFields != other.unknownFields {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

@ -179,10 +179,10 @@ extension ProvisioningProtos_ProvisionEnvelope: SwiftProtobuf.Message, SwiftProt
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: ProvisioningProtos_ProvisionEnvelope) -> Bool {
if self._publicKey != other._publicKey {return false}
if self._body != other._body {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: ProvisioningProtos_ProvisionEnvelope, rhs: ProvisioningProtos_ProvisionEnvelope) -> Bool {
if lhs._publicKey != rhs._publicKey {return false}
if lhs._body != rhs._body {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
@ -239,15 +239,15 @@ extension ProvisioningProtos_ProvisionMessage: SwiftProtobuf.Message, SwiftProto
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: ProvisioningProtos_ProvisionMessage) -> Bool {
if self._identityKeyPublic != other._identityKeyPublic {return false}
if self._identityKeyPrivate != other._identityKeyPrivate {return false}
if self._number != other._number {return false}
if self._provisioningCode != other._provisioningCode {return false}
if self._userAgent != other._userAgent {return false}
if self._profileKey != other._profileKey {return false}
if self._readReceipts != other._readReceipts {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: ProvisioningProtos_ProvisionMessage, rhs: ProvisioningProtos_ProvisionMessage) -> Bool {
if lhs._identityKeyPublic != rhs._identityKeyPublic {return false}
if lhs._identityKeyPrivate != rhs._identityKeyPrivate {return false}
if lhs._number != rhs._number {return false}
if lhs._provisioningCode != rhs._provisioningCode {return false}
if lhs._userAgent != rhs._userAgent {return false}
if lhs._profileKey != rhs._profileKey {return false}
if lhs._readReceipts != rhs._readReceipts {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

@ -3151,6 +3151,114 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
#endif
// MARK: - SSKProtoSyncMessageSentUnidentifiedDeliveryStatus
@objc public class SSKProtoSyncMessageSentUnidentifiedDeliveryStatus: NSObject {
// MARK: - SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder
@objc public class func builder() -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder {
return SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder()
}
// asBuilder() constructs a builder that reflects the proto's contents.
@objc public func asBuilder() -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder {
let builder = SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder()
if let _value = destination {
builder.setDestination(_value)
}
if hasUnidentified {
builder.setUnidentified(unidentified)
}
return builder
}
@objc public class SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder: NSObject {
private var proto = SignalServiceProtos_SyncMessage.Sent.UnidentifiedDeliveryStatus()
@objc fileprivate override init() {}
@objc public func setDestination(_ valueParam: String) {
proto.destination = valueParam
}
@objc public func setUnidentified(_ valueParam: Bool) {
proto.unidentified = valueParam
}
@objc public func build() throws -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatus {
return try SSKProtoSyncMessageSentUnidentifiedDeliveryStatus.parseProto(proto)
}
@objc public func buildSerializedData() throws -> Data {
return try SSKProtoSyncMessageSentUnidentifiedDeliveryStatus.parseProto(proto).serializedData()
}
}
fileprivate let proto: SignalServiceProtos_SyncMessage.Sent.UnidentifiedDeliveryStatus
@objc public var destination: String? {
guard proto.hasDestination else {
return nil
}
return proto.destination
}
@objc public var hasDestination: Bool {
return proto.hasDestination
}
@objc public var unidentified: Bool {
return proto.unidentified
}
@objc public var hasUnidentified: Bool {
return proto.hasUnidentified
}
private init(proto: SignalServiceProtos_SyncMessage.Sent.UnidentifiedDeliveryStatus) {
self.proto = proto
}
@objc
public func serializedData() throws -> Data {
return try self.proto.serializedData()
}
@objc public class func parseData(_ serializedData: Data) throws -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatus {
let proto = try SignalServiceProtos_SyncMessage.Sent.UnidentifiedDeliveryStatus(serializedData: serializedData)
return try parseProto(proto)
}
fileprivate class func parseProto(_ proto: SignalServiceProtos_SyncMessage.Sent.UnidentifiedDeliveryStatus) throws -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatus {
// MARK: - Begin Validation Logic for SSKProtoSyncMessageSentUnidentifiedDeliveryStatus -
// MARK: - End Validation Logic for SSKProtoSyncMessageSentUnidentifiedDeliveryStatus -
let result = SSKProtoSyncMessageSentUnidentifiedDeliveryStatus(proto: proto)
return result
}
@objc public override var debugDescription: String {
return "\(proto)"
}
}
#if DEBUG
extension SSKProtoSyncMessageSentUnidentifiedDeliveryStatus {
@objc public func serializedDataIgnoringErrors() -> Data? {
return try! self.serializedData()
}
}
extension SSKProtoSyncMessageSentUnidentifiedDeliveryStatus.SSKProtoSyncMessageSentUnidentifiedDeliveryStatusBuilder {
@objc public func buildIgnoringErrors() -> SSKProtoSyncMessageSentUnidentifiedDeliveryStatus? {
return try! self.build()
}
}
#endif
// MARK: - SSKProtoSyncMessageSent
@objc public class SSKProtoSyncMessageSent: NSObject {
@ -3176,6 +3284,7 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
if hasExpirationStartTimestamp {
builder.setExpirationStartTimestamp(expirationStartTimestamp)
}
builder.setUnidentifiedStatus(unidentifiedStatus)
return builder
}
@ -3201,6 +3310,16 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
proto.expirationStartTimestamp = valueParam
}
@objc public func addUnidentifiedStatus(_ valueParam: SSKProtoSyncMessageSentUnidentifiedDeliveryStatus) {
var items = proto.unidentifiedStatus
items.append(valueParam.proto)
proto.unidentifiedStatus = items
}
@objc public func setUnidentifiedStatus(_ wrappedItems: [SSKProtoSyncMessageSentUnidentifiedDeliveryStatus]) {
proto.unidentifiedStatus = wrappedItems.map { $0.proto }
}
@objc public func build() throws -> SSKProtoSyncMessageSent {
return try SSKProtoSyncMessageSent.parseProto(proto)
}
@ -3214,6 +3333,8 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
@objc public let message: SSKProtoDataMessage?
@objc public let unidentifiedStatus: [SSKProtoSyncMessageSentUnidentifiedDeliveryStatus]
@objc public var destination: String? {
guard proto.hasDestination else {
return nil
@ -3239,9 +3360,11 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
}
private init(proto: SignalServiceProtos_SyncMessage.Sent,
message: SSKProtoDataMessage?) {
message: SSKProtoDataMessage?,
unidentifiedStatus: [SSKProtoSyncMessageSentUnidentifiedDeliveryStatus]) {
self.proto = proto
self.message = message
self.unidentifiedStatus = unidentifiedStatus
}
@objc
@ -3260,12 +3383,16 @@ extension SSKProtoVerified.SSKProtoVerifiedBuilder {
message = try SSKProtoDataMessage.parseProto(proto.message)
}
var unidentifiedStatus: [SSKProtoSyncMessageSentUnidentifiedDeliveryStatus] = []
unidentifiedStatus = try proto.unidentifiedStatus.map { try SSKProtoSyncMessageSentUnidentifiedDeliveryStatus.parseProto($0) }
// MARK: - Begin Validation Logic for SSKProtoSyncMessageSent -
// MARK: - End Validation Logic for SSKProtoSyncMessageSent -
let result = SSKProtoSyncMessageSent(proto: proto,
message: message)
message: message,
unidentifiedStatus: unidentifiedStatus)
return result
}

@ -133,9 +133,9 @@ extension IOSProtos_BackupSnapshot: SwiftProtobuf.Message, SwiftProtobuf._Messag
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: IOSProtos_BackupSnapshot) -> Bool {
if self.entity != other.entity {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: IOSProtos_BackupSnapshot, rhs: IOSProtos_BackupSnapshot) -> Bool {
if lhs.entity != rhs.entity {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
@ -167,10 +167,10 @@ extension IOSProtos_BackupSnapshot.BackupEntity: SwiftProtobuf.Message, SwiftPro
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: IOSProtos_BackupSnapshot.BackupEntity) -> Bool {
if self._type != other._type {return false}
if self._entityData != other._entityData {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: IOSProtos_BackupSnapshot.BackupEntity, rhs: IOSProtos_BackupSnapshot.BackupEntity) -> Bool {
if lhs._type != rhs._type {return false}
if lhs._entityData != rhs._entityData {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

@ -151,7 +151,7 @@ struct WebSocketProtos_WebSocketMessage {
/// Returns true if `type` has been explicitly set.
var hasType: Bool {return _storage._type != nil}
/// Clears the value of `type`. Subsequent reads from it will return its default value.
mutating func clearType() {_storage._type = nil}
mutating func clearType() {_uniqueStorage()._type = nil}
var request: WebSocketProtos_WebSocketRequestMessage {
get {return _storage._request ?? WebSocketProtos_WebSocketRequestMessage()}
@ -160,7 +160,7 @@ struct WebSocketProtos_WebSocketMessage {
/// Returns true if `request` has been explicitly set.
var hasRequest: Bool {return _storage._request != nil}
/// Clears the value of `request`. Subsequent reads from it will return its default value.
mutating func clearRequest() {_storage._request = nil}
mutating func clearRequest() {_uniqueStorage()._request = nil}
var response: WebSocketProtos_WebSocketResponseMessage {
get {return _storage._response ?? WebSocketProtos_WebSocketResponseMessage()}
@ -169,7 +169,7 @@ struct WebSocketProtos_WebSocketMessage {
/// Returns true if `response` has been explicitly set.
var hasResponse: Bool {return _storage._response != nil}
/// Clears the value of `response`. Subsequent reads from it will return its default value.
mutating func clearResponse() {_storage._response = nil}
mutating func clearResponse() {_uniqueStorage()._response = nil}
var unknownFields = SwiftProtobuf.UnknownStorage()
@ -261,13 +261,13 @@ extension WebSocketProtos_WebSocketRequestMessage: SwiftProtobuf.Message, SwiftP
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: WebSocketProtos_WebSocketRequestMessage) -> Bool {
if self._verb != other._verb {return false}
if self._path != other._path {return false}
if self._body != other._body {return false}
if self.headers != other.headers {return false}
if self._requestID != other._requestID {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: WebSocketProtos_WebSocketRequestMessage, rhs: WebSocketProtos_WebSocketRequestMessage) -> Bool {
if lhs._verb != rhs._verb {return false}
if lhs._path != rhs._path {return false}
if lhs._body != rhs._body {return false}
if lhs.headers != rhs.headers {return false}
if lhs._requestID != rhs._requestID {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
@ -314,13 +314,13 @@ extension WebSocketProtos_WebSocketResponseMessage: SwiftProtobuf.Message, Swift
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: WebSocketProtos_WebSocketResponseMessage) -> Bool {
if self._requestID != other._requestID {return false}
if self._status != other._status {return false}
if self._message != other._message {return false}
if self.headers != other.headers {return false}
if self._body != other._body {return false}
if unknownFields != other.unknownFields {return false}
static func ==(lhs: WebSocketProtos_WebSocketResponseMessage, rhs: WebSocketProtos_WebSocketResponseMessage) -> Bool {
if lhs._requestID != rhs._requestID {return false}
if lhs._status != rhs._status {return false}
if lhs._message != rhs._message {return false}
if lhs.headers != rhs.headers {return false}
if lhs._body != rhs._body {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}
@ -385,19 +385,19 @@ extension WebSocketProtos_WebSocketMessage: SwiftProtobuf.Message, SwiftProtobuf
try unknownFields.traverse(visitor: &visitor)
}
func _protobuf_generated_isEqualTo(other: WebSocketProtos_WebSocketMessage) -> Bool {
if _storage !== other._storage {
let storagesAreEqual: Bool = withExtendedLifetime((_storage, other._storage)) { (_args: (_StorageClass, _StorageClass)) in
static func ==(lhs: WebSocketProtos_WebSocketMessage, rhs: WebSocketProtos_WebSocketMessage) -> Bool {
if lhs._storage !== rhs._storage {
let storagesAreEqual: Bool = withExtendedLifetime((lhs._storage, rhs._storage)) { (_args: (_StorageClass, _StorageClass)) in
let _storage = _args.0
let other_storage = _args.1
if _storage._type != other_storage._type {return false}
if _storage._request != other_storage._request {return false}
if _storage._response != other_storage._response {return false}
let rhs_storage = _args.1
if _storage._type != rhs_storage._type {return false}
if _storage._request != rhs_storage._request {return false}
if _storage._response != rhs_storage._response {return false}
return true
}
if !storagesAreEqual {return false}
}
if unknownFields != other.unknownFields {return false}
if lhs.unknownFields != rhs.unknownFields {return false}
return true
}
}

Loading…
Cancel
Save