|
|
|
@ -1,4 +1,6 @@
|
|
|
|
|
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
|
|
|
|
//
|
|
|
|
|
// Copyright (c) 2017 Open Whisper Systems. All rights reserved.
|
|
|
|
|
//
|
|
|
|
|
|
|
|
|
|
#import "OWSSignalServiceProtos.pb.h"
|
|
|
|
|
// @@protoc_insertion_point(imports)
|
|
|
|
@ -5375,6 +5377,7 @@ static OWSSignalServiceProtosSyncMessageRead* defaultOWSSignalServiceProtosSyncM
|
|
|
|
|
@property (strong) NSData* thumbnail;
|
|
|
|
|
@property (strong) NSData* digest;
|
|
|
|
|
@property (strong) NSString* fileName;
|
|
|
|
|
@property UInt32 flags;
|
|
|
|
|
@end
|
|
|
|
|
|
|
|
|
|
@implementation OWSSignalServiceProtosAttachmentPointer
|
|
|
|
@ -5428,6 +5431,15 @@ static OWSSignalServiceProtosSyncMessageRead* defaultOWSSignalServiceProtosSyncM
|
|
|
|
|
hasFileName_ = !!_value_;
|
|
|
|
|
}
|
|
|
|
|
@synthesize fileName;
|
|
|
|
|
- (BOOL)hasFlags
|
|
|
|
|
{
|
|
|
|
|
return !!hasFlags_;
|
|
|
|
|
}
|
|
|
|
|
- (void)setHasFlags:(BOOL)_value_
|
|
|
|
|
{
|
|
|
|
|
hasFlags_ = !!_value_;
|
|
|
|
|
}
|
|
|
|
|
@synthesize flags;
|
|
|
|
|
- (instancetype) init {
|
|
|
|
|
if ((self = [super init])) {
|
|
|
|
|
self.id = 0L;
|
|
|
|
@ -5437,6 +5449,7 @@ static OWSSignalServiceProtosSyncMessageRead* defaultOWSSignalServiceProtosSyncM
|
|
|
|
|
self.thumbnail = [NSData data];
|
|
|
|
|
self.digest = [NSData data];
|
|
|
|
|
self.fileName = @"";
|
|
|
|
|
self.flags = 0;
|
|
|
|
|
}
|
|
|
|
|
return self;
|
|
|
|
|
}
|
|
|
|
@ -5477,6 +5490,9 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (self.hasFileName) {
|
|
|
|
|
[output writeString:7 value:self.fileName];
|
|
|
|
|
}
|
|
|
|
|
if (self.hasFlags) {
|
|
|
|
|
[output writeUInt32:8 value:self.flags];
|
|
|
|
|
}
|
|
|
|
|
[self.unknownFields writeToCodedOutputStream:output];
|
|
|
|
|
}
|
|
|
|
|
- (SInt32) serializedSize {
|
|
|
|
@ -5507,6 +5523,9 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (self.hasFileName) {
|
|
|
|
|
size_ += computeStringSize(7, self.fileName);
|
|
|
|
|
}
|
|
|
|
|
if (self.hasFlags) {
|
|
|
|
|
size_ += computeUInt32Size(8, self.flags);
|
|
|
|
|
}
|
|
|
|
|
size_ += self.unknownFields.serializedSize;
|
|
|
|
|
memoizedSerializedSize = size_;
|
|
|
|
|
return size_;
|
|
|
|
@ -5563,6 +5582,9 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (self.hasFileName) {
|
|
|
|
|
[output appendFormat:@"%@%@: %@\n", indent, @"fileName", self.fileName];
|
|
|
|
|
}
|
|
|
|
|
if (self.hasFlags) {
|
|
|
|
|
[output appendFormat:@"%@%@: %@\n", indent, @"flags", [NSNumber numberWithInteger:self.flags]];
|
|
|
|
|
}
|
|
|
|
|
[self.unknownFields writeDescriptionTo:output withIndent:indent];
|
|
|
|
|
}
|
|
|
|
|
- (void) storeInDictionary:(NSMutableDictionary *)dictionary {
|
|
|
|
@ -5587,6 +5609,9 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (self.hasFileName) {
|
|
|
|
|
[dictionary setObject: self.fileName forKey: @"fileName"];
|
|
|
|
|
}
|
|
|
|
|
if (self.hasFlags) {
|
|
|
|
|
[dictionary setObject:[NSNumber numberWithInteger:self.flags] forKey:@"flags"];
|
|
|
|
|
}
|
|
|
|
|
[self.unknownFields storeInDictionary:dictionary];
|
|
|
|
|
}
|
|
|
|
|
- (BOOL) isEqual:(id)other {
|
|
|
|
@ -5597,22 +5622,19 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
return NO;
|
|
|
|
|
}
|
|
|
|
|
OWSSignalServiceProtosAttachmentPointer *otherMessage = other;
|
|
|
|
|
return
|
|
|
|
|
self.hasId == otherMessage.hasId &&
|
|
|
|
|
(!self.hasId || self.id == otherMessage.id) &&
|
|
|
|
|
self.hasContentType == otherMessage.hasContentType &&
|
|
|
|
|
(!self.hasContentType || [self.contentType isEqual:otherMessage.contentType]) &&
|
|
|
|
|
self.hasKey == otherMessage.hasKey &&
|
|
|
|
|
(!self.hasKey || [self.key isEqual:otherMessage.key]) &&
|
|
|
|
|
self.hasSize == otherMessage.hasSize &&
|
|
|
|
|
(!self.hasSize || self.size == otherMessage.size) &&
|
|
|
|
|
self.hasThumbnail == otherMessage.hasThumbnail &&
|
|
|
|
|
(!self.hasThumbnail || [self.thumbnail isEqual:otherMessage.thumbnail]) &&
|
|
|
|
|
self.hasDigest == otherMessage.hasDigest &&
|
|
|
|
|
(!self.hasDigest || [self.digest isEqual:otherMessage.digest]) &&
|
|
|
|
|
self.hasFileName == otherMessage.hasFileName &&
|
|
|
|
|
(!self.hasFileName || [self.fileName isEqual:otherMessage.fileName]) &&
|
|
|
|
|
(self.unknownFields == otherMessage.unknownFields || (self.unknownFields != nil && [self.unknownFields isEqual:otherMessage.unknownFields]));
|
|
|
|
|
return self.hasId == otherMessage.hasId && (!self.hasId || self.id == otherMessage.id)
|
|
|
|
|
&& self.hasContentType == otherMessage.hasContentType
|
|
|
|
|
&& (!self.hasContentType || [self.contentType isEqual:otherMessage.contentType])
|
|
|
|
|
&& self.hasKey == otherMessage.hasKey && (!self.hasKey || [self.key isEqual:otherMessage.key])
|
|
|
|
|
&& self.hasSize == otherMessage.hasSize && (!self.hasSize || self.size == otherMessage.size)
|
|
|
|
|
&& self.hasThumbnail == otherMessage.hasThumbnail
|
|
|
|
|
&& (!self.hasThumbnail || [self.thumbnail isEqual:otherMessage.thumbnail])
|
|
|
|
|
&& self.hasDigest == otherMessage.hasDigest && (!self.hasDigest || [self.digest isEqual:otherMessage.digest])
|
|
|
|
|
&& self.hasFileName == otherMessage.hasFileName
|
|
|
|
|
&& (!self.hasFileName || [self.fileName isEqual:otherMessage.fileName]) && self.hasFlags == otherMessage.hasFlags
|
|
|
|
|
&& (!self.hasFlags || self.flags == otherMessage.flags)
|
|
|
|
|
&& (self.unknownFields == otherMessage.unknownFields
|
|
|
|
|
|| (self.unknownFields != nil && [self.unknownFields isEqual:otherMessage.unknownFields]));
|
|
|
|
|
}
|
|
|
|
|
- (NSUInteger) hash {
|
|
|
|
|
__block NSUInteger hashCode = 7;
|
|
|
|
@ -5637,11 +5659,33 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (self.hasFileName) {
|
|
|
|
|
hashCode = hashCode * 31 + [self.fileName hash];
|
|
|
|
|
}
|
|
|
|
|
if (self.hasFlags) {
|
|
|
|
|
hashCode = hashCode * 31 + [[NSNumber numberWithInteger:self.flags] hash];
|
|
|
|
|
}
|
|
|
|
|
hashCode = hashCode * 31 + [self.unknownFields hash];
|
|
|
|
|
return hashCode;
|
|
|
|
|
}
|
|
|
|
|
@end
|
|
|
|
|
|
|
|
|
|
BOOL OWSSignalServiceProtosAttachmentPointerFlagsIsValidValue(OWSSignalServiceProtosAttachmentPointerFlags value)
|
|
|
|
|
{
|
|
|
|
|
switch (value) {
|
|
|
|
|
case OWSSignalServiceProtosAttachmentPointerFlagsVoiceMessage:
|
|
|
|
|
return YES;
|
|
|
|
|
default:
|
|
|
|
|
return NO;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
NSString *NSStringFromOWSSignalServiceProtosAttachmentPointerFlags(OWSSignalServiceProtosAttachmentPointerFlags value)
|
|
|
|
|
{
|
|
|
|
|
switch (value) {
|
|
|
|
|
case OWSSignalServiceProtosAttachmentPointerFlagsVoiceMessage:
|
|
|
|
|
return @"OWSSignalServiceProtosAttachmentPointerFlagsVoiceMessage";
|
|
|
|
|
default:
|
|
|
|
|
return nil;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
@interface OWSSignalServiceProtosAttachmentPointerBuilder()
|
|
|
|
|
@property (strong) OWSSignalServiceProtosAttachmentPointer* resultAttachmentPointer;
|
|
|
|
|
@end
|
|
|
|
@ -5701,6 +5745,9 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
if (other.hasFileName) {
|
|
|
|
|
[self setFileName:other.fileName];
|
|
|
|
|
}
|
|
|
|
|
if (other.hasFlags) {
|
|
|
|
|
[self setFlags:other.flags];
|
|
|
|
|
}
|
|
|
|
|
[self mergeUnknownFields:other.unknownFields];
|
|
|
|
|
return self;
|
|
|
|
|
}
|
|
|
|
@ -5750,6 +5797,10 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
[self setFileName:[input readString]];
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
case 64: {
|
|
|
|
|
[self setFlags:[input readUInt32]];
|
|
|
|
|
break;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
@ -5865,6 +5916,26 @@ static OWSSignalServiceProtosAttachmentPointer* defaultOWSSignalServiceProtosAtt
|
|
|
|
|
resultAttachmentPointer.fileName = @"";
|
|
|
|
|
return self;
|
|
|
|
|
}
|
|
|
|
|
- (BOOL)hasFlags
|
|
|
|
|
{
|
|
|
|
|
return resultAttachmentPointer.hasFlags;
|
|
|
|
|
}
|
|
|
|
|
- (UInt32)flags
|
|
|
|
|
{
|
|
|
|
|
return resultAttachmentPointer.flags;
|
|
|
|
|
}
|
|
|
|
|
- (OWSSignalServiceProtosAttachmentPointerBuilder *)setFlags:(UInt32)value
|
|
|
|
|
{
|
|
|
|
|
resultAttachmentPointer.hasFlags = YES;
|
|
|
|
|
resultAttachmentPointer.flags = value;
|
|
|
|
|
return self;
|
|
|
|
|
}
|
|
|
|
|
- (OWSSignalServiceProtosAttachmentPointerBuilder *)clearFlags
|
|
|
|
|
{
|
|
|
|
|
resultAttachmentPointer.hasFlags = NO;
|
|
|
|
|
resultAttachmentPointer.flags = 0;
|
|
|
|
|
return self;
|
|
|
|
|
}
|
|
|
|
|
@end
|
|
|
|
|
|
|
|
|
|
@interface OWSSignalServiceProtosGroupContext ()
|
|
|
|
|