http://git-wip-us.apache.org/repos/asf/incubator-wave/blob/7d8609e7/proto_src/org/waveprotocol/box/attachment/AttachmentProto.java ---------------------------------------------------------------------- diff --git a/proto_src/org/waveprotocol/box/attachment/AttachmentProto.java b/proto_src/org/waveprotocol/box/attachment/AttachmentProto.java deleted file mode 100644 index bb7dcab..0000000 --- a/proto_src/org/waveprotocol/box/attachment/AttachmentProto.java +++ /dev/null @@ -1,3322 +0,0 @@ -/** - * Licensed to the Apache Software Foundation (ASF) under one - * or more contributor license agreements. See the NOTICE file - * distributed with this work for additional information - * regarding copyright ownership. The ASF licenses this file - * to you under the Apache License, Version 2.0 (the - * "License"); you may not use this file except in compliance - * with the License. You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, - * software distributed under the License is distributed on an - * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY - * KIND, either express or implied. See the License for the - * specific language governing permissions and limitations - * under the License. - */ - -// Generated by the protocol buffer compiler. DO NOT EDIT! -// source: org/waveprotocol/box/attachment/attachment.proto - -package org.waveprotocol.box.attachment; - -public final class AttachmentProto { - private AttachmentProto() {} - public static void registerAllExtensions( - com.google.protobuf.ExtensionRegistry registry) { - } - public interface AttachmentsResponseOrBuilder - extends com.google.protobuf.MessageOrBuilder { - - // repeated .attachment.AttachmentMetadata attachment = 1; - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> - getAttachmentList(); - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata getAttachment(int index); - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - int getAttachmentCount(); - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - java.util.List<? extends org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder> - getAttachmentOrBuilderList(); - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder getAttachmentOrBuilder( - int index); - } - /** - * Protobuf type {@code attachment.AttachmentsResponse} - */ - public static final class AttachmentsResponse extends - com.google.protobuf.GeneratedMessage - implements AttachmentsResponseOrBuilder { - // Use AttachmentsResponse.newBuilder() to construct. - private AttachmentsResponse(com.google.protobuf.GeneratedMessage.Builder<?> builder) { - super(builder); - this.unknownFields = builder.getUnknownFields(); - } - private AttachmentsResponse(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } - - private static final AttachmentsResponse defaultInstance; - public static AttachmentsResponse getDefaultInstance() { - return defaultInstance; - } - - public AttachmentsResponse getDefaultInstanceForType() { - return defaultInstance; - } - - private final com.google.protobuf.UnknownFieldSet unknownFields; - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private AttachmentsResponse( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - initFields(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - attachment_ = new java.util.ArrayList<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata>(); - mutable_bitField0_ |= 0x00000001; - } - attachment_.add(input.readMessage(org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.PARSER, extensionRegistry)); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this); - } finally { - if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) { - attachment_ = java.util.Collections.unmodifiableList(attachment_); - } - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentsResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.class, org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.Builder.class); - } - - public static com.google.protobuf.Parser<AttachmentsResponse> PARSER = - new com.google.protobuf.AbstractParser<AttachmentsResponse>() { - public AttachmentsResponse parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AttachmentsResponse(input, extensionRegistry); - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<AttachmentsResponse> getParserForType() { - return PARSER; - } - - // repeated .attachment.AttachmentMetadata attachment = 1; - public static final int ATTACHMENT_FIELD_NUMBER = 1; - private java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> attachment_; - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> getAttachmentList() { - return attachment_; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public java.util.List<? extends org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder> - getAttachmentOrBuilderList() { - return attachment_; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public int getAttachmentCount() { - return attachment_.size(); - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata getAttachment(int index) { - return attachment_.get(index); - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder getAttachmentOrBuilder( - int index) { - return attachment_.get(index); - } - - private void initFields() { - attachment_ = java.util.Collections.emptyList(); - } - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized != -1) return isInitialized == 1; - - for (int i = 0; i < getAttachmentCount(); i++) { - if (!getAttachment(i).isInitialized()) { - memoizedIsInitialized = 0; - return false; - } - } - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - getSerializedSize(); - for (int i = 0; i < attachment_.size(); i++) { - output.writeMessage(1, attachment_.get(i)); - } - getUnknownFields().writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - for (int i = 0; i < attachment_.size(); i++) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(1, attachment_.get(i)); - } - size += getUnknownFields().getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - @java.lang.Override - protected java.lang.Object writeReplace() - throws java.io.ObjectStreamException { - return super.writeReplace(); - } - - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public static Builder newBuilder() { return Builder.create(); } - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder(org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse prototype) { - return newBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { return newBuilder(this); } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code attachment.AttachmentsResponse} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> - implements org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponseOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentsResponse_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentsResponse_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.class, org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.Builder.class); - } - - // Construct using org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getAttachmentFieldBuilder(); - } - } - private static Builder create() { - return new Builder(); - } - - public Builder clear() { - super.clear(); - if (attachmentBuilder_ == null) { - attachment_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - } else { - attachmentBuilder_.clear(); - } - return this; - } - - public Builder clone() { - return create().mergeFrom(buildPartial()); - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentsResponse_descriptor; - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse getDefaultInstanceForType() { - return org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.getDefaultInstance(); - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse build() { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse buildPartial() { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse result = new org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse(this); - int from_bitField0_ = bitField0_; - if (attachmentBuilder_ == null) { - if (((bitField0_ & 0x00000001) == 0x00000001)) { - attachment_ = java.util.Collections.unmodifiableList(attachment_); - bitField0_ = (bitField0_ & ~0x00000001); - } - result.attachment_ = attachment_; - } else { - result.attachment_ = attachmentBuilder_.build(); - } - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse) { - return mergeFrom((org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse other) { - if (other == org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse.getDefaultInstance()) return this; - if (attachmentBuilder_ == null) { - if (!other.attachment_.isEmpty()) { - if (attachment_.isEmpty()) { - attachment_ = other.attachment_; - bitField0_ = (bitField0_ & ~0x00000001); - } else { - ensureAttachmentIsMutable(); - attachment_.addAll(other.attachment_); - } - onChanged(); - } - } else { - if (!other.attachment_.isEmpty()) { - if (attachmentBuilder_.isEmpty()) { - attachmentBuilder_.dispose(); - attachmentBuilder_ = null; - attachment_ = other.attachment_; - bitField0_ = (bitField0_ & ~0x00000001); - attachmentBuilder_ = - com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders ? - getAttachmentFieldBuilder() : null; - } else { - attachmentBuilder_.addAllMessages(other.attachment_); - } - } - } - this.mergeUnknownFields(other.getUnknownFields()); - return this; - } - - public final boolean isInitialized() { - for (int i = 0; i < getAttachmentCount(); i++) { - if (!getAttachment(i).isInitialized()) { - - return false; - } - } - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.waveprotocol.box.attachment.AttachmentProto.AttachmentsResponse) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - // repeated .attachment.AttachmentMetadata attachment = 1; - private java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> attachment_ = - java.util.Collections.emptyList(); - private void ensureAttachmentIsMutable() { - if (!((bitField0_ & 0x00000001) == 0x00000001)) { - attachment_ = new java.util.ArrayList<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata>(attachment_); - bitField0_ |= 0x00000001; - } - } - - private com.google.protobuf.RepeatedFieldBuilder< - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder> attachmentBuilder_; - - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> getAttachmentList() { - if (attachmentBuilder_ == null) { - return java.util.Collections.unmodifiableList(attachment_); - } else { - return attachmentBuilder_.getMessageList(); - } - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public int getAttachmentCount() { - if (attachmentBuilder_ == null) { - return attachment_.size(); - } else { - return attachmentBuilder_.getCount(); - } - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata getAttachment(int index) { - if (attachmentBuilder_ == null) { - return attachment_.get(index); - } else { - return attachmentBuilder_.getMessage(index); - } - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder setAttachment( - int index, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata value) { - if (attachmentBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAttachmentIsMutable(); - attachment_.set(index, value); - onChanged(); - } else { - attachmentBuilder_.setMessage(index, value); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder setAttachment( - int index, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder builderForValue) { - if (attachmentBuilder_ == null) { - ensureAttachmentIsMutable(); - attachment_.set(index, builderForValue.build()); - onChanged(); - } else { - attachmentBuilder_.setMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder addAttachment(org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata value) { - if (attachmentBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAttachmentIsMutable(); - attachment_.add(value); - onChanged(); - } else { - attachmentBuilder_.addMessage(value); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder addAttachment( - int index, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata value) { - if (attachmentBuilder_ == null) { - if (value == null) { - throw new NullPointerException(); - } - ensureAttachmentIsMutable(); - attachment_.add(index, value); - onChanged(); - } else { - attachmentBuilder_.addMessage(index, value); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder addAttachment( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder builderForValue) { - if (attachmentBuilder_ == null) { - ensureAttachmentIsMutable(); - attachment_.add(builderForValue.build()); - onChanged(); - } else { - attachmentBuilder_.addMessage(builderForValue.build()); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder addAttachment( - int index, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder builderForValue) { - if (attachmentBuilder_ == null) { - ensureAttachmentIsMutable(); - attachment_.add(index, builderForValue.build()); - onChanged(); - } else { - attachmentBuilder_.addMessage(index, builderForValue.build()); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder addAllAttachment( - java.lang.Iterable<? extends org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata> values) { - if (attachmentBuilder_ == null) { - ensureAttachmentIsMutable(); - super.addAll(values, attachment_); - onChanged(); - } else { - attachmentBuilder_.addAllMessages(values); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder clearAttachment() { - if (attachmentBuilder_ == null) { - attachment_ = java.util.Collections.emptyList(); - bitField0_ = (bitField0_ & ~0x00000001); - onChanged(); - } else { - attachmentBuilder_.clear(); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public Builder removeAttachment(int index) { - if (attachmentBuilder_ == null) { - ensureAttachmentIsMutable(); - attachment_.remove(index); - onChanged(); - } else { - attachmentBuilder_.remove(index); - } - return this; - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder getAttachmentBuilder( - int index) { - return getAttachmentFieldBuilder().getBuilder(index); - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder getAttachmentOrBuilder( - int index) { - if (attachmentBuilder_ == null) { - return attachment_.get(index); } else { - return attachmentBuilder_.getMessageOrBuilder(index); - } - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public java.util.List<? extends org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder> - getAttachmentOrBuilderList() { - if (attachmentBuilder_ != null) { - return attachmentBuilder_.getMessageOrBuilderList(); - } else { - return java.util.Collections.unmodifiableList(attachment_); - } - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder addAttachmentBuilder() { - return getAttachmentFieldBuilder().addBuilder( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.getDefaultInstance()); - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder addAttachmentBuilder( - int index) { - return getAttachmentFieldBuilder().addBuilder( - index, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.getDefaultInstance()); - } - /** - * <code>repeated .attachment.AttachmentMetadata attachment = 1;</code> - */ - public java.util.List<org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder> - getAttachmentBuilderList() { - return getAttachmentFieldBuilder().getBuilderList(); - } - private com.google.protobuf.RepeatedFieldBuilder< - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder> - getAttachmentFieldBuilder() { - if (attachmentBuilder_ == null) { - attachmentBuilder_ = new com.google.protobuf.RepeatedFieldBuilder< - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder>( - attachment_, - ((bitField0_ & 0x00000001) == 0x00000001), - getParentForChildren(), - isClean()); - attachment_ = null; - } - return attachmentBuilder_; - } - - // @@protoc_insertion_point(builder_scope:attachment.AttachmentsResponse) - } - - static { - defaultInstance = new AttachmentsResponse(true); - defaultInstance.initFields(); - } - - // @@protoc_insertion_point(class_scope:attachment.AttachmentsResponse) - } - - public interface AttachmentMetadataOrBuilder - extends com.google.protobuf.MessageOrBuilder { - - // required string attachmentId = 1; - /** - * <code>required string attachmentId = 1;</code> - */ - boolean hasAttachmentId(); - /** - * <code>required string attachmentId = 1;</code> - */ - java.lang.String getAttachmentId(); - /** - * <code>required string attachmentId = 1;</code> - */ - com.google.protobuf.ByteString - getAttachmentIdBytes(); - - // required string waveRef = 2; - /** - * <code>required string waveRef = 2;</code> - */ - boolean hasWaveRef(); - /** - * <code>required string waveRef = 2;</code> - */ - java.lang.String getWaveRef(); - /** - * <code>required string waveRef = 2;</code> - */ - com.google.protobuf.ByteString - getWaveRefBytes(); - - // required string fileName = 3; - /** - * <code>required string fileName = 3;</code> - */ - boolean hasFileName(); - /** - * <code>required string fileName = 3;</code> - */ - java.lang.String getFileName(); - /** - * <code>required string fileName = 3;</code> - */ - com.google.protobuf.ByteString - getFileNameBytes(); - - // required string mimeType = 4; - /** - * <code>required string mimeType = 4;</code> - */ - boolean hasMimeType(); - /** - * <code>required string mimeType = 4;</code> - */ - java.lang.String getMimeType(); - /** - * <code>required string mimeType = 4;</code> - */ - com.google.protobuf.ByteString - getMimeTypeBytes(); - - // required int64 size = 5; - /** - * <code>required int64 size = 5;</code> - */ - boolean hasSize(); - /** - * <code>required int64 size = 5;</code> - */ - long getSize(); - - // required string creator = 6; - /** - * <code>required string creator = 6;</code> - */ - boolean hasCreator(); - /** - * <code>required string creator = 6;</code> - */ - java.lang.String getCreator(); - /** - * <code>required string creator = 6;</code> - */ - com.google.protobuf.ByteString - getCreatorBytes(); - - // required string attachmentUrl = 7; - /** - * <code>required string attachmentUrl = 7;</code> - */ - boolean hasAttachmentUrl(); - /** - * <code>required string attachmentUrl = 7;</code> - */ - java.lang.String getAttachmentUrl(); - /** - * <code>required string attachmentUrl = 7;</code> - */ - com.google.protobuf.ByteString - getAttachmentUrlBytes(); - - // required string thumbnailUrl = 8; - /** - * <code>required string thumbnailUrl = 8;</code> - */ - boolean hasThumbnailUrl(); - /** - * <code>required string thumbnailUrl = 8;</code> - */ - java.lang.String getThumbnailUrl(); - /** - * <code>required string thumbnailUrl = 8;</code> - */ - com.google.protobuf.ByteString - getThumbnailUrlBytes(); - - // optional .attachment.ImageMetadata imageMetadata = 9; - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - boolean hasImageMetadata(); - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata getImageMetadata(); - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadataOrBuilder getImageMetadataOrBuilder(); - - // optional .attachment.ImageMetadata thumbnailMetadata = 10; - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - boolean hasThumbnailMetadata(); - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata getThumbnailMetadata(); - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadataOrBuilder getThumbnailMetadataOrBuilder(); - - // optional bool malware = 11; - /** - * <code>optional bool malware = 11;</code> - */ - boolean hasMalware(); - /** - * <code>optional bool malware = 11;</code> - */ - boolean getMalware(); - } - /** - * Protobuf type {@code attachment.AttachmentMetadata} - */ - public static final class AttachmentMetadata extends - com.google.protobuf.GeneratedMessage - implements AttachmentMetadataOrBuilder { - // Use AttachmentMetadata.newBuilder() to construct. - private AttachmentMetadata(com.google.protobuf.GeneratedMessage.Builder<?> builder) { - super(builder); - this.unknownFields = builder.getUnknownFields(); - } - private AttachmentMetadata(boolean noInit) { this.unknownFields = com.google.protobuf.UnknownFieldSet.getDefaultInstance(); } - - private static final AttachmentMetadata defaultInstance; - public static AttachmentMetadata getDefaultInstance() { - return defaultInstance; - } - - public AttachmentMetadata getDefaultInstanceForType() { - return defaultInstance; - } - - private final com.google.protobuf.UnknownFieldSet unknownFields; - @java.lang.Override - public final com.google.protobuf.UnknownFieldSet - getUnknownFields() { - return this.unknownFields; - } - private AttachmentMetadata( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - initFields(); - int mutable_bitField0_ = 0; - com.google.protobuf.UnknownFieldSet.Builder unknownFields = - com.google.protobuf.UnknownFieldSet.newBuilder(); - try { - boolean done = false; - while (!done) { - int tag = input.readTag(); - switch (tag) { - case 0: - done = true; - break; - default: { - if (!parseUnknownField(input, unknownFields, - extensionRegistry, tag)) { - done = true; - } - break; - } - case 10: { - bitField0_ |= 0x00000001; - attachmentId_ = input.readBytes(); - break; - } - case 18: { - bitField0_ |= 0x00000002; - waveRef_ = input.readBytes(); - break; - } - case 26: { - bitField0_ |= 0x00000004; - fileName_ = input.readBytes(); - break; - } - case 34: { - bitField0_ |= 0x00000008; - mimeType_ = input.readBytes(); - break; - } - case 40: { - bitField0_ |= 0x00000010; - size_ = input.readInt64(); - break; - } - case 50: { - bitField0_ |= 0x00000020; - creator_ = input.readBytes(); - break; - } - case 58: { - bitField0_ |= 0x00000040; - attachmentUrl_ = input.readBytes(); - break; - } - case 66: { - bitField0_ |= 0x00000080; - thumbnailUrl_ = input.readBytes(); - break; - } - case 74: { - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.Builder subBuilder = null; - if (((bitField0_ & 0x00000100) == 0x00000100)) { - subBuilder = imageMetadata_.toBuilder(); - } - imageMetadata_ = input.readMessage(org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(imageMetadata_); - imageMetadata_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000100; - break; - } - case 82: { - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.Builder subBuilder = null; - if (((bitField0_ & 0x00000200) == 0x00000200)) { - subBuilder = thumbnailMetadata_.toBuilder(); - } - thumbnailMetadata_ = input.readMessage(org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.PARSER, extensionRegistry); - if (subBuilder != null) { - subBuilder.mergeFrom(thumbnailMetadata_); - thumbnailMetadata_ = subBuilder.buildPartial(); - } - bitField0_ |= 0x00000200; - break; - } - case 88: { - bitField0_ |= 0x00000400; - malware_ = input.readBool(); - break; - } - } - } - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - throw e.setUnfinishedMessage(this); - } catch (java.io.IOException e) { - throw new com.google.protobuf.InvalidProtocolBufferException( - e.getMessage()).setUnfinishedMessage(this); - } finally { - this.unknownFields = unknownFields.build(); - makeExtensionsImmutable(); - } - } - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.class, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder.class); - } - - public static com.google.protobuf.Parser<AttachmentMetadata> PARSER = - new com.google.protobuf.AbstractParser<AttachmentMetadata>() { - public AttachmentMetadata parsePartialFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return new AttachmentMetadata(input, extensionRegistry); - } - }; - - @java.lang.Override - public com.google.protobuf.Parser<AttachmentMetadata> getParserForType() { - return PARSER; - } - - private int bitField0_; - // required string attachmentId = 1; - public static final int ATTACHMENTID_FIELD_NUMBER = 1; - private java.lang.Object attachmentId_; - /** - * <code>required string attachmentId = 1;</code> - */ - public boolean hasAttachmentId() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>required string attachmentId = 1;</code> - */ - public java.lang.String getAttachmentId() { - java.lang.Object ref = attachmentId_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - attachmentId_ = s; - } - return s; - } - } - /** - * <code>required string attachmentId = 1;</code> - */ - public com.google.protobuf.ByteString - getAttachmentIdBytes() { - java.lang.Object ref = attachmentId_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - attachmentId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required string waveRef = 2; - public static final int WAVEREF_FIELD_NUMBER = 2; - private java.lang.Object waveRef_; - /** - * <code>required string waveRef = 2;</code> - */ - public boolean hasWaveRef() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>required string waveRef = 2;</code> - */ - public java.lang.String getWaveRef() { - java.lang.Object ref = waveRef_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - waveRef_ = s; - } - return s; - } - } - /** - * <code>required string waveRef = 2;</code> - */ - public com.google.protobuf.ByteString - getWaveRefBytes() { - java.lang.Object ref = waveRef_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - waveRef_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required string fileName = 3; - public static final int FILENAME_FIELD_NUMBER = 3; - private java.lang.Object fileName_; - /** - * <code>required string fileName = 3;</code> - */ - public boolean hasFileName() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>required string fileName = 3;</code> - */ - public java.lang.String getFileName() { - java.lang.Object ref = fileName_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - fileName_ = s; - } - return s; - } - } - /** - * <code>required string fileName = 3;</code> - */ - public com.google.protobuf.ByteString - getFileNameBytes() { - java.lang.Object ref = fileName_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - fileName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required string mimeType = 4; - public static final int MIMETYPE_FIELD_NUMBER = 4; - private java.lang.Object mimeType_; - /** - * <code>required string mimeType = 4;</code> - */ - public boolean hasMimeType() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>required string mimeType = 4;</code> - */ - public java.lang.String getMimeType() { - java.lang.Object ref = mimeType_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - mimeType_ = s; - } - return s; - } - } - /** - * <code>required string mimeType = 4;</code> - */ - public com.google.protobuf.ByteString - getMimeTypeBytes() { - java.lang.Object ref = mimeType_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - mimeType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required int64 size = 5; - public static final int SIZE_FIELD_NUMBER = 5; - private long size_; - /** - * <code>required int64 size = 5;</code> - */ - public boolean hasSize() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>required int64 size = 5;</code> - */ - public long getSize() { - return size_; - } - - // required string creator = 6; - public static final int CREATOR_FIELD_NUMBER = 6; - private java.lang.Object creator_; - /** - * <code>required string creator = 6;</code> - */ - public boolean hasCreator() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>required string creator = 6;</code> - */ - public java.lang.String getCreator() { - java.lang.Object ref = creator_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - creator_ = s; - } - return s; - } - } - /** - * <code>required string creator = 6;</code> - */ - public com.google.protobuf.ByteString - getCreatorBytes() { - java.lang.Object ref = creator_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - creator_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required string attachmentUrl = 7; - public static final int ATTACHMENTURL_FIELD_NUMBER = 7; - private java.lang.Object attachmentUrl_; - /** - * <code>required string attachmentUrl = 7;</code> - */ - public boolean hasAttachmentUrl() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public java.lang.String getAttachmentUrl() { - java.lang.Object ref = attachmentUrl_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - attachmentUrl_ = s; - } - return s; - } - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public com.google.protobuf.ByteString - getAttachmentUrlBytes() { - java.lang.Object ref = attachmentUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - attachmentUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // required string thumbnailUrl = 8; - public static final int THUMBNAILURL_FIELD_NUMBER = 8; - private java.lang.Object thumbnailUrl_; - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public boolean hasThumbnailUrl() { - return ((bitField0_ & 0x00000080) == 0x00000080); - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public java.lang.String getThumbnailUrl() { - java.lang.Object ref = thumbnailUrl_; - if (ref instanceof java.lang.String) { - return (java.lang.String) ref; - } else { - com.google.protobuf.ByteString bs = - (com.google.protobuf.ByteString) ref; - java.lang.String s = bs.toStringUtf8(); - if (bs.isValidUtf8()) { - thumbnailUrl_ = s; - } - return s; - } - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public com.google.protobuf.ByteString - getThumbnailUrlBytes() { - java.lang.Object ref = thumbnailUrl_; - if (ref instanceof java.lang.String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - thumbnailUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - - // optional .attachment.ImageMetadata imageMetadata = 9; - public static final int IMAGEMETADATA_FIELD_NUMBER = 9; - private org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata imageMetadata_; - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - public boolean hasImageMetadata() { - return ((bitField0_ & 0x00000100) == 0x00000100); - } - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata getImageMetadata() { - return imageMetadata_; - } - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.ImageMetadataOrBuilder getImageMetadataOrBuilder() { - return imageMetadata_; - } - - // optional .attachment.ImageMetadata thumbnailMetadata = 10; - public static final int THUMBNAILMETADATA_FIELD_NUMBER = 10; - private org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata thumbnailMetadata_; - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - public boolean hasThumbnailMetadata() { - return ((bitField0_ & 0x00000200) == 0x00000200); - } - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata getThumbnailMetadata() { - return thumbnailMetadata_; - } - /** - * <code>optional .attachment.ImageMetadata thumbnailMetadata = 10;</code> - */ - public org.waveprotocol.box.attachment.AttachmentProto.ImageMetadataOrBuilder getThumbnailMetadataOrBuilder() { - return thumbnailMetadata_; - } - - // optional bool malware = 11; - public static final int MALWARE_FIELD_NUMBER = 11; - private boolean malware_; - /** - * <code>optional bool malware = 11;</code> - */ - public boolean hasMalware() { - return ((bitField0_ & 0x00000400) == 0x00000400); - } - /** - * <code>optional bool malware = 11;</code> - */ - public boolean getMalware() { - return malware_; - } - - private void initFields() { - attachmentId_ = ""; - waveRef_ = ""; - fileName_ = ""; - mimeType_ = ""; - size_ = 0L; - creator_ = ""; - attachmentUrl_ = ""; - thumbnailUrl_ = ""; - imageMetadata_ = org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.getDefaultInstance(); - thumbnailMetadata_ = org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.getDefaultInstance(); - malware_ = false; - } - private byte memoizedIsInitialized = -1; - public final boolean isInitialized() { - byte isInitialized = memoizedIsInitialized; - if (isInitialized != -1) return isInitialized == 1; - - if (!hasAttachmentId()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasWaveRef()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasFileName()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasMimeType()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasSize()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasCreator()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasAttachmentUrl()) { - memoizedIsInitialized = 0; - return false; - } - if (!hasThumbnailUrl()) { - memoizedIsInitialized = 0; - return false; - } - if (hasImageMetadata()) { - if (!getImageMetadata().isInitialized()) { - memoizedIsInitialized = 0; - return false; - } - } - if (hasThumbnailMetadata()) { - if (!getThumbnailMetadata().isInitialized()) { - memoizedIsInitialized = 0; - return false; - } - } - memoizedIsInitialized = 1; - return true; - } - - public void writeTo(com.google.protobuf.CodedOutputStream output) - throws java.io.IOException { - getSerializedSize(); - if (((bitField0_ & 0x00000001) == 0x00000001)) { - output.writeBytes(1, getAttachmentIdBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - output.writeBytes(2, getWaveRefBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - output.writeBytes(3, getFileNameBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - output.writeBytes(4, getMimeTypeBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - output.writeInt64(5, size_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - output.writeBytes(6, getCreatorBytes()); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - output.writeBytes(7, getAttachmentUrlBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - output.writeBytes(8, getThumbnailUrlBytes()); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - output.writeMessage(9, imageMetadata_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - output.writeMessage(10, thumbnailMetadata_); - } - if (((bitField0_ & 0x00000400) == 0x00000400)) { - output.writeBool(11, malware_); - } - getUnknownFields().writeTo(output); - } - - private int memoizedSerializedSize = -1; - public int getSerializedSize() { - int size = memoizedSerializedSize; - if (size != -1) return size; - - size = 0; - if (((bitField0_ & 0x00000001) == 0x00000001)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(1, getAttachmentIdBytes()); - } - if (((bitField0_ & 0x00000002) == 0x00000002)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(2, getWaveRefBytes()); - } - if (((bitField0_ & 0x00000004) == 0x00000004)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(3, getFileNameBytes()); - } - if (((bitField0_ & 0x00000008) == 0x00000008)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(4, getMimeTypeBytes()); - } - if (((bitField0_ & 0x00000010) == 0x00000010)) { - size += com.google.protobuf.CodedOutputStream - .computeInt64Size(5, size_); - } - if (((bitField0_ & 0x00000020) == 0x00000020)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(6, getCreatorBytes()); - } - if (((bitField0_ & 0x00000040) == 0x00000040)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(7, getAttachmentUrlBytes()); - } - if (((bitField0_ & 0x00000080) == 0x00000080)) { - size += com.google.protobuf.CodedOutputStream - .computeBytesSize(8, getThumbnailUrlBytes()); - } - if (((bitField0_ & 0x00000100) == 0x00000100)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(9, imageMetadata_); - } - if (((bitField0_ & 0x00000200) == 0x00000200)) { - size += com.google.protobuf.CodedOutputStream - .computeMessageSize(10, thumbnailMetadata_); - } - if (((bitField0_ & 0x00000400) == 0x00000400)) { - size += com.google.protobuf.CodedOutputStream - .computeBoolSize(11, malware_); - } - size += getUnknownFields().getSerializedSize(); - memoizedSerializedSize = size; - return size; - } - - private static final long serialVersionUID = 0L; - @java.lang.Override - protected java.lang.Object writeReplace() - throws java.io.ObjectStreamException { - return super.writeReplace(); - } - - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - com.google.protobuf.ByteString data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - com.google.protobuf.ByteString data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom(byte[] data) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - byte[] data, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws com.google.protobuf.InvalidProtocolBufferException { - return PARSER.parseFrom(data, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseDelimitedFrom(java.io.InputStream input) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseDelimitedFrom( - java.io.InputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseDelimitedFrom(input, extensionRegistry); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - com.google.protobuf.CodedInputStream input) - throws java.io.IOException { - return PARSER.parseFrom(input); - } - public static org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parseFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - return PARSER.parseFrom(input, extensionRegistry); - } - - public static Builder newBuilder() { return Builder.create(); } - public Builder newBuilderForType() { return newBuilder(); } - public static Builder newBuilder(org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata prototype) { - return newBuilder().mergeFrom(prototype); - } - public Builder toBuilder() { return newBuilder(this); } - - @java.lang.Override - protected Builder newBuilderForType( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - Builder builder = new Builder(parent); - return builder; - } - /** - * Protobuf type {@code attachment.AttachmentMetadata} - */ - public static final class Builder extends - com.google.protobuf.GeneratedMessage.Builder<Builder> - implements org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadataOrBuilder { - public static final com.google.protobuf.Descriptors.Descriptor - getDescriptor() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentMetadata_descriptor; - } - - protected com.google.protobuf.GeneratedMessage.FieldAccessorTable - internalGetFieldAccessorTable() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentMetadata_fieldAccessorTable - .ensureFieldAccessorsInitialized( - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.class, org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.Builder.class); - } - - // Construct using org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.newBuilder() - private Builder() { - maybeForceBuilderInitialization(); - } - - private Builder( - com.google.protobuf.GeneratedMessage.BuilderParent parent) { - super(parent); - maybeForceBuilderInitialization(); - } - private void maybeForceBuilderInitialization() { - if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) { - getImageMetadataFieldBuilder(); - getThumbnailMetadataFieldBuilder(); - } - } - private static Builder create() { - return new Builder(); - } - - public Builder clear() { - super.clear(); - attachmentId_ = ""; - bitField0_ = (bitField0_ & ~0x00000001); - waveRef_ = ""; - bitField0_ = (bitField0_ & ~0x00000002); - fileName_ = ""; - bitField0_ = (bitField0_ & ~0x00000004); - mimeType_ = ""; - bitField0_ = (bitField0_ & ~0x00000008); - size_ = 0L; - bitField0_ = (bitField0_ & ~0x00000010); - creator_ = ""; - bitField0_ = (bitField0_ & ~0x00000020); - attachmentUrl_ = ""; - bitField0_ = (bitField0_ & ~0x00000040); - thumbnailUrl_ = ""; - bitField0_ = (bitField0_ & ~0x00000080); - if (imageMetadataBuilder_ == null) { - imageMetadata_ = org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.getDefaultInstance(); - } else { - imageMetadataBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000100); - if (thumbnailMetadataBuilder_ == null) { - thumbnailMetadata_ = org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.getDefaultInstance(); - } else { - thumbnailMetadataBuilder_.clear(); - } - bitField0_ = (bitField0_ & ~0x00000200); - malware_ = false; - bitField0_ = (bitField0_ & ~0x00000400); - return this; - } - - public Builder clone() { - return create().mergeFrom(buildPartial()); - } - - public com.google.protobuf.Descriptors.Descriptor - getDescriptorForType() { - return org.waveprotocol.box.attachment.AttachmentProto.internal_static_attachment_AttachmentMetadata_descriptor; - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata getDefaultInstanceForType() { - return org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.getDefaultInstance(); - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata build() { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata result = buildPartial(); - if (!result.isInitialized()) { - throw newUninitializedMessageException(result); - } - return result; - } - - public org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata buildPartial() { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata result = new org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata(this); - int from_bitField0_ = bitField0_; - int to_bitField0_ = 0; - if (((from_bitField0_ & 0x00000001) == 0x00000001)) { - to_bitField0_ |= 0x00000001; - } - result.attachmentId_ = attachmentId_; - if (((from_bitField0_ & 0x00000002) == 0x00000002)) { - to_bitField0_ |= 0x00000002; - } - result.waveRef_ = waveRef_; - if (((from_bitField0_ & 0x00000004) == 0x00000004)) { - to_bitField0_ |= 0x00000004; - } - result.fileName_ = fileName_; - if (((from_bitField0_ & 0x00000008) == 0x00000008)) { - to_bitField0_ |= 0x00000008; - } - result.mimeType_ = mimeType_; - if (((from_bitField0_ & 0x00000010) == 0x00000010)) { - to_bitField0_ |= 0x00000010; - } - result.size_ = size_; - if (((from_bitField0_ & 0x00000020) == 0x00000020)) { - to_bitField0_ |= 0x00000020; - } - result.creator_ = creator_; - if (((from_bitField0_ & 0x00000040) == 0x00000040)) { - to_bitField0_ |= 0x00000040; - } - result.attachmentUrl_ = attachmentUrl_; - if (((from_bitField0_ & 0x00000080) == 0x00000080)) { - to_bitField0_ |= 0x00000080; - } - result.thumbnailUrl_ = thumbnailUrl_; - if (((from_bitField0_ & 0x00000100) == 0x00000100)) { - to_bitField0_ |= 0x00000100; - } - if (imageMetadataBuilder_ == null) { - result.imageMetadata_ = imageMetadata_; - } else { - result.imageMetadata_ = imageMetadataBuilder_.build(); - } - if (((from_bitField0_ & 0x00000200) == 0x00000200)) { - to_bitField0_ |= 0x00000200; - } - if (thumbnailMetadataBuilder_ == null) { - result.thumbnailMetadata_ = thumbnailMetadata_; - } else { - result.thumbnailMetadata_ = thumbnailMetadataBuilder_.build(); - } - if (((from_bitField0_ & 0x00000400) == 0x00000400)) { - to_bitField0_ |= 0x00000400; - } - result.malware_ = malware_; - result.bitField0_ = to_bitField0_; - onBuilt(); - return result; - } - - public Builder mergeFrom(com.google.protobuf.Message other) { - if (other instanceof org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata) { - return mergeFrom((org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata)other); - } else { - super.mergeFrom(other); - return this; - } - } - - public Builder mergeFrom(org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata other) { - if (other == org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata.getDefaultInstance()) return this; - if (other.hasAttachmentId()) { - bitField0_ |= 0x00000001; - attachmentId_ = other.attachmentId_; - onChanged(); - } - if (other.hasWaveRef()) { - bitField0_ |= 0x00000002; - waveRef_ = other.waveRef_; - onChanged(); - } - if (other.hasFileName()) { - bitField0_ |= 0x00000004; - fileName_ = other.fileName_; - onChanged(); - } - if (other.hasMimeType()) { - bitField0_ |= 0x00000008; - mimeType_ = other.mimeType_; - onChanged(); - } - if (other.hasSize()) { - setSize(other.getSize()); - } - if (other.hasCreator()) { - bitField0_ |= 0x00000020; - creator_ = other.creator_; - onChanged(); - } - if (other.hasAttachmentUrl()) { - bitField0_ |= 0x00000040; - attachmentUrl_ = other.attachmentUrl_; - onChanged(); - } - if (other.hasThumbnailUrl()) { - bitField0_ |= 0x00000080; - thumbnailUrl_ = other.thumbnailUrl_; - onChanged(); - } - if (other.hasImageMetadata()) { - mergeImageMetadata(other.getImageMetadata()); - } - if (other.hasThumbnailMetadata()) { - mergeThumbnailMetadata(other.getThumbnailMetadata()); - } - if (other.hasMalware()) { - setMalware(other.getMalware()); - } - this.mergeUnknownFields(other.getUnknownFields()); - return this; - } - - public final boolean isInitialized() { - if (!hasAttachmentId()) { - - return false; - } - if (!hasWaveRef()) { - - return false; - } - if (!hasFileName()) { - - return false; - } - if (!hasMimeType()) { - - return false; - } - if (!hasSize()) { - - return false; - } - if (!hasCreator()) { - - return false; - } - if (!hasAttachmentUrl()) { - - return false; - } - if (!hasThumbnailUrl()) { - - return false; - } - if (hasImageMetadata()) { - if (!getImageMetadata().isInitialized()) { - - return false; - } - } - if (hasThumbnailMetadata()) { - if (!getThumbnailMetadata().isInitialized()) { - - return false; - } - } - return true; - } - - public Builder mergeFrom( - com.google.protobuf.CodedInputStream input, - com.google.protobuf.ExtensionRegistryLite extensionRegistry) - throws java.io.IOException { - org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata parsedMessage = null; - try { - parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry); - } catch (com.google.protobuf.InvalidProtocolBufferException e) { - parsedMessage = (org.waveprotocol.box.attachment.AttachmentProto.AttachmentMetadata) e.getUnfinishedMessage(); - throw e; - } finally { - if (parsedMessage != null) { - mergeFrom(parsedMessage); - } - } - return this; - } - private int bitField0_; - - // required string attachmentId = 1; - private java.lang.Object attachmentId_ = ""; - /** - * <code>required string attachmentId = 1;</code> - */ - public boolean hasAttachmentId() { - return ((bitField0_ & 0x00000001) == 0x00000001); - } - /** - * <code>required string attachmentId = 1;</code> - */ - public java.lang.String getAttachmentId() { - java.lang.Object ref = attachmentId_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - attachmentId_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string attachmentId = 1;</code> - */ - public com.google.protobuf.ByteString - getAttachmentIdBytes() { - java.lang.Object ref = attachmentId_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - attachmentId_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string attachmentId = 1;</code> - */ - public Builder setAttachmentId( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - attachmentId_ = value; - onChanged(); - return this; - } - /** - * <code>required string attachmentId = 1;</code> - */ - public Builder clearAttachmentId() { - bitField0_ = (bitField0_ & ~0x00000001); - attachmentId_ = getDefaultInstance().getAttachmentId(); - onChanged(); - return this; - } - /** - * <code>required string attachmentId = 1;</code> - */ - public Builder setAttachmentIdBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000001; - attachmentId_ = value; - onChanged(); - return this; - } - - // required string waveRef = 2; - private java.lang.Object waveRef_ = ""; - /** - * <code>required string waveRef = 2;</code> - */ - public boolean hasWaveRef() { - return ((bitField0_ & 0x00000002) == 0x00000002); - } - /** - * <code>required string waveRef = 2;</code> - */ - public java.lang.String getWaveRef() { - java.lang.Object ref = waveRef_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - waveRef_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string waveRef = 2;</code> - */ - public com.google.protobuf.ByteString - getWaveRefBytes() { - java.lang.Object ref = waveRef_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - waveRef_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string waveRef = 2;</code> - */ - public Builder setWaveRef( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - waveRef_ = value; - onChanged(); - return this; - } - /** - * <code>required string waveRef = 2;</code> - */ - public Builder clearWaveRef() { - bitField0_ = (bitField0_ & ~0x00000002); - waveRef_ = getDefaultInstance().getWaveRef(); - onChanged(); - return this; - } - /** - * <code>required string waveRef = 2;</code> - */ - public Builder setWaveRefBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000002; - waveRef_ = value; - onChanged(); - return this; - } - - // required string fileName = 3; - private java.lang.Object fileName_ = ""; - /** - * <code>required string fileName = 3;</code> - */ - public boolean hasFileName() { - return ((bitField0_ & 0x00000004) == 0x00000004); - } - /** - * <code>required string fileName = 3;</code> - */ - public java.lang.String getFileName() { - java.lang.Object ref = fileName_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - fileName_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string fileName = 3;</code> - */ - public com.google.protobuf.ByteString - getFileNameBytes() { - java.lang.Object ref = fileName_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - fileName_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string fileName = 3;</code> - */ - public Builder setFileName( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - fileName_ = value; - onChanged(); - return this; - } - /** - * <code>required string fileName = 3;</code> - */ - public Builder clearFileName() { - bitField0_ = (bitField0_ & ~0x00000004); - fileName_ = getDefaultInstance().getFileName(); - onChanged(); - return this; - } - /** - * <code>required string fileName = 3;</code> - */ - public Builder setFileNameBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000004; - fileName_ = value; - onChanged(); - return this; - } - - // required string mimeType = 4; - private java.lang.Object mimeType_ = ""; - /** - * <code>required string mimeType = 4;</code> - */ - public boolean hasMimeType() { - return ((bitField0_ & 0x00000008) == 0x00000008); - } - /** - * <code>required string mimeType = 4;</code> - */ - public java.lang.String getMimeType() { - java.lang.Object ref = mimeType_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - mimeType_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string mimeType = 4;</code> - */ - public com.google.protobuf.ByteString - getMimeTypeBytes() { - java.lang.Object ref = mimeType_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - mimeType_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string mimeType = 4;</code> - */ - public Builder setMimeType( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - mimeType_ = value; - onChanged(); - return this; - } - /** - * <code>required string mimeType = 4;</code> - */ - public Builder clearMimeType() { - bitField0_ = (bitField0_ & ~0x00000008); - mimeType_ = getDefaultInstance().getMimeType(); - onChanged(); - return this; - } - /** - * <code>required string mimeType = 4;</code> - */ - public Builder setMimeTypeBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000008; - mimeType_ = value; - onChanged(); - return this; - } - - // required int64 size = 5; - private long size_ ; - /** - * <code>required int64 size = 5;</code> - */ - public boolean hasSize() { - return ((bitField0_ & 0x00000010) == 0x00000010); - } - /** - * <code>required int64 size = 5;</code> - */ - public long getSize() { - return size_; - } - /** - * <code>required int64 size = 5;</code> - */ - public Builder setSize(long value) { - bitField0_ |= 0x00000010; - size_ = value; - onChanged(); - return this; - } - /** - * <code>required int64 size = 5;</code> - */ - public Builder clearSize() { - bitField0_ = (bitField0_ & ~0x00000010); - size_ = 0L; - onChanged(); - return this; - } - - // required string creator = 6; - private java.lang.Object creator_ = ""; - /** - * <code>required string creator = 6;</code> - */ - public boolean hasCreator() { - return ((bitField0_ & 0x00000020) == 0x00000020); - } - /** - * <code>required string creator = 6;</code> - */ - public java.lang.String getCreator() { - java.lang.Object ref = creator_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - creator_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string creator = 6;</code> - */ - public com.google.protobuf.ByteString - getCreatorBytes() { - java.lang.Object ref = creator_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - creator_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string creator = 6;</code> - */ - public Builder setCreator( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - creator_ = value; - onChanged(); - return this; - } - /** - * <code>required string creator = 6;</code> - */ - public Builder clearCreator() { - bitField0_ = (bitField0_ & ~0x00000020); - creator_ = getDefaultInstance().getCreator(); - onChanged(); - return this; - } - /** - * <code>required string creator = 6;</code> - */ - public Builder setCreatorBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000020; - creator_ = value; - onChanged(); - return this; - } - - // required string attachmentUrl = 7; - private java.lang.Object attachmentUrl_ = ""; - /** - * <code>required string attachmentUrl = 7;</code> - */ - public boolean hasAttachmentUrl() { - return ((bitField0_ & 0x00000040) == 0x00000040); - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public java.lang.String getAttachmentUrl() { - java.lang.Object ref = attachmentUrl_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - attachmentUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public com.google.protobuf.ByteString - getAttachmentUrlBytes() { - java.lang.Object ref = attachmentUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - attachmentUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public Builder setAttachmentUrl( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - attachmentUrl_ = value; - onChanged(); - return this; - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public Builder clearAttachmentUrl() { - bitField0_ = (bitField0_ & ~0x00000040); - attachmentUrl_ = getDefaultInstance().getAttachmentUrl(); - onChanged(); - return this; - } - /** - * <code>required string attachmentUrl = 7;</code> - */ - public Builder setAttachmentUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000040; - attachmentUrl_ = value; - onChanged(); - return this; - } - - // required string thumbnailUrl = 8; - private java.lang.Object thumbnailUrl_ = ""; - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public boolean hasThumbnailUrl() { - return ((bitField0_ & 0x00000080) == 0x00000080); - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public java.lang.String getThumbnailUrl() { - java.lang.Object ref = thumbnailUrl_; - if (!(ref instanceof java.lang.String)) { - java.lang.String s = ((com.google.protobuf.ByteString) ref) - .toStringUtf8(); - thumbnailUrl_ = s; - return s; - } else { - return (java.lang.String) ref; - } - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public com.google.protobuf.ByteString - getThumbnailUrlBytes() { - java.lang.Object ref = thumbnailUrl_; - if (ref instanceof String) { - com.google.protobuf.ByteString b = - com.google.protobuf.ByteString.copyFromUtf8( - (java.lang.String) ref); - thumbnailUrl_ = b; - return b; - } else { - return (com.google.protobuf.ByteString) ref; - } - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public Builder setThumbnailUrl( - java.lang.String value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000080; - thumbnailUrl_ = value; - onChanged(); - return this; - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public Builder clearThumbnailUrl() { - bitField0_ = (bitField0_ & ~0x00000080); - thumbnailUrl_ = getDefaultInstance().getThumbnailUrl(); - onChanged(); - return this; - } - /** - * <code>required string thumbnailUrl = 8;</code> - */ - public Builder setThumbnailUrlBytes( - com.google.protobuf.ByteString value) { - if (value == null) { - throw new NullPointerException(); - } - bitField0_ |= 0x00000080; - thumbnailUrl_ = value; - onChanged(); - return this; - } - - // optional .attachment.ImageMetadata imageMetadata = 9; - private org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata imageMetadata_ = org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.getDefaultInstance(); - private com.google.protobuf.SingleFieldBuilder< - org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata, org.waveprotocol.box.attachment.AttachmentProto.ImageMetadata.Builder, org.waveprotocol.box.attachment.AttachmentProto.ImageMetadataOrBuilder> imageMetadataBuilder_; - /** - * <code>optional .attachment.ImageMetadata imageMetadata = 9;</code> - */ - public boolean has
<TRUNCATED>
