
io.opencannabis.schema.content.BrandContent Maven / Gradle / Ivy
/*
* Copyright 2018, Momentum Ideas, Co. All rights reserved.
*
* Source and object computer code contained herein is the private intellectual
* property of Momentum Ideas Co., a Delaware Corporation. Use of this
* code in source form requires permission in writing before use or the
* assembly, distribution, or publishing of derivative works, for commercial
* purposes or any other purpose, from a duly authorized officer of Momentum
* Ideas Co.
*
* 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: content/Brand.proto
package io.opencannabis.schema.content;
public final class BrandContent {
private BrandContent() {}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistryLite registry) {
}
public static void registerAllExtensions(
com.google.protobuf.ExtensionRegistry registry) {
registerAllExtensions(
(com.google.protobuf.ExtensionRegistryLite) registry);
}
public interface RasterGraphicOrBuilder extends
// @@protoc_insertion_point(interface_extends:opencannabis.content.RasterGraphic)
com.google.protobuf.MessageOrBuilder {
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
boolean hasStandard();
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReference getStandard();
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getStandardOrBuilder();
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
boolean hasRetina();
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReference getRetina();
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getRetinaOrBuilder();
}
/**
*
* Raster graphic URL reference.
*
*
* Protobuf type {@code opencannabis.content.RasterGraphic}
*/
public static final class RasterGraphic extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:opencannabis.content.RasterGraphic)
RasterGraphicOrBuilder {
private static final long serialVersionUID = 0L;
// Use RasterGraphic.newBuilder() to construct.
private RasterGraphic(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private RasterGraphic() {
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private RasterGraphic(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
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;
case 10: {
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder subBuilder = null;
if (standard_ != null) {
subBuilder = standard_.toBuilder();
}
standard_ = input.readMessage(io.opencannabis.schema.media.MediaItemKey.MediaReference.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(standard_);
standard_ = subBuilder.buildPartial();
}
break;
}
case 18: {
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder subBuilder = null;
if (retina_ != null) {
subBuilder = retina_.toBuilder();
}
retina_ = input.readMessage(io.opencannabis.schema.media.MediaItemKey.MediaReference.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(retina_);
retina_ = subBuilder.buildPartial();
}
break;
}
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_RasterGraphic_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_RasterGraphic_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.RasterGraphic.class, io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder.class);
}
public static final int STANDARD_FIELD_NUMBER = 1;
private io.opencannabis.schema.media.MediaItemKey.MediaReference standard_;
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public boolean hasStandard() {
return standard_ != null;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getStandard() {
return standard_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : standard_;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getStandardOrBuilder() {
return getStandard();
}
public static final int RETINA_FIELD_NUMBER = 2;
private io.opencannabis.schema.media.MediaItemKey.MediaReference retina_;
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public boolean hasRetina() {
return retina_ != null;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getRetina() {
return retina_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : retina_;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getRetinaOrBuilder() {
return getRetina();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (standard_ != null) {
output.writeMessage(1, getStandard());
}
if (retina_ != null) {
output.writeMessage(2, getRetina());
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (standard_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getStandard());
}
if (retina_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getRetina());
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.opencannabis.schema.content.BrandContent.RasterGraphic)) {
return super.equals(obj);
}
io.opencannabis.schema.content.BrandContent.RasterGraphic other = (io.opencannabis.schema.content.BrandContent.RasterGraphic) obj;
boolean result = true;
result = result && (hasStandard() == other.hasStandard());
if (hasStandard()) {
result = result && getStandard()
.equals(other.getStandard());
}
result = result && (hasRetina() == other.hasRetina());
if (hasRetina()) {
result = result && getRetina()
.equals(other.getRetina());
}
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasStandard()) {
hash = (37 * hash) + STANDARD_FIELD_NUMBER;
hash = (53 * hash) + getStandard().hashCode();
}
if (hasRetina()) {
hash = (37 * hash) + RETINA_FIELD_NUMBER;
hash = (53 * hash) + getRetina().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.opencannabis.schema.content.BrandContent.RasterGraphic prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Raster graphic URL reference.
*
*
* Protobuf type {@code opencannabis.content.RasterGraphic}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:opencannabis.content.RasterGraphic)
io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_RasterGraphic_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_RasterGraphic_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.RasterGraphic.class, io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder.class);
}
// Construct using io.opencannabis.schema.content.BrandContent.RasterGraphic.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (standardBuilder_ == null) {
standard_ = null;
} else {
standard_ = null;
standardBuilder_ = null;
}
if (retinaBuilder_ == null) {
retina_ = null;
} else {
retina_ = null;
retinaBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_RasterGraphic_descriptor;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.RasterGraphic getDefaultInstanceForType() {
return io.opencannabis.schema.content.BrandContent.RasterGraphic.getDefaultInstance();
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.RasterGraphic build() {
io.opencannabis.schema.content.BrandContent.RasterGraphic result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.RasterGraphic buildPartial() {
io.opencannabis.schema.content.BrandContent.RasterGraphic result = new io.opencannabis.schema.content.BrandContent.RasterGraphic(this);
if (standardBuilder_ == null) {
result.standard_ = standard_;
} else {
result.standard_ = standardBuilder_.build();
}
if (retinaBuilder_ == null) {
result.retina_ = retina_;
} else {
result.retina_ = retinaBuilder_.build();
}
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return (Builder) super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.opencannabis.schema.content.BrandContent.RasterGraphic) {
return mergeFrom((io.opencannabis.schema.content.BrandContent.RasterGraphic)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.opencannabis.schema.content.BrandContent.RasterGraphic other) {
if (other == io.opencannabis.schema.content.BrandContent.RasterGraphic.getDefaultInstance()) return this;
if (other.hasStandard()) {
mergeStandard(other.getStandard());
}
if (other.hasRetina()) {
mergeRetina(other.getRetina());
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
io.opencannabis.schema.content.BrandContent.RasterGraphic parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.opencannabis.schema.content.BrandContent.RasterGraphic) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private io.opencannabis.schema.media.MediaItemKey.MediaReference standard_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder> standardBuilder_;
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public boolean hasStandard() {
return standardBuilder_ != null || standard_ != null;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getStandard() {
if (standardBuilder_ == null) {
return standard_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : standard_;
} else {
return standardBuilder_.getMessage();
}
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public Builder setStandard(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (standardBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
standard_ = value;
onChanged();
} else {
standardBuilder_.setMessage(value);
}
return this;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public Builder setStandard(
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder builderForValue) {
if (standardBuilder_ == null) {
standard_ = builderForValue.build();
onChanged();
} else {
standardBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public Builder mergeStandard(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (standardBuilder_ == null) {
if (standard_ != null) {
standard_ =
io.opencannabis.schema.media.MediaItemKey.MediaReference.newBuilder(standard_).mergeFrom(value).buildPartial();
} else {
standard_ = value;
}
onChanged();
} else {
standardBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public Builder clearStandard() {
if (standardBuilder_ == null) {
standard_ = null;
onChanged();
} else {
standard_ = null;
standardBuilder_ = null;
}
return this;
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder getStandardBuilder() {
onChanged();
return getStandardFieldBuilder().getBuilder();
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getStandardOrBuilder() {
if (standardBuilder_ != null) {
return standardBuilder_.getMessageOrBuilder();
} else {
return standard_ == null ?
io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : standard_;
}
}
/**
*
* Standard-resolution graphic link.
*
*
* .opencannabis.media.MediaReference standard = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>
getStandardFieldBuilder() {
if (standardBuilder_ == null) {
standardBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>(
getStandard(),
getParentForChildren(),
isClean());
standard_ = null;
}
return standardBuilder_;
}
private io.opencannabis.schema.media.MediaItemKey.MediaReference retina_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder> retinaBuilder_;
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public boolean hasRetina() {
return retinaBuilder_ != null || retina_ != null;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getRetina() {
if (retinaBuilder_ == null) {
return retina_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : retina_;
} else {
return retinaBuilder_.getMessage();
}
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public Builder setRetina(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (retinaBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
retina_ = value;
onChanged();
} else {
retinaBuilder_.setMessage(value);
}
return this;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public Builder setRetina(
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder builderForValue) {
if (retinaBuilder_ == null) {
retina_ = builderForValue.build();
onChanged();
} else {
retinaBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public Builder mergeRetina(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (retinaBuilder_ == null) {
if (retina_ != null) {
retina_ =
io.opencannabis.schema.media.MediaItemKey.MediaReference.newBuilder(retina_).mergeFrom(value).buildPartial();
} else {
retina_ = value;
}
onChanged();
} else {
retinaBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public Builder clearRetina() {
if (retinaBuilder_ == null) {
retina_ = null;
onChanged();
} else {
retina_ = null;
retinaBuilder_ = null;
}
return this;
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder getRetinaBuilder() {
onChanged();
return getRetinaFieldBuilder().getBuilder();
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getRetinaOrBuilder() {
if (retinaBuilder_ != null) {
return retinaBuilder_.getMessageOrBuilder();
} else {
return retina_ == null ?
io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : retina_;
}
}
/**
*
* High-resolution graphic link.
*
*
* .opencannabis.media.MediaReference retina = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>
getRetinaFieldBuilder() {
if (retinaBuilder_ == null) {
retinaBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>(
getRetina(),
getParentForChildren(),
isClean());
retina_ = null;
}
return retinaBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:opencannabis.content.RasterGraphic)
}
// @@protoc_insertion_point(class_scope:opencannabis.content.RasterGraphic)
private static final io.opencannabis.schema.content.BrandContent.RasterGraphic DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.opencannabis.schema.content.BrandContent.RasterGraphic();
}
public static io.opencannabis.schema.content.BrandContent.RasterGraphic getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public RasterGraphic parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new RasterGraphic(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.RasterGraphic getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface BrandAssetOrBuilder extends
// @@protoc_insertion_point(interface_extends:opencannabis.content.BrandAsset)
com.google.protobuf.MessageOrBuilder {
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
boolean hasRaster();
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
io.opencannabis.schema.content.BrandContent.RasterGraphic getRaster();
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder getRasterOrBuilder();
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
boolean hasVector();
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReference getVector();
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getVectorOrBuilder();
}
/**
*
* Individual brand asset.
*
*
* Protobuf type {@code opencannabis.content.BrandAsset}
*/
public static final class BrandAsset extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:opencannabis.content.BrandAsset)
BrandAssetOrBuilder {
private static final long serialVersionUID = 0L;
// Use BrandAsset.newBuilder() to construct.
private BrandAsset(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private BrandAsset() {
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private BrandAsset(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
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;
case 10: {
io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder subBuilder = null;
if (raster_ != null) {
subBuilder = raster_.toBuilder();
}
raster_ = input.readMessage(io.opencannabis.schema.content.BrandContent.RasterGraphic.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(raster_);
raster_ = subBuilder.buildPartial();
}
break;
}
case 18: {
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder subBuilder = null;
if (vector_ != null) {
subBuilder = vector_.toBuilder();
}
vector_ = input.readMessage(io.opencannabis.schema.media.MediaItemKey.MediaReference.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(vector_);
vector_ = subBuilder.buildPartial();
}
break;
}
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_BrandAsset_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_BrandAsset_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.BrandAsset.class, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder.class);
}
public static final int RASTER_FIELD_NUMBER = 1;
private io.opencannabis.schema.content.BrandContent.RasterGraphic raster_;
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public boolean hasRaster() {
return raster_ != null;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public io.opencannabis.schema.content.BrandContent.RasterGraphic getRaster() {
return raster_ == null ? io.opencannabis.schema.content.BrandContent.RasterGraphic.getDefaultInstance() : raster_;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder getRasterOrBuilder() {
return getRaster();
}
public static final int VECTOR_FIELD_NUMBER = 2;
private io.opencannabis.schema.media.MediaItemKey.MediaReference vector_;
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public boolean hasVector() {
return vector_ != null;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getVector() {
return vector_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : vector_;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getVectorOrBuilder() {
return getVector();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (raster_ != null) {
output.writeMessage(1, getRaster());
}
if (vector_ != null) {
output.writeMessage(2, getVector());
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (raster_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getRaster());
}
if (vector_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getVector());
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.opencannabis.schema.content.BrandContent.BrandAsset)) {
return super.equals(obj);
}
io.opencannabis.schema.content.BrandContent.BrandAsset other = (io.opencannabis.schema.content.BrandContent.BrandAsset) obj;
boolean result = true;
result = result && (hasRaster() == other.hasRaster());
if (hasRaster()) {
result = result && getRaster()
.equals(other.getRaster());
}
result = result && (hasVector() == other.hasVector());
if (hasVector()) {
result = result && getVector()
.equals(other.getVector());
}
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasRaster()) {
hash = (37 * hash) + RASTER_FIELD_NUMBER;
hash = (53 * hash) + getRaster().hashCode();
}
if (hasVector()) {
hash = (37 * hash) + VECTOR_FIELD_NUMBER;
hash = (53 * hash) + getVector().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.opencannabis.schema.content.BrandContent.BrandAsset prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Individual brand asset.
*
*
* Protobuf type {@code opencannabis.content.BrandAsset}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:opencannabis.content.BrandAsset)
io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_BrandAsset_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_BrandAsset_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.BrandAsset.class, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder.class);
}
// Construct using io.opencannabis.schema.content.BrandContent.BrandAsset.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (rasterBuilder_ == null) {
raster_ = null;
} else {
raster_ = null;
rasterBuilder_ = null;
}
if (vectorBuilder_ == null) {
vector_ = null;
} else {
vector_ = null;
vectorBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_BrandAsset_descriptor;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.BrandAsset getDefaultInstanceForType() {
return io.opencannabis.schema.content.BrandContent.BrandAsset.getDefaultInstance();
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.BrandAsset build() {
io.opencannabis.schema.content.BrandContent.BrandAsset result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.BrandAsset buildPartial() {
io.opencannabis.schema.content.BrandContent.BrandAsset result = new io.opencannabis.schema.content.BrandContent.BrandAsset(this);
if (rasterBuilder_ == null) {
result.raster_ = raster_;
} else {
result.raster_ = rasterBuilder_.build();
}
if (vectorBuilder_ == null) {
result.vector_ = vector_;
} else {
result.vector_ = vectorBuilder_.build();
}
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return (Builder) super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.opencannabis.schema.content.BrandContent.BrandAsset) {
return mergeFrom((io.opencannabis.schema.content.BrandContent.BrandAsset)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.opencannabis.schema.content.BrandContent.BrandAsset other) {
if (other == io.opencannabis.schema.content.BrandContent.BrandAsset.getDefaultInstance()) return this;
if (other.hasRaster()) {
mergeRaster(other.getRaster());
}
if (other.hasVector()) {
mergeVector(other.getVector());
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
io.opencannabis.schema.content.BrandContent.BrandAsset parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.opencannabis.schema.content.BrandContent.BrandAsset) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private io.opencannabis.schema.content.BrandContent.RasterGraphic raster_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.RasterGraphic, io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder, io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder> rasterBuilder_;
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public boolean hasRaster() {
return rasterBuilder_ != null || raster_ != null;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public io.opencannabis.schema.content.BrandContent.RasterGraphic getRaster() {
if (rasterBuilder_ == null) {
return raster_ == null ? io.opencannabis.schema.content.BrandContent.RasterGraphic.getDefaultInstance() : raster_;
} else {
return rasterBuilder_.getMessage();
}
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public Builder setRaster(io.opencannabis.schema.content.BrandContent.RasterGraphic value) {
if (rasterBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
raster_ = value;
onChanged();
} else {
rasterBuilder_.setMessage(value);
}
return this;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public Builder setRaster(
io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder builderForValue) {
if (rasterBuilder_ == null) {
raster_ = builderForValue.build();
onChanged();
} else {
rasterBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public Builder mergeRaster(io.opencannabis.schema.content.BrandContent.RasterGraphic value) {
if (rasterBuilder_ == null) {
if (raster_ != null) {
raster_ =
io.opencannabis.schema.content.BrandContent.RasterGraphic.newBuilder(raster_).mergeFrom(value).buildPartial();
} else {
raster_ = value;
}
onChanged();
} else {
rasterBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public Builder clearRaster() {
if (rasterBuilder_ == null) {
raster_ = null;
onChanged();
} else {
raster_ = null;
rasterBuilder_ = null;
}
return this;
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder getRasterBuilder() {
onChanged();
return getRasterFieldBuilder().getBuilder();
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
public io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder getRasterOrBuilder() {
if (rasterBuilder_ != null) {
return rasterBuilder_.getMessageOrBuilder();
} else {
return raster_ == null ?
io.opencannabis.schema.content.BrandContent.RasterGraphic.getDefaultInstance() : raster_;
}
}
/**
*
* Raster graphic references.
*
*
* .opencannabis.content.RasterGraphic raster = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.RasterGraphic, io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder, io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder>
getRasterFieldBuilder() {
if (rasterBuilder_ == null) {
rasterBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.RasterGraphic, io.opencannabis.schema.content.BrandContent.RasterGraphic.Builder, io.opencannabis.schema.content.BrandContent.RasterGraphicOrBuilder>(
getRaster(),
getParentForChildren(),
isClean());
raster_ = null;
}
return rasterBuilder_;
}
private io.opencannabis.schema.media.MediaItemKey.MediaReference vector_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder> vectorBuilder_;
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public boolean hasVector() {
return vectorBuilder_ != null || vector_ != null;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference getVector() {
if (vectorBuilder_ == null) {
return vector_ == null ? io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : vector_;
} else {
return vectorBuilder_.getMessage();
}
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public Builder setVector(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (vectorBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
vector_ = value;
onChanged();
} else {
vectorBuilder_.setMessage(value);
}
return this;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public Builder setVector(
io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder builderForValue) {
if (vectorBuilder_ == null) {
vector_ = builderForValue.build();
onChanged();
} else {
vectorBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public Builder mergeVector(io.opencannabis.schema.media.MediaItemKey.MediaReference value) {
if (vectorBuilder_ == null) {
if (vector_ != null) {
vector_ =
io.opencannabis.schema.media.MediaItemKey.MediaReference.newBuilder(vector_).mergeFrom(value).buildPartial();
} else {
vector_ = value;
}
onChanged();
} else {
vectorBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public Builder clearVector() {
if (vectorBuilder_ == null) {
vector_ = null;
onChanged();
} else {
vector_ = null;
vectorBuilder_ = null;
}
return this;
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder getVectorBuilder() {
onChanged();
return getVectorFieldBuilder().getBuilder();
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
public io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder getVectorOrBuilder() {
if (vectorBuilder_ != null) {
return vectorBuilder_.getMessageOrBuilder();
} else {
return vector_ == null ?
io.opencannabis.schema.media.MediaItemKey.MediaReference.getDefaultInstance() : vector_;
}
}
/**
*
* Vector graphic reference.
*
*
* .opencannabis.media.MediaReference vector = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>
getVectorFieldBuilder() {
if (vectorBuilder_ == null) {
vectorBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.media.MediaItemKey.MediaReference, io.opencannabis.schema.media.MediaItemKey.MediaReference.Builder, io.opencannabis.schema.media.MediaItemKey.MediaReferenceOrBuilder>(
getVector(),
getParentForChildren(),
isClean());
vector_ = null;
}
return vectorBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:opencannabis.content.BrandAsset)
}
// @@protoc_insertion_point(class_scope:opencannabis.content.BrandAsset)
private static final io.opencannabis.schema.content.BrandContent.BrandAsset DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.opencannabis.schema.content.BrandContent.BrandAsset();
}
public static io.opencannabis.schema.content.BrandContent.BrandAsset getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public BrandAsset parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new BrandAsset(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.BrandAsset getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
public interface BrandOrBuilder extends
// @@protoc_insertion_point(interface_extends:opencannabis.content.Brand)
com.google.protobuf.MessageOrBuilder {
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
boolean hasName();
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
io.opencannabis.schema.content.NameContent.Name getName();
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
io.opencannabis.schema.content.NameContent.NameOrBuilder getNameOrBuilder();
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
boolean hasParent();
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
io.opencannabis.schema.content.BrandContent.Brand getParent();
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
io.opencannabis.schema.content.BrandContent.BrandOrBuilder getParentOrBuilder();
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
boolean hasSummary();
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
io.opencannabis.schema.content.GenericContent.Content getSummary();
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
io.opencannabis.schema.content.GenericContent.ContentOrBuilder getSummaryOrBuilder();
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
java.util.List
getMediaList();
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
io.opencannabis.schema.content.BrandContent.BrandAsset getMedia(int index);
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
int getMediaCount();
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
java.util.List extends io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder>
getMediaOrBuilderList();
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder getMediaOrBuilder(
int index);
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
boolean hasTheme();
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
io.opencannabis.schema.content.Colors.ColorScheme getTheme();
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder getThemeOrBuilder();
}
/**
*
* Information about a particular brand or producer of products or materials.
*
*
* Protobuf type {@code opencannabis.content.Brand}
*/
public static final class Brand extends
com.google.protobuf.GeneratedMessageV3 implements
// @@protoc_insertion_point(message_implements:opencannabis.content.Brand)
BrandOrBuilder {
private static final long serialVersionUID = 0L;
// Use Brand.newBuilder() to construct.
private Brand(com.google.protobuf.GeneratedMessageV3.Builder> builder) {
super(builder);
}
private Brand() {
media_ = java.util.Collections.emptyList();
}
@java.lang.Override
public final com.google.protobuf.UnknownFieldSet
getUnknownFields() {
return this.unknownFields;
}
private Brand(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
this();
if (extensionRegistry == null) {
throw new java.lang.NullPointerException();
}
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;
case 10: {
io.opencannabis.schema.content.NameContent.Name.Builder subBuilder = null;
if (name_ != null) {
subBuilder = name_.toBuilder();
}
name_ = input.readMessage(io.opencannabis.schema.content.NameContent.Name.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(name_);
name_ = subBuilder.buildPartial();
}
break;
}
case 18: {
io.opencannabis.schema.content.BrandContent.Brand.Builder subBuilder = null;
if (parent_ != null) {
subBuilder = parent_.toBuilder();
}
parent_ = input.readMessage(io.opencannabis.schema.content.BrandContent.Brand.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(parent_);
parent_ = subBuilder.buildPartial();
}
break;
}
case 26: {
io.opencannabis.schema.content.GenericContent.Content.Builder subBuilder = null;
if (summary_ != null) {
subBuilder = summary_.toBuilder();
}
summary_ = input.readMessage(io.opencannabis.schema.content.GenericContent.Content.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(summary_);
summary_ = subBuilder.buildPartial();
}
break;
}
case 162: {
if (!((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
media_ = new java.util.ArrayList();
mutable_bitField0_ |= 0x00000008;
}
media_.add(
input.readMessage(io.opencannabis.schema.content.BrandContent.BrandAsset.parser(), extensionRegistry));
break;
}
case 170: {
io.opencannabis.schema.content.Colors.ColorScheme.Builder subBuilder = null;
if (theme_ != null) {
subBuilder = theme_.toBuilder();
}
theme_ = input.readMessage(io.opencannabis.schema.content.Colors.ColorScheme.parser(), extensionRegistry);
if (subBuilder != null) {
subBuilder.mergeFrom(theme_);
theme_ = subBuilder.buildPartial();
}
break;
}
default: {
if (!parseUnknownFieldProto3(
input, unknownFields, extensionRegistry, tag)) {
done = true;
}
break;
}
}
}
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
throw e.setUnfinishedMessage(this);
} catch (java.io.IOException e) {
throw new com.google.protobuf.InvalidProtocolBufferException(
e).setUnfinishedMessage(this);
} finally {
if (((mutable_bitField0_ & 0x00000008) == 0x00000008)) {
media_ = java.util.Collections.unmodifiableList(media_);
}
this.unknownFields = unknownFields.build();
makeExtensionsImmutable();
}
}
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_Brand_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_Brand_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.Brand.class, io.opencannabis.schema.content.BrandContent.Brand.Builder.class);
}
private int bitField0_;
public static final int NAME_FIELD_NUMBER = 1;
private io.opencannabis.schema.content.NameContent.Name name_;
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public boolean hasName() {
return name_ != null;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public io.opencannabis.schema.content.NameContent.Name getName() {
return name_ == null ? io.opencannabis.schema.content.NameContent.Name.getDefaultInstance() : name_;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public io.opencannabis.schema.content.NameContent.NameOrBuilder getNameOrBuilder() {
return getName();
}
public static final int PARENT_FIELD_NUMBER = 2;
private io.opencannabis.schema.content.BrandContent.Brand parent_;
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public boolean hasParent() {
return parent_ != null;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public io.opencannabis.schema.content.BrandContent.Brand getParent() {
return parent_ == null ? io.opencannabis.schema.content.BrandContent.Brand.getDefaultInstance() : parent_;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public io.opencannabis.schema.content.BrandContent.BrandOrBuilder getParentOrBuilder() {
return getParent();
}
public static final int SUMMARY_FIELD_NUMBER = 3;
private io.opencannabis.schema.content.GenericContent.Content summary_;
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public boolean hasSummary() {
return summary_ != null;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public io.opencannabis.schema.content.GenericContent.Content getSummary() {
return summary_ == null ? io.opencannabis.schema.content.GenericContent.Content.getDefaultInstance() : summary_;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public io.opencannabis.schema.content.GenericContent.ContentOrBuilder getSummaryOrBuilder() {
return getSummary();
}
public static final int MEDIA_FIELD_NUMBER = 20;
private java.util.List media_;
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public java.util.List getMediaList() {
return media_;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public java.util.List extends io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder>
getMediaOrBuilderList() {
return media_;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public int getMediaCount() {
return media_.size();
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAsset getMedia(int index) {
return media_.get(index);
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder getMediaOrBuilder(
int index) {
return media_.get(index);
}
public static final int THEME_FIELD_NUMBER = 21;
private io.opencannabis.schema.content.Colors.ColorScheme theme_;
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public boolean hasTheme() {
return theme_ != null;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public io.opencannabis.schema.content.Colors.ColorScheme getTheme() {
return theme_ == null ? io.opencannabis.schema.content.Colors.ColorScheme.getDefaultInstance() : theme_;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder getThemeOrBuilder() {
return getTheme();
}
private byte memoizedIsInitialized = -1;
@java.lang.Override
public final boolean isInitialized() {
byte isInitialized = memoizedIsInitialized;
if (isInitialized == 1) return true;
if (isInitialized == 0) return false;
memoizedIsInitialized = 1;
return true;
}
@java.lang.Override
public void writeTo(com.google.protobuf.CodedOutputStream output)
throws java.io.IOException {
if (name_ != null) {
output.writeMessage(1, getName());
}
if (parent_ != null) {
output.writeMessage(2, getParent());
}
if (summary_ != null) {
output.writeMessage(3, getSummary());
}
for (int i = 0; i < media_.size(); i++) {
output.writeMessage(20, media_.get(i));
}
if (theme_ != null) {
output.writeMessage(21, getTheme());
}
unknownFields.writeTo(output);
}
@java.lang.Override
public int getSerializedSize() {
int size = memoizedSize;
if (size != -1) return size;
size = 0;
if (name_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(1, getName());
}
if (parent_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(2, getParent());
}
if (summary_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(3, getSummary());
}
for (int i = 0; i < media_.size(); i++) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(20, media_.get(i));
}
if (theme_ != null) {
size += com.google.protobuf.CodedOutputStream
.computeMessageSize(21, getTheme());
}
size += unknownFields.getSerializedSize();
memoizedSize = size;
return size;
}
@java.lang.Override
public boolean equals(final java.lang.Object obj) {
if (obj == this) {
return true;
}
if (!(obj instanceof io.opencannabis.schema.content.BrandContent.Brand)) {
return super.equals(obj);
}
io.opencannabis.schema.content.BrandContent.Brand other = (io.opencannabis.schema.content.BrandContent.Brand) obj;
boolean result = true;
result = result && (hasName() == other.hasName());
if (hasName()) {
result = result && getName()
.equals(other.getName());
}
result = result && (hasParent() == other.hasParent());
if (hasParent()) {
result = result && getParent()
.equals(other.getParent());
}
result = result && (hasSummary() == other.hasSummary());
if (hasSummary()) {
result = result && getSummary()
.equals(other.getSummary());
}
result = result && getMediaList()
.equals(other.getMediaList());
result = result && (hasTheme() == other.hasTheme());
if (hasTheme()) {
result = result && getTheme()
.equals(other.getTheme());
}
result = result && unknownFields.equals(other.unknownFields);
return result;
}
@java.lang.Override
public int hashCode() {
if (memoizedHashCode != 0) {
return memoizedHashCode;
}
int hash = 41;
hash = (19 * hash) + getDescriptor().hashCode();
if (hasName()) {
hash = (37 * hash) + NAME_FIELD_NUMBER;
hash = (53 * hash) + getName().hashCode();
}
if (hasParent()) {
hash = (37 * hash) + PARENT_FIELD_NUMBER;
hash = (53 * hash) + getParent().hashCode();
}
if (hasSummary()) {
hash = (37 * hash) + SUMMARY_FIELD_NUMBER;
hash = (53 * hash) + getSummary().hashCode();
}
if (getMediaCount() > 0) {
hash = (37 * hash) + MEDIA_FIELD_NUMBER;
hash = (53 * hash) + getMediaList().hashCode();
}
if (hasTheme()) {
hash = (37 * hash) + THEME_FIELD_NUMBER;
hash = (53 * hash) + getTheme().hashCode();
}
hash = (29 * hash) + unknownFields.hashCode();
memoizedHashCode = hash;
return hash;
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
java.nio.ByteBuffer data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
java.nio.ByteBuffer data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
com.google.protobuf.ByteString data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
com.google.protobuf.ByteString data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(byte[] data)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
byte[] data,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return PARSER.parseFrom(data, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseDelimitedFrom(java.io.InputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseDelimitedFrom(
java.io.InputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseDelimitedWithIOException(PARSER, input, extensionRegistry);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
com.google.protobuf.CodedInputStream input)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input);
}
public static io.opencannabis.schema.content.BrandContent.Brand parseFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
return com.google.protobuf.GeneratedMessageV3
.parseWithIOException(PARSER, input, extensionRegistry);
}
@java.lang.Override
public Builder newBuilderForType() { return newBuilder(); }
public static Builder newBuilder() {
return DEFAULT_INSTANCE.toBuilder();
}
public static Builder newBuilder(io.opencannabis.schema.content.BrandContent.Brand prototype) {
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
}
@java.lang.Override
public Builder toBuilder() {
return this == DEFAULT_INSTANCE
? new Builder() : new Builder().mergeFrom(this);
}
@java.lang.Override
protected Builder newBuilderForType(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
Builder builder = new Builder(parent);
return builder;
}
/**
*
* Information about a particular brand or producer of products or materials.
*
*
* Protobuf type {@code opencannabis.content.Brand}
*/
public static final class Builder extends
com.google.protobuf.GeneratedMessageV3.Builder implements
// @@protoc_insertion_point(builder_implements:opencannabis.content.Brand)
io.opencannabis.schema.content.BrandContent.BrandOrBuilder {
public static final com.google.protobuf.Descriptors.Descriptor
getDescriptor() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_Brand_descriptor;
}
@java.lang.Override
protected com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internalGetFieldAccessorTable() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_Brand_fieldAccessorTable
.ensureFieldAccessorsInitialized(
io.opencannabis.schema.content.BrandContent.Brand.class, io.opencannabis.schema.content.BrandContent.Brand.Builder.class);
}
// Construct using io.opencannabis.schema.content.BrandContent.Brand.newBuilder()
private Builder() {
maybeForceBuilderInitialization();
}
private Builder(
com.google.protobuf.GeneratedMessageV3.BuilderParent parent) {
super(parent);
maybeForceBuilderInitialization();
}
private void maybeForceBuilderInitialization() {
if (com.google.protobuf.GeneratedMessageV3
.alwaysUseFieldBuilders) {
getMediaFieldBuilder();
}
}
@java.lang.Override
public Builder clear() {
super.clear();
if (nameBuilder_ == null) {
name_ = null;
} else {
name_ = null;
nameBuilder_ = null;
}
if (parentBuilder_ == null) {
parent_ = null;
} else {
parent_ = null;
parentBuilder_ = null;
}
if (summaryBuilder_ == null) {
summary_ = null;
} else {
summary_ = null;
summaryBuilder_ = null;
}
if (mediaBuilder_ == null) {
media_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
} else {
mediaBuilder_.clear();
}
if (themeBuilder_ == null) {
theme_ = null;
} else {
theme_ = null;
themeBuilder_ = null;
}
return this;
}
@java.lang.Override
public com.google.protobuf.Descriptors.Descriptor
getDescriptorForType() {
return io.opencannabis.schema.content.BrandContent.internal_static_opencannabis_content_Brand_descriptor;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.Brand getDefaultInstanceForType() {
return io.opencannabis.schema.content.BrandContent.Brand.getDefaultInstance();
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.Brand build() {
io.opencannabis.schema.content.BrandContent.Brand result = buildPartial();
if (!result.isInitialized()) {
throw newUninitializedMessageException(result);
}
return result;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.Brand buildPartial() {
io.opencannabis.schema.content.BrandContent.Brand result = new io.opencannabis.schema.content.BrandContent.Brand(this);
int from_bitField0_ = bitField0_;
int to_bitField0_ = 0;
if (nameBuilder_ == null) {
result.name_ = name_;
} else {
result.name_ = nameBuilder_.build();
}
if (parentBuilder_ == null) {
result.parent_ = parent_;
} else {
result.parent_ = parentBuilder_.build();
}
if (summaryBuilder_ == null) {
result.summary_ = summary_;
} else {
result.summary_ = summaryBuilder_.build();
}
if (mediaBuilder_ == null) {
if (((bitField0_ & 0x00000008) == 0x00000008)) {
media_ = java.util.Collections.unmodifiableList(media_);
bitField0_ = (bitField0_ & ~0x00000008);
}
result.media_ = media_;
} else {
result.media_ = mediaBuilder_.build();
}
if (themeBuilder_ == null) {
result.theme_ = theme_;
} else {
result.theme_ = themeBuilder_.build();
}
result.bitField0_ = to_bitField0_;
onBuilt();
return result;
}
@java.lang.Override
public Builder clone() {
return (Builder) super.clone();
}
@java.lang.Override
public Builder setField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.setField(field, value);
}
@java.lang.Override
public Builder clearField(
com.google.protobuf.Descriptors.FieldDescriptor field) {
return (Builder) super.clearField(field);
}
@java.lang.Override
public Builder clearOneof(
com.google.protobuf.Descriptors.OneofDescriptor oneof) {
return (Builder) super.clearOneof(oneof);
}
@java.lang.Override
public Builder setRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
int index, java.lang.Object value) {
return (Builder) super.setRepeatedField(field, index, value);
}
@java.lang.Override
public Builder addRepeatedField(
com.google.protobuf.Descriptors.FieldDescriptor field,
java.lang.Object value) {
return (Builder) super.addRepeatedField(field, value);
}
@java.lang.Override
public Builder mergeFrom(com.google.protobuf.Message other) {
if (other instanceof io.opencannabis.schema.content.BrandContent.Brand) {
return mergeFrom((io.opencannabis.schema.content.BrandContent.Brand)other);
} else {
super.mergeFrom(other);
return this;
}
}
public Builder mergeFrom(io.opencannabis.schema.content.BrandContent.Brand other) {
if (other == io.opencannabis.schema.content.BrandContent.Brand.getDefaultInstance()) return this;
if (other.hasName()) {
mergeName(other.getName());
}
if (other.hasParent()) {
mergeParent(other.getParent());
}
if (other.hasSummary()) {
mergeSummary(other.getSummary());
}
if (mediaBuilder_ == null) {
if (!other.media_.isEmpty()) {
if (media_.isEmpty()) {
media_ = other.media_;
bitField0_ = (bitField0_ & ~0x00000008);
} else {
ensureMediaIsMutable();
media_.addAll(other.media_);
}
onChanged();
}
} else {
if (!other.media_.isEmpty()) {
if (mediaBuilder_.isEmpty()) {
mediaBuilder_.dispose();
mediaBuilder_ = null;
media_ = other.media_;
bitField0_ = (bitField0_ & ~0x00000008);
mediaBuilder_ =
com.google.protobuf.GeneratedMessageV3.alwaysUseFieldBuilders ?
getMediaFieldBuilder() : null;
} else {
mediaBuilder_.addAllMessages(other.media_);
}
}
}
if (other.hasTheme()) {
mergeTheme(other.getTheme());
}
this.mergeUnknownFields(other.unknownFields);
onChanged();
return this;
}
@java.lang.Override
public final boolean isInitialized() {
return true;
}
@java.lang.Override
public Builder mergeFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws java.io.IOException {
io.opencannabis.schema.content.BrandContent.Brand parsedMessage = null;
try {
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
parsedMessage = (io.opencannabis.schema.content.BrandContent.Brand) e.getUnfinishedMessage();
throw e.unwrapIOException();
} finally {
if (parsedMessage != null) {
mergeFrom(parsedMessage);
}
}
return this;
}
private int bitField0_;
private io.opencannabis.schema.content.NameContent.Name name_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.NameContent.Name, io.opencannabis.schema.content.NameContent.Name.Builder, io.opencannabis.schema.content.NameContent.NameOrBuilder> nameBuilder_;
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public boolean hasName() {
return nameBuilder_ != null || name_ != null;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public io.opencannabis.schema.content.NameContent.Name getName() {
if (nameBuilder_ == null) {
return name_ == null ? io.opencannabis.schema.content.NameContent.Name.getDefaultInstance() : name_;
} else {
return nameBuilder_.getMessage();
}
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public Builder setName(io.opencannabis.schema.content.NameContent.Name value) {
if (nameBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
name_ = value;
onChanged();
} else {
nameBuilder_.setMessage(value);
}
return this;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public Builder setName(
io.opencannabis.schema.content.NameContent.Name.Builder builderForValue) {
if (nameBuilder_ == null) {
name_ = builderForValue.build();
onChanged();
} else {
nameBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public Builder mergeName(io.opencannabis.schema.content.NameContent.Name value) {
if (nameBuilder_ == null) {
if (name_ != null) {
name_ =
io.opencannabis.schema.content.NameContent.Name.newBuilder(name_).mergeFrom(value).buildPartial();
} else {
name_ = value;
}
onChanged();
} else {
nameBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public Builder clearName() {
if (nameBuilder_ == null) {
name_ = null;
onChanged();
} else {
name_ = null;
nameBuilder_ = null;
}
return this;
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public io.opencannabis.schema.content.NameContent.Name.Builder getNameBuilder() {
onChanged();
return getNameFieldBuilder().getBuilder();
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
public io.opencannabis.schema.content.NameContent.NameOrBuilder getNameOrBuilder() {
if (nameBuilder_ != null) {
return nameBuilder_.getMessageOrBuilder();
} else {
return name_ == null ?
io.opencannabis.schema.content.NameContent.Name.getDefaultInstance() : name_;
}
}
/**
*
* Naming information for this brand.
*
*
* .opencannabis.content.Name name = 1;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.NameContent.Name, io.opencannabis.schema.content.NameContent.Name.Builder, io.opencannabis.schema.content.NameContent.NameOrBuilder>
getNameFieldBuilder() {
if (nameBuilder_ == null) {
nameBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.NameContent.Name, io.opencannabis.schema.content.NameContent.Name.Builder, io.opencannabis.schema.content.NameContent.NameOrBuilder>(
getName(),
getParentForChildren(),
isClean());
name_ = null;
}
return nameBuilder_;
}
private io.opencannabis.schema.content.BrandContent.Brand parent_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.Brand, io.opencannabis.schema.content.BrandContent.Brand.Builder, io.opencannabis.schema.content.BrandContent.BrandOrBuilder> parentBuilder_;
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public boolean hasParent() {
return parentBuilder_ != null || parent_ != null;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public io.opencannabis.schema.content.BrandContent.Brand getParent() {
if (parentBuilder_ == null) {
return parent_ == null ? io.opencannabis.schema.content.BrandContent.Brand.getDefaultInstance() : parent_;
} else {
return parentBuilder_.getMessage();
}
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public Builder setParent(io.opencannabis.schema.content.BrandContent.Brand value) {
if (parentBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
parent_ = value;
onChanged();
} else {
parentBuilder_.setMessage(value);
}
return this;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public Builder setParent(
io.opencannabis.schema.content.BrandContent.Brand.Builder builderForValue) {
if (parentBuilder_ == null) {
parent_ = builderForValue.build();
onChanged();
} else {
parentBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public Builder mergeParent(io.opencannabis.schema.content.BrandContent.Brand value) {
if (parentBuilder_ == null) {
if (parent_ != null) {
parent_ =
io.opencannabis.schema.content.BrandContent.Brand.newBuilder(parent_).mergeFrom(value).buildPartial();
} else {
parent_ = value;
}
onChanged();
} else {
parentBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public Builder clearParent() {
if (parentBuilder_ == null) {
parent_ = null;
onChanged();
} else {
parent_ = null;
parentBuilder_ = null;
}
return this;
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public io.opencannabis.schema.content.BrandContent.Brand.Builder getParentBuilder() {
onChanged();
return getParentFieldBuilder().getBuilder();
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
public io.opencannabis.schema.content.BrandContent.BrandOrBuilder getParentOrBuilder() {
if (parentBuilder_ != null) {
return parentBuilder_.getMessageOrBuilder();
} else {
return parent_ == null ?
io.opencannabis.schema.content.BrandContent.Brand.getDefaultInstance() : parent_;
}
}
/**
*
* Parent/owning brand, if applicable.
*
*
* .opencannabis.content.Brand parent = 2;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.Brand, io.opencannabis.schema.content.BrandContent.Brand.Builder, io.opencannabis.schema.content.BrandContent.BrandOrBuilder>
getParentFieldBuilder() {
if (parentBuilder_ == null) {
parentBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.Brand, io.opencannabis.schema.content.BrandContent.Brand.Builder, io.opencannabis.schema.content.BrandContent.BrandOrBuilder>(
getParent(),
getParentForChildren(),
isClean());
parent_ = null;
}
return parentBuilder_;
}
private io.opencannabis.schema.content.GenericContent.Content summary_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.GenericContent.Content, io.opencannabis.schema.content.GenericContent.Content.Builder, io.opencannabis.schema.content.GenericContent.ContentOrBuilder> summaryBuilder_;
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public boolean hasSummary() {
return summaryBuilder_ != null || summary_ != null;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public io.opencannabis.schema.content.GenericContent.Content getSummary() {
if (summaryBuilder_ == null) {
return summary_ == null ? io.opencannabis.schema.content.GenericContent.Content.getDefaultInstance() : summary_;
} else {
return summaryBuilder_.getMessage();
}
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public Builder setSummary(io.opencannabis.schema.content.GenericContent.Content value) {
if (summaryBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
summary_ = value;
onChanged();
} else {
summaryBuilder_.setMessage(value);
}
return this;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public Builder setSummary(
io.opencannabis.schema.content.GenericContent.Content.Builder builderForValue) {
if (summaryBuilder_ == null) {
summary_ = builderForValue.build();
onChanged();
} else {
summaryBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public Builder mergeSummary(io.opencannabis.schema.content.GenericContent.Content value) {
if (summaryBuilder_ == null) {
if (summary_ != null) {
summary_ =
io.opencannabis.schema.content.GenericContent.Content.newBuilder(summary_).mergeFrom(value).buildPartial();
} else {
summary_ = value;
}
onChanged();
} else {
summaryBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public Builder clearSummary() {
if (summaryBuilder_ == null) {
summary_ = null;
onChanged();
} else {
summary_ = null;
summaryBuilder_ = null;
}
return this;
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public io.opencannabis.schema.content.GenericContent.Content.Builder getSummaryBuilder() {
onChanged();
return getSummaryFieldBuilder().getBuilder();
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
public io.opencannabis.schema.content.GenericContent.ContentOrBuilder getSummaryOrBuilder() {
if (summaryBuilder_ != null) {
return summaryBuilder_.getMessageOrBuilder();
} else {
return summary_ == null ?
io.opencannabis.schema.content.GenericContent.Content.getDefaultInstance() : summary_;
}
}
/**
*
* Summary information or content about this brand.
*
*
* .opencannabis.content.Content summary = 3;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.GenericContent.Content, io.opencannabis.schema.content.GenericContent.Content.Builder, io.opencannabis.schema.content.GenericContent.ContentOrBuilder>
getSummaryFieldBuilder() {
if (summaryBuilder_ == null) {
summaryBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.GenericContent.Content, io.opencannabis.schema.content.GenericContent.Content.Builder, io.opencannabis.schema.content.GenericContent.ContentOrBuilder>(
getSummary(),
getParentForChildren(),
isClean());
summary_ = null;
}
return summaryBuilder_;
}
private java.util.List media_ =
java.util.Collections.emptyList();
private void ensureMediaIsMutable() {
if (!((bitField0_ & 0x00000008) == 0x00000008)) {
media_ = new java.util.ArrayList(media_);
bitField0_ |= 0x00000008;
}
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.BrandAsset, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder, io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder> mediaBuilder_;
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public java.util.List getMediaList() {
if (mediaBuilder_ == null) {
return java.util.Collections.unmodifiableList(media_);
} else {
return mediaBuilder_.getMessageList();
}
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public int getMediaCount() {
if (mediaBuilder_ == null) {
return media_.size();
} else {
return mediaBuilder_.getCount();
}
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAsset getMedia(int index) {
if (mediaBuilder_ == null) {
return media_.get(index);
} else {
return mediaBuilder_.getMessage(index);
}
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder setMedia(
int index, io.opencannabis.schema.content.BrandContent.BrandAsset value) {
if (mediaBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMediaIsMutable();
media_.set(index, value);
onChanged();
} else {
mediaBuilder_.setMessage(index, value);
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder setMedia(
int index, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder builderForValue) {
if (mediaBuilder_ == null) {
ensureMediaIsMutable();
media_.set(index, builderForValue.build());
onChanged();
} else {
mediaBuilder_.setMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder addMedia(io.opencannabis.schema.content.BrandContent.BrandAsset value) {
if (mediaBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMediaIsMutable();
media_.add(value);
onChanged();
} else {
mediaBuilder_.addMessage(value);
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder addMedia(
int index, io.opencannabis.schema.content.BrandContent.BrandAsset value) {
if (mediaBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
ensureMediaIsMutable();
media_.add(index, value);
onChanged();
} else {
mediaBuilder_.addMessage(index, value);
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder addMedia(
io.opencannabis.schema.content.BrandContent.BrandAsset.Builder builderForValue) {
if (mediaBuilder_ == null) {
ensureMediaIsMutable();
media_.add(builderForValue.build());
onChanged();
} else {
mediaBuilder_.addMessage(builderForValue.build());
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder addMedia(
int index, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder builderForValue) {
if (mediaBuilder_ == null) {
ensureMediaIsMutable();
media_.add(index, builderForValue.build());
onChanged();
} else {
mediaBuilder_.addMessage(index, builderForValue.build());
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder addAllMedia(
java.lang.Iterable extends io.opencannabis.schema.content.BrandContent.BrandAsset> values) {
if (mediaBuilder_ == null) {
ensureMediaIsMutable();
com.google.protobuf.AbstractMessageLite.Builder.addAll(
values, media_);
onChanged();
} else {
mediaBuilder_.addAllMessages(values);
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder clearMedia() {
if (mediaBuilder_ == null) {
media_ = java.util.Collections.emptyList();
bitField0_ = (bitField0_ & ~0x00000008);
onChanged();
} else {
mediaBuilder_.clear();
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public Builder removeMedia(int index) {
if (mediaBuilder_ == null) {
ensureMediaIsMutable();
media_.remove(index);
onChanged();
} else {
mediaBuilder_.remove(index);
}
return this;
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAsset.Builder getMediaBuilder(
int index) {
return getMediaFieldBuilder().getBuilder(index);
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder getMediaOrBuilder(
int index) {
if (mediaBuilder_ == null) {
return media_.get(index); } else {
return mediaBuilder_.getMessageOrBuilder(index);
}
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public java.util.List extends io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder>
getMediaOrBuilderList() {
if (mediaBuilder_ != null) {
return mediaBuilder_.getMessageOrBuilderList();
} else {
return java.util.Collections.unmodifiableList(media_);
}
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAsset.Builder addMediaBuilder() {
return getMediaFieldBuilder().addBuilder(
io.opencannabis.schema.content.BrandContent.BrandAsset.getDefaultInstance());
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public io.opencannabis.schema.content.BrandContent.BrandAsset.Builder addMediaBuilder(
int index) {
return getMediaFieldBuilder().addBuilder(
index, io.opencannabis.schema.content.BrandContent.BrandAsset.getDefaultInstance());
}
/**
*
* Media items attached to this brand.
*
*
* repeated .opencannabis.content.BrandAsset media = 20;
*/
public java.util.List
getMediaBuilderList() {
return getMediaFieldBuilder().getBuilderList();
}
private com.google.protobuf.RepeatedFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.BrandAsset, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder, io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder>
getMediaFieldBuilder() {
if (mediaBuilder_ == null) {
mediaBuilder_ = new com.google.protobuf.RepeatedFieldBuilderV3<
io.opencannabis.schema.content.BrandContent.BrandAsset, io.opencannabis.schema.content.BrandContent.BrandAsset.Builder, io.opencannabis.schema.content.BrandContent.BrandAssetOrBuilder>(
media_,
((bitField0_ & 0x00000008) == 0x00000008),
getParentForChildren(),
isClean());
media_ = null;
}
return mediaBuilder_;
}
private io.opencannabis.schema.content.Colors.ColorScheme theme_ = null;
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.Colors.ColorScheme, io.opencannabis.schema.content.Colors.ColorScheme.Builder, io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder> themeBuilder_;
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public boolean hasTheme() {
return themeBuilder_ != null || theme_ != null;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public io.opencannabis.schema.content.Colors.ColorScheme getTheme() {
if (themeBuilder_ == null) {
return theme_ == null ? io.opencannabis.schema.content.Colors.ColorScheme.getDefaultInstance() : theme_;
} else {
return themeBuilder_.getMessage();
}
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public Builder setTheme(io.opencannabis.schema.content.Colors.ColorScheme value) {
if (themeBuilder_ == null) {
if (value == null) {
throw new NullPointerException();
}
theme_ = value;
onChanged();
} else {
themeBuilder_.setMessage(value);
}
return this;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public Builder setTheme(
io.opencannabis.schema.content.Colors.ColorScheme.Builder builderForValue) {
if (themeBuilder_ == null) {
theme_ = builderForValue.build();
onChanged();
} else {
themeBuilder_.setMessage(builderForValue.build());
}
return this;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public Builder mergeTheme(io.opencannabis.schema.content.Colors.ColorScheme value) {
if (themeBuilder_ == null) {
if (theme_ != null) {
theme_ =
io.opencannabis.schema.content.Colors.ColorScheme.newBuilder(theme_).mergeFrom(value).buildPartial();
} else {
theme_ = value;
}
onChanged();
} else {
themeBuilder_.mergeFrom(value);
}
return this;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public Builder clearTheme() {
if (themeBuilder_ == null) {
theme_ = null;
onChanged();
} else {
theme_ = null;
themeBuilder_ = null;
}
return this;
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public io.opencannabis.schema.content.Colors.ColorScheme.Builder getThemeBuilder() {
onChanged();
return getThemeFieldBuilder().getBuilder();
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
public io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder getThemeOrBuilder() {
if (themeBuilder_ != null) {
return themeBuilder_.getMessageOrBuilder();
} else {
return theme_ == null ?
io.opencannabis.schema.content.Colors.ColorScheme.getDefaultInstance() : theme_;
}
}
/**
*
* Specifies color scheme and app theme values.
*
*
* .opencannabis.content.ColorScheme theme = 21;
*/
private com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.Colors.ColorScheme, io.opencannabis.schema.content.Colors.ColorScheme.Builder, io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder>
getThemeFieldBuilder() {
if (themeBuilder_ == null) {
themeBuilder_ = new com.google.protobuf.SingleFieldBuilderV3<
io.opencannabis.schema.content.Colors.ColorScheme, io.opencannabis.schema.content.Colors.ColorScheme.Builder, io.opencannabis.schema.content.Colors.ColorSchemeOrBuilder>(
getTheme(),
getParentForChildren(),
isClean());
theme_ = null;
}
return themeBuilder_;
}
@java.lang.Override
public final Builder setUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.setUnknownFieldsProto3(unknownFields);
}
@java.lang.Override
public final Builder mergeUnknownFields(
final com.google.protobuf.UnknownFieldSet unknownFields) {
return super.mergeUnknownFields(unknownFields);
}
// @@protoc_insertion_point(builder_scope:opencannabis.content.Brand)
}
// @@protoc_insertion_point(class_scope:opencannabis.content.Brand)
private static final io.opencannabis.schema.content.BrandContent.Brand DEFAULT_INSTANCE;
static {
DEFAULT_INSTANCE = new io.opencannabis.schema.content.BrandContent.Brand();
}
public static io.opencannabis.schema.content.BrandContent.Brand getDefaultInstance() {
return DEFAULT_INSTANCE;
}
private static final com.google.protobuf.Parser
PARSER = new com.google.protobuf.AbstractParser() {
@java.lang.Override
public Brand parsePartialFrom(
com.google.protobuf.CodedInputStream input,
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
throws com.google.protobuf.InvalidProtocolBufferException {
return new Brand(input, extensionRegistry);
}
};
public static com.google.protobuf.Parser parser() {
return PARSER;
}
@java.lang.Override
public com.google.protobuf.Parser getParserForType() {
return PARSER;
}
@java.lang.Override
public io.opencannabis.schema.content.BrandContent.Brand getDefaultInstanceForType() {
return DEFAULT_INSTANCE;
}
}
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_opencannabis_content_RasterGraphic_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_opencannabis_content_RasterGraphic_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_opencannabis_content_BrandAsset_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_opencannabis_content_BrandAsset_fieldAccessorTable;
private static final com.google.protobuf.Descriptors.Descriptor
internal_static_opencannabis_content_Brand_descriptor;
private static final
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable
internal_static_opencannabis_content_Brand_fieldAccessorTable;
public static com.google.protobuf.Descriptors.FileDescriptor
getDescriptor() {
return descriptor;
}
private static com.google.protobuf.Descriptors.FileDescriptor
descriptor;
static {
java.lang.String[] descriptorData = {
"\n\023content/Brand.proto\022\024opencannabis.cont" +
"ent\032\024content/Colors.proto\032\022content/Name." +
"proto\032\025content/Content.proto\032\024media/Medi" +
"aKey.proto\"y\n\rRasterGraphic\0224\n\010standard\030" +
"\001 \001(\0132\".opencannabis.media.MediaReferenc" +
"e\0222\n\006retina\030\002 \001(\0132\".opencannabis.media.M" +
"ediaReference\"u\n\nBrandAsset\0223\n\006raster\030\001 " +
"\001(\0132#.opencannabis.content.RasterGraphic" +
"\0222\n\006vector\030\002 \001(\0132\".opencannabis.media.Me" +
"diaReference\"\361\001\n\005Brand\022(\n\004name\030\001 \001(\0132\032.o" +
"pencannabis.content.Name\022+\n\006parent\030\002 \001(\013" +
"2\033.opencannabis.content.Brand\022.\n\007summary" +
"\030\003 \001(\0132\035.opencannabis.content.Content\022/\n" +
"\005media\030\024 \003(\0132 .opencannabis.content.Bran" +
"dAsset\0220\n\005theme\030\025 \001(\0132!.opencannabis.con" +
"tent.ColorSchemeB8\n\036io.opencannabis.sche" +
"ma.contentB\014BrandContentH\001P\000\242\002\003OCSb\006prot" +
"o3"
};
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() {
public com.google.protobuf.ExtensionRegistry assignDescriptors(
com.google.protobuf.Descriptors.FileDescriptor root) {
descriptor = root;
return null;
}
};
com.google.protobuf.Descriptors.FileDescriptor
.internalBuildGeneratedFileFrom(descriptorData,
new com.google.protobuf.Descriptors.FileDescriptor[] {
io.opencannabis.schema.content.Colors.getDescriptor(),
io.opencannabis.schema.content.NameContent.getDescriptor(),
io.opencannabis.schema.content.GenericContent.getDescriptor(),
io.opencannabis.schema.media.MediaItemKey.getDescriptor(),
}, assigner);
internal_static_opencannabis_content_RasterGraphic_descriptor =
getDescriptor().getMessageTypes().get(0);
internal_static_opencannabis_content_RasterGraphic_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_opencannabis_content_RasterGraphic_descriptor,
new java.lang.String[] { "Standard", "Retina", });
internal_static_opencannabis_content_BrandAsset_descriptor =
getDescriptor().getMessageTypes().get(1);
internal_static_opencannabis_content_BrandAsset_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_opencannabis_content_BrandAsset_descriptor,
new java.lang.String[] { "Raster", "Vector", });
internal_static_opencannabis_content_Brand_descriptor =
getDescriptor().getMessageTypes().get(2);
internal_static_opencannabis_content_Brand_fieldAccessorTable = new
com.google.protobuf.GeneratedMessageV3.FieldAccessorTable(
internal_static_opencannabis_content_Brand_descriptor,
new java.lang.String[] { "Name", "Parent", "Summary", "Media", "Theme", });
io.opencannabis.schema.content.Colors.getDescriptor();
io.opencannabis.schema.content.NameContent.getDescriptor();
io.opencannabis.schema.content.GenericContent.getDescriptor();
io.opencannabis.schema.media.MediaItemKey.getDescriptor();
}
// @@protoc_insertion_point(outer_class_scope)
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy