ResourceProto.java

// Generated by the protocol buffer compiler.  DO NOT EDIT!
// source: resources.proto

package androidx.wear.protolayout.proto;

public final class ResourceProto {
  private ResourceProto() {}
  public static void registerAllExtensions(
      com.google.protobuf.ExtensionRegistryLite registry) {
  }
  /**
   * <pre>
   * Format describing the contents of an image data byte array.
   * </pre>
   *
   * Protobuf enum {@code androidx.wear.protolayout.proto.ImageFormat}
   */
  public enum ImageFormat
      implements com.google.protobuf.Internal.EnumLite {
    /**
     * <pre>
     * An undefined image format.
     * </pre>
     *
     * <code>IMAGE_FORMAT_UNDEFINED = 0;</code>
     */
    IMAGE_FORMAT_UNDEFINED(0),
    /**
     * <pre>
     * An image format where each pixel is stored on 2 bytes, with red using 5
     * bits, green using 6 bits and blue using 5 bits of precision.
     * </pre>
     *
     * <code>IMAGE_FORMAT_RGB_565 = 1;</code>
     */
    IMAGE_FORMAT_RGB_565(1),
    UNRECOGNIZED(-1),
    ;

    /**
     * <pre>
     * An undefined image format.
     * </pre>
     *
     * <code>IMAGE_FORMAT_UNDEFINED = 0;</code>
     */
    public static final int IMAGE_FORMAT_UNDEFINED_VALUE = 0;
    /**
     * <pre>
     * An image format where each pixel is stored on 2 bytes, with red using 5
     * bits, green using 6 bits and blue using 5 bits of precision.
     * </pre>
     *
     * <code>IMAGE_FORMAT_RGB_565 = 1;</code>
     */
    public static final int IMAGE_FORMAT_RGB_565_VALUE = 1;


    @java.lang.Override
    public final int getNumber() {
      if (this == UNRECOGNIZED) {
        throw new java.lang.IllegalArgumentException(
            "Can't get the number of an unknown enum value.");
      }
      return value;
    }

    /**
     * @param value The number of the enum to look for.
     * @return The enum associated with the given number.
     * @deprecated Use {@link #forNumber(int)} instead.
     */
    @java.lang.Deprecated
    public static ImageFormat valueOf(int value) {
      return forNumber(value);
    }

    public static ImageFormat forNumber(int value) {
      switch (value) {
        case 0: return IMAGE_FORMAT_UNDEFINED;
        case 1: return IMAGE_FORMAT_RGB_565;
        default: return null;
      }
    }

    public static com.google.protobuf.Internal.EnumLiteMap<ImageFormat>
        internalGetValueMap() {
      return internalValueMap;
    }
    private static final com.google.protobuf.Internal.EnumLiteMap<
        ImageFormat> internalValueMap =
          new com.google.protobuf.Internal.EnumLiteMap<ImageFormat>() {
            @java.lang.Override
            public ImageFormat findValueByNumber(int number) {
              return ImageFormat.forNumber(number);
            }
          };

    public static com.google.protobuf.Internal.EnumVerifier 
        internalGetVerifier() {
      return ImageFormatVerifier.INSTANCE;
    }

    private static final class ImageFormatVerifier implements 
         com.google.protobuf.Internal.EnumVerifier { 
            static final com.google.protobuf.Internal.EnumVerifier           INSTANCE = new ImageFormatVerifier();
            @java.lang.Override
            public boolean isInRange(int number) {
              return ImageFormat.forNumber(number) != null;
            }
          };

    private final int value;

    private ImageFormat(int value) {
      this.value = value;
    }

    // @@protoc_insertion_point(enum_scope:androidx.wear.protolayout.proto.ImageFormat)
  }

  public interface AndroidImageResourceByResIdOrBuilder extends
      // @@protoc_insertion_point(interface_extends:androidx.wear.protolayout.proto.AndroidImageResourceByResId)
      com.google.protobuf.MessageLiteOrBuilder {

    /**
     * <pre>
     * The Android resource ID of this image. This must refer to a drawable under
     * R.drawable.
     * </pre>
     *
     * <code>int32 resource_id = 1;</code>
     * @return The resourceId.
     */
    int getResourceId();
  }
  /**
   * <pre>
   * An image resource which maps to an Android drawable by resource ID.
   * </pre>
   *
   * Protobuf type {@code androidx.wear.protolayout.proto.AndroidImageResourceByResId}
   */
  public  static final class AndroidImageResourceByResId extends
      com.google.protobuf.GeneratedMessageLite<
          AndroidImageResourceByResId, AndroidImageResourceByResId.Builder> implements
      // @@protoc_insertion_point(message_implements:androidx.wear.protolayout.proto.AndroidImageResourceByResId)
      AndroidImageResourceByResIdOrBuilder {
    private AndroidImageResourceByResId() {
    }
    public static final int RESOURCE_ID_FIELD_NUMBER = 1;
    private int resourceId_;
    /**
     * <pre>
     * The Android resource ID of this image. This must refer to a drawable under
     * R.drawable.
     * </pre>
     *
     * <code>int32 resource_id = 1;</code>
     * @return The resourceId.
     */
    @java.lang.Override
    public int getResourceId() {
      return resourceId_;
    }
    /**
     * <pre>
     * The Android resource ID of this image. This must refer to a drawable under
     * R.drawable.
     * </pre>
     *
     * <code>int32 resource_id = 1;</code>
     * @param value The resourceId to set.
     */
    private void setResourceId(int value) {
      
      resourceId_ = value;
    }
    /**
     * <pre>
     * The Android resource ID of this image. This must refer to a drawable under
     * R.drawable.
     * </pre>
     *
     * <code>int32 resource_id = 1;</code>
     */
    private void clearResourceId() {
      
      resourceId_ = 0;
    }

    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }

    public static Builder newBuilder() {
      return (Builder) DEFAULT_INSTANCE.createBuilder();
    }
    public static Builder newBuilder(androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId prototype) {
      return (Builder) DEFAULT_INSTANCE.createBuilder(prototype);
    }

    /**
     * <pre>
     * An image resource which maps to an Android drawable by resource ID.
     * </pre>
     *
     * Protobuf type {@code androidx.wear.protolayout.proto.AndroidImageResourceByResId}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageLite.Builder<
          androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId, Builder> implements
        // @@protoc_insertion_point(builder_implements:androidx.wear.protolayout.proto.AndroidImageResourceByResId)
        androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResIdOrBuilder {
      // Construct using androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.newBuilder()
      private Builder() {
        super(DEFAULT_INSTANCE);
      }


      /**
       * <pre>
       * The Android resource ID of this image. This must refer to a drawable under
       * R.drawable.
       * </pre>
       *
       * <code>int32 resource_id = 1;</code>
       * @return The resourceId.
       */
      @java.lang.Override
      public int getResourceId() {
        return instance.getResourceId();
      }
      /**
       * <pre>
       * The Android resource ID of this image. This must refer to a drawable under
       * R.drawable.
       * </pre>
       *
       * <code>int32 resource_id = 1;</code>
       * @param value The resourceId to set.
       * @return This builder for chaining.
       */
      public Builder setResourceId(int value) {
        copyOnWrite();
        instance.setResourceId(value);
        return this;
      }
      /**
       * <pre>
       * The Android resource ID of this image. This must refer to a drawable under
       * R.drawable.
       * </pre>
       *
       * <code>int32 resource_id = 1;</code>
       * @return This builder for chaining.
       */
      public Builder clearResourceId() {
        copyOnWrite();
        instance.clearResourceId();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:androidx.wear.protolayout.proto.AndroidImageResourceByResId)
    }
    @java.lang.Override
    @java.lang.SuppressWarnings({"unchecked", "fallthrough"})
    protected final java.lang.Object dynamicMethod(
        com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
        java.lang.Object arg0, java.lang.Object arg1) {
      switch (method) {
        case NEW_MUTABLE_INSTANCE: {
          return new androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId();
        }
        case NEW_BUILDER: {
          return new Builder();
        }
        case BUILD_MESSAGE_INFO: {
            java.lang.Object[] objects = new java.lang.Object[] {
              "resourceId_",
            };
            java.lang.String info =
                "\u0000\u0001\u0000\u0000\u0001\u0001\u0001\u0000\u0000\u0000\u0001\u0004";
            return newMessageInfo(DEFAULT_INSTANCE, info, objects);
        }
        // fall through
        case GET_DEFAULT_INSTANCE: {
          return DEFAULT_INSTANCE;
        }
        case GET_PARSER: {
          com.google.protobuf.Parser<androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId> parser = PARSER;
          if (parser == null) {
            synchronized (androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.class) {
              parser = PARSER;
              if (parser == null) {
                parser =
                    new DefaultInstanceBasedParser<androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId>(
                        DEFAULT_INSTANCE);
                PARSER = parser;
              }
            }
          }
          return parser;
      }
      case GET_MEMOIZED_IS_INITIALIZED: {
        return (byte) 1;
      }
      case SET_MEMOIZED_IS_INITIALIZED: {
        return null;
      }
      }
      throw new UnsupportedOperationException();
    }


    // @@protoc_insertion_point(class_scope:androidx.wear.protolayout.proto.AndroidImageResourceByResId)
    private static final androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId DEFAULT_INSTANCE;
    static {
      AndroidImageResourceByResId defaultInstance = new AndroidImageResourceByResId();
      // New instances are implicitly immutable so no need to make
      // immutable.
      DEFAULT_INSTANCE = defaultInstance;
      com.google.protobuf.GeneratedMessageLite.registerDefaultInstance(
        AndroidImageResourceByResId.class, defaultInstance);
    }

    public static androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static volatile com.google.protobuf.Parser<AndroidImageResourceByResId> PARSER;

    public static com.google.protobuf.Parser<AndroidImageResourceByResId> parser() {
      return DEFAULT_INSTANCE.getParserForType();
    }
  }

  public interface InlineImageResourceOrBuilder extends
      // @@protoc_insertion_point(interface_extends:androidx.wear.protolayout.proto.InlineImageResource)
      com.google.protobuf.MessageLiteOrBuilder {

    /**
     * <pre>
     * The byte array representing the image.
     * </pre>
     *
     * <code>bytes data = 1;</code>
     * @return The data.
     */
    com.google.protobuf.ByteString getData();

    /**
     * <pre>
     * The native width of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 width_px = 2;</code>
     * @return The widthPx.
     */
    int getWidthPx();

    /**
     * <pre>
     * The native height of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 height_px = 3;</code>
     * @return The heightPx.
     */
    int getHeightPx();

    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @return The enum numeric value on the wire for format.
     */
    int getFormatValue();
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @return The format.
     */
    androidx.wear.protolayout.proto.ResourceProto.ImageFormat getFormat();
  }
  /**
   * <pre>
   * An image resource whose data is fully inlined, with no dependency on a
   * system or app resource.
   * </pre>
   *
   * Protobuf type {@code androidx.wear.protolayout.proto.InlineImageResource}
   */
  public  static final class InlineImageResource extends
      com.google.protobuf.GeneratedMessageLite<
          InlineImageResource, InlineImageResource.Builder> implements
      // @@protoc_insertion_point(message_implements:androidx.wear.protolayout.proto.InlineImageResource)
      InlineImageResourceOrBuilder {
    private InlineImageResource() {
      data_ = com.google.protobuf.ByteString.EMPTY;
    }
    public static final int DATA_FIELD_NUMBER = 1;
    private com.google.protobuf.ByteString data_;
    /**
     * <pre>
     * The byte array representing the image.
     * </pre>
     *
     * <code>bytes data = 1;</code>
     * @return The data.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString getData() {
      return data_;
    }
    /**
     * <pre>
     * The byte array representing the image.
     * </pre>
     *
     * <code>bytes data = 1;</code>
     * @param value The data to set.
     */
    private void setData(com.google.protobuf.ByteString value) {
      java.lang.Class<?> valueClass = value.getClass();
  
      data_ = value;
    }
    /**
     * <pre>
     * The byte array representing the image.
     * </pre>
     *
     * <code>bytes data = 1;</code>
     */
    private void clearData() {
      
      data_ = getDefaultInstance().getData();
    }

    public static final int WIDTH_PX_FIELD_NUMBER = 2;
    private int widthPx_;
    /**
     * <pre>
     * The native width of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 width_px = 2;</code>
     * @return The widthPx.
     */
    @java.lang.Override
    public int getWidthPx() {
      return widthPx_;
    }
    /**
     * <pre>
     * The native width of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 width_px = 2;</code>
     * @param value The widthPx to set.
     */
    private void setWidthPx(int value) {
      
      widthPx_ = value;
    }
    /**
     * <pre>
     * The native width of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 width_px = 2;</code>
     */
    private void clearWidthPx() {
      
      widthPx_ = 0;
    }

    public static final int HEIGHT_PX_FIELD_NUMBER = 3;
    private int heightPx_;
    /**
     * <pre>
     * The native height of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 height_px = 3;</code>
     * @return The heightPx.
     */
    @java.lang.Override
    public int getHeightPx() {
      return heightPx_;
    }
    /**
     * <pre>
     * The native height of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 height_px = 3;</code>
     * @param value The heightPx to set.
     */
    private void setHeightPx(int value) {
      
      heightPx_ = value;
    }
    /**
     * <pre>
     * The native height of the image, in pixels. Only required for formats
     * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
     * </pre>
     *
     * <code>int32 height_px = 3;</code>
     */
    private void clearHeightPx() {
      
      heightPx_ = 0;
    }

    public static final int FORMAT_FIELD_NUMBER = 4;
    private int format_;
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @return The enum numeric value on the wire for format.
     */
    @java.lang.Override
    public int getFormatValue() {
      return format_;
    }
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @return The format.
     */
    @java.lang.Override
    public androidx.wear.protolayout.proto.ResourceProto.ImageFormat getFormat() {
      androidx.wear.protolayout.proto.ResourceProto.ImageFormat result = androidx.wear.protolayout.proto.ResourceProto.ImageFormat.forNumber(format_);
      return result == null ? androidx.wear.protolayout.proto.ResourceProto.ImageFormat.UNRECOGNIZED : result;
    }
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @param value The enum numeric value on the wire for format to set.
     */
    private void setFormatValue(int value) {
        format_ = value;
    }
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     * @param value The format to set.
     */
    private void setFormat(androidx.wear.protolayout.proto.ResourceProto.ImageFormat value) {
      format_ = value.getNumber();
      
    }
    /**
     * <pre>
     * The format of the byte array data representing the image. May be left
     * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
     * will attempt to extract this from the raw image data. If the platform does
     * not support the format, the image will not be decoded or displayed.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
     */
    private void clearFormat() {
      
      format_ = 0;
    }

    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }

    public static Builder newBuilder() {
      return (Builder) DEFAULT_INSTANCE.createBuilder();
    }
    public static Builder newBuilder(androidx.wear.protolayout.proto.ResourceProto.InlineImageResource prototype) {
      return (Builder) DEFAULT_INSTANCE.createBuilder(prototype);
    }

    /**
     * <pre>
     * An image resource whose data is fully inlined, with no dependency on a
     * system or app resource.
     * </pre>
     *
     * Protobuf type {@code androidx.wear.protolayout.proto.InlineImageResource}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageLite.Builder<
          androidx.wear.protolayout.proto.ResourceProto.InlineImageResource, Builder> implements
        // @@protoc_insertion_point(builder_implements:androidx.wear.protolayout.proto.InlineImageResource)
        androidx.wear.protolayout.proto.ResourceProto.InlineImageResourceOrBuilder {
      // Construct using androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.newBuilder()
      private Builder() {
        super(DEFAULT_INSTANCE);
      }


      /**
       * <pre>
       * The byte array representing the image.
       * </pre>
       *
       * <code>bytes data = 1;</code>
       * @return The data.
       */
      @java.lang.Override
      public com.google.protobuf.ByteString getData() {
        return instance.getData();
      }
      /**
       * <pre>
       * The byte array representing the image.
       * </pre>
       *
       * <code>bytes data = 1;</code>
       * @param value The data to set.
       * @return This builder for chaining.
       */
      public Builder setData(com.google.protobuf.ByteString value) {
        copyOnWrite();
        instance.setData(value);
        return this;
      }
      /**
       * <pre>
       * The byte array representing the image.
       * </pre>
       *
       * <code>bytes data = 1;</code>
       * @return This builder for chaining.
       */
      public Builder clearData() {
        copyOnWrite();
        instance.clearData();
        return this;
      }

      /**
       * <pre>
       * The native width of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 width_px = 2;</code>
       * @return The widthPx.
       */
      @java.lang.Override
      public int getWidthPx() {
        return instance.getWidthPx();
      }
      /**
       * <pre>
       * The native width of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 width_px = 2;</code>
       * @param value The widthPx to set.
       * @return This builder for chaining.
       */
      public Builder setWidthPx(int value) {
        copyOnWrite();
        instance.setWidthPx(value);
        return this;
      }
      /**
       * <pre>
       * The native width of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 width_px = 2;</code>
       * @return This builder for chaining.
       */
      public Builder clearWidthPx() {
        copyOnWrite();
        instance.clearWidthPx();
        return this;
      }

      /**
       * <pre>
       * The native height of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 height_px = 3;</code>
       * @return The heightPx.
       */
      @java.lang.Override
      public int getHeightPx() {
        return instance.getHeightPx();
      }
      /**
       * <pre>
       * The native height of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 height_px = 3;</code>
       * @param value The heightPx to set.
       * @return This builder for chaining.
       */
      public Builder setHeightPx(int value) {
        copyOnWrite();
        instance.setHeightPx(value);
        return this;
      }
      /**
       * <pre>
       * The native height of the image, in pixels. Only required for formats
       * (e.g. IMAGE_FORMAT_RGB_565) where the image data does not include size.
       * </pre>
       *
       * <code>int32 height_px = 3;</code>
       * @return This builder for chaining.
       */
      public Builder clearHeightPx() {
        copyOnWrite();
        instance.clearHeightPx();
        return this;
      }

      /**
       * <pre>
       * The format of the byte array data representing the image. May be left
       * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
       * will attempt to extract this from the raw image data. If the platform does
       * not support the format, the image will not be decoded or displayed.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
       * @return The enum numeric value on the wire for format.
       */
      @java.lang.Override
      public int getFormatValue() {
        return instance.getFormatValue();
      }
      /**
       * <pre>
       * The format of the byte array data representing the image. May be left
       * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
       * will attempt to extract this from the raw image data. If the platform does
       * not support the format, the image will not be decoded or displayed.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
       * @param value The format to set.
       * @return This builder for chaining.
       */
      public Builder setFormatValue(int value) {
        copyOnWrite();
        instance.setFormatValue(value);
        return this;
      }
      /**
       * <pre>
       * The format of the byte array data representing the image. May be left
       * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
       * will attempt to extract this from the raw image data. If the platform does
       * not support the format, the image will not be decoded or displayed.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
       * @return The format.
       */
      @java.lang.Override
      public androidx.wear.protolayout.proto.ResourceProto.ImageFormat getFormat() {
        return instance.getFormat();
      }
      /**
       * <pre>
       * The format of the byte array data representing the image. May be left
       * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
       * will attempt to extract this from the raw image data. If the platform does
       * not support the format, the image will not be decoded or displayed.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
       * @param value The enum numeric value on the wire for format to set.
       * @return This builder for chaining.
       */
      public Builder setFormat(androidx.wear.protolayout.proto.ResourceProto.ImageFormat value) {
        copyOnWrite();
        instance.setFormat(value);
        return this;
      }
      /**
       * <pre>
       * The format of the byte array data representing the image. May be left
       * unspecified or set to IMAGE_FORMAT_UNDEFINED in which case the platform
       * will attempt to extract this from the raw image data. If the platform does
       * not support the format, the image will not be decoded or displayed.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.ImageFormat format = 4;</code>
       * @return This builder for chaining.
       */
      public Builder clearFormat() {
        copyOnWrite();
        instance.clearFormat();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:androidx.wear.protolayout.proto.InlineImageResource)
    }
    @java.lang.Override
    @java.lang.SuppressWarnings({"unchecked", "fallthrough"})
    protected final java.lang.Object dynamicMethod(
        com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
        java.lang.Object arg0, java.lang.Object arg1) {
      switch (method) {
        case NEW_MUTABLE_INSTANCE: {
          return new androidx.wear.protolayout.proto.ResourceProto.InlineImageResource();
        }
        case NEW_BUILDER: {
          return new Builder();
        }
        case BUILD_MESSAGE_INFO: {
            java.lang.Object[] objects = new java.lang.Object[] {
              "data_",
              "widthPx_",
              "heightPx_",
              "format_",
            };
            java.lang.String info =
                "\u0000\u0004\u0000\u0000\u0001\u0004\u0004\u0000\u0000\u0000\u0001\n\u0002\u0004" +
                "\u0003\u0004\u0004\f";
            return newMessageInfo(DEFAULT_INSTANCE, info, objects);
        }
        // fall through
        case GET_DEFAULT_INSTANCE: {
          return DEFAULT_INSTANCE;
        }
        case GET_PARSER: {
          com.google.protobuf.Parser<androidx.wear.protolayout.proto.ResourceProto.InlineImageResource> parser = PARSER;
          if (parser == null) {
            synchronized (androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.class) {
              parser = PARSER;
              if (parser == null) {
                parser =
                    new DefaultInstanceBasedParser<androidx.wear.protolayout.proto.ResourceProto.InlineImageResource>(
                        DEFAULT_INSTANCE);
                PARSER = parser;
              }
            }
          }
          return parser;
      }
      case GET_MEMOIZED_IS_INITIALIZED: {
        return (byte) 1;
      }
      case SET_MEMOIZED_IS_INITIALIZED: {
        return null;
      }
      }
      throw new UnsupportedOperationException();
    }


    // @@protoc_insertion_point(class_scope:androidx.wear.protolayout.proto.InlineImageResource)
    private static final androidx.wear.protolayout.proto.ResourceProto.InlineImageResource DEFAULT_INSTANCE;
    static {
      InlineImageResource defaultInstance = new InlineImageResource();
      // New instances are implicitly immutable so no need to make
      // immutable.
      DEFAULT_INSTANCE = defaultInstance;
      com.google.protobuf.GeneratedMessageLite.registerDefaultInstance(
        InlineImageResource.class, defaultInstance);
    }

    public static androidx.wear.protolayout.proto.ResourceProto.InlineImageResource getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static volatile com.google.protobuf.Parser<InlineImageResource> PARSER;

    public static com.google.protobuf.Parser<InlineImageResource> parser() {
      return DEFAULT_INSTANCE.getParserForType();
    }
  }

  public interface ImageResourceOrBuilder extends
      // @@protoc_insertion_point(interface_extends:androidx.wear.protolayout.proto.ImageResource)
      com.google.protobuf.MessageLiteOrBuilder {

    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     * @return Whether the androidResourceByResId field is set.
     */
    boolean hasAndroidResourceByResId();
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     * @return The androidResourceByResId.
     */
    androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId getAndroidResourceByResId();

    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     * @return Whether the inlineResource field is set.
     */
    boolean hasInlineResource();
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     * @return The inlineResource.
     */
    androidx.wear.protolayout.proto.ResourceProto.InlineImageResource getInlineResource();
  }
  /**
   * <pre>
   * An image resource, which can be used by layouts. This holds multiple
   * underlying resource types, which the underlying runtime will pick according
   * to what it thinks is appropriate.
   * </pre>
   *
   * Protobuf type {@code androidx.wear.protolayout.proto.ImageResource}
   */
  public  static final class ImageResource extends
      com.google.protobuf.GeneratedMessageLite<
          ImageResource, ImageResource.Builder> implements
      // @@protoc_insertion_point(message_implements:androidx.wear.protolayout.proto.ImageResource)
      ImageResourceOrBuilder {
    private ImageResource() {
    }
    public static final int ANDROID_RESOURCE_BY_RES_ID_FIELD_NUMBER = 1;
    private androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId androidResourceByResId_;
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     */
    @java.lang.Override
    public boolean hasAndroidResourceByResId() {
      return androidResourceByResId_ != null;
    }
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     */
    @java.lang.Override
    public androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId getAndroidResourceByResId() {
      return androidResourceByResId_ == null ? androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.getDefaultInstance() : androidResourceByResId_;
    }
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     */
    private void setAndroidResourceByResId(androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId value) {
      value.getClass();
  androidResourceByResId_ = value;
      
      }
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     */
    @java.lang.SuppressWarnings({"ReferenceEquality"})
    private void mergeAndroidResourceByResId(androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId value) {
      value.getClass();
  if (androidResourceByResId_ != null &&
          androidResourceByResId_ != androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.getDefaultInstance()) {
        androidResourceByResId_ =
          androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.newBuilder(androidResourceByResId_).mergeFrom(value).buildPartial();
      } else {
        androidResourceByResId_ = value;
      }
      
    }
    /**
     * <pre>
     * An image resource that maps to an Android drawable by resource ID.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
     */
    private void clearAndroidResourceByResId() {  androidResourceByResId_ = null;
      
    }

    public static final int INLINE_RESOURCE_FIELD_NUMBER = 2;
    private androidx.wear.protolayout.proto.ResourceProto.InlineImageResource inlineResource_;
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     */
    @java.lang.Override
    public boolean hasInlineResource() {
      return inlineResource_ != null;
    }
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     */
    @java.lang.Override
    public androidx.wear.protolayout.proto.ResourceProto.InlineImageResource getInlineResource() {
      return inlineResource_ == null ? androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.getDefaultInstance() : inlineResource_;
    }
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     */
    private void setInlineResource(androidx.wear.protolayout.proto.ResourceProto.InlineImageResource value) {
      value.getClass();
  inlineResource_ = value;
      
      }
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     */
    @java.lang.SuppressWarnings({"ReferenceEquality"})
    private void mergeInlineResource(androidx.wear.protolayout.proto.ResourceProto.InlineImageResource value) {
      value.getClass();
  if (inlineResource_ != null &&
          inlineResource_ != androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.getDefaultInstance()) {
        inlineResource_ =
          androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.newBuilder(inlineResource_).mergeFrom(value).buildPartial();
      } else {
        inlineResource_ = value;
      }
      
    }
    /**
     * <pre>
     * An image resource that contains the image data inline.
     * </pre>
     *
     * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
     */
    private void clearInlineResource() {  inlineResource_ = null;
      
    }

    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }

    public static Builder newBuilder() {
      return (Builder) DEFAULT_INSTANCE.createBuilder();
    }
    public static Builder newBuilder(androidx.wear.protolayout.proto.ResourceProto.ImageResource prototype) {
      return (Builder) DEFAULT_INSTANCE.createBuilder(prototype);
    }

    /**
     * <pre>
     * An image resource, which can be used by layouts. This holds multiple
     * underlying resource types, which the underlying runtime will pick according
     * to what it thinks is appropriate.
     * </pre>
     *
     * Protobuf type {@code androidx.wear.protolayout.proto.ImageResource}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageLite.Builder<
          androidx.wear.protolayout.proto.ResourceProto.ImageResource, Builder> implements
        // @@protoc_insertion_point(builder_implements:androidx.wear.protolayout.proto.ImageResource)
        androidx.wear.protolayout.proto.ResourceProto.ImageResourceOrBuilder {
      // Construct using androidx.wear.protolayout.proto.ResourceProto.ImageResource.newBuilder()
      private Builder() {
        super(DEFAULT_INSTANCE);
      }


      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      @java.lang.Override
      public boolean hasAndroidResourceByResId() {
        return instance.hasAndroidResourceByResId();
      }
      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      @java.lang.Override
      public androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId getAndroidResourceByResId() {
        return instance.getAndroidResourceByResId();
      }
      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      public Builder setAndroidResourceByResId(androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId value) {
        copyOnWrite();
        instance.setAndroidResourceByResId(value);
        return this;
        }
      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      public Builder setAndroidResourceByResId(
          androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId.Builder builderForValue) {
        copyOnWrite();
        instance.setAndroidResourceByResId(builderForValue.build());
        return this;
      }
      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      public Builder mergeAndroidResourceByResId(androidx.wear.protolayout.proto.ResourceProto.AndroidImageResourceByResId value) {
        copyOnWrite();
        instance.mergeAndroidResourceByResId(value);
        return this;
      }
      /**
       * <pre>
       * An image resource that maps to an Android drawable by resource ID.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.AndroidImageResourceByResId android_resource_by_res_id = 1;</code>
       */
      public Builder clearAndroidResourceByResId() {  copyOnWrite();
        instance.clearAndroidResourceByResId();
        return this;
      }

      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      @java.lang.Override
      public boolean hasInlineResource() {
        return instance.hasInlineResource();
      }
      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      @java.lang.Override
      public androidx.wear.protolayout.proto.ResourceProto.InlineImageResource getInlineResource() {
        return instance.getInlineResource();
      }
      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      public Builder setInlineResource(androidx.wear.protolayout.proto.ResourceProto.InlineImageResource value) {
        copyOnWrite();
        instance.setInlineResource(value);
        return this;
        }
      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      public Builder setInlineResource(
          androidx.wear.protolayout.proto.ResourceProto.InlineImageResource.Builder builderForValue) {
        copyOnWrite();
        instance.setInlineResource(builderForValue.build());
        return this;
      }
      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      public Builder mergeInlineResource(androidx.wear.protolayout.proto.ResourceProto.InlineImageResource value) {
        copyOnWrite();
        instance.mergeInlineResource(value);
        return this;
      }
      /**
       * <pre>
       * An image resource that contains the image data inline.
       * </pre>
       *
       * <code>.androidx.wear.protolayout.proto.InlineImageResource inline_resource = 2;</code>
       */
      public Builder clearInlineResource() {  copyOnWrite();
        instance.clearInlineResource();
        return this;
      }

      // @@protoc_insertion_point(builder_scope:androidx.wear.protolayout.proto.ImageResource)
    }
    @java.lang.Override
    @java.lang.SuppressWarnings({"unchecked", "fallthrough"})
    protected final java.lang.Object dynamicMethod(
        com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
        java.lang.Object arg0, java.lang.Object arg1) {
      switch (method) {
        case NEW_MUTABLE_INSTANCE: {
          return new androidx.wear.protolayout.proto.ResourceProto.ImageResource();
        }
        case NEW_BUILDER: {
          return new Builder();
        }
        case BUILD_MESSAGE_INFO: {
            java.lang.Object[] objects = new java.lang.Object[] {
              "androidResourceByResId_",
              "inlineResource_",
            };
            java.lang.String info =
                "\u0000\u0002\u0000\u0000\u0001\u0002\u0002\u0000\u0000\u0000\u0001\t\u0002\t";
            return newMessageInfo(DEFAULT_INSTANCE, info, objects);
        }
        // fall through
        case GET_DEFAULT_INSTANCE: {
          return DEFAULT_INSTANCE;
        }
        case GET_PARSER: {
          com.google.protobuf.Parser<androidx.wear.protolayout.proto.ResourceProto.ImageResource> parser = PARSER;
          if (parser == null) {
            synchronized (androidx.wear.protolayout.proto.ResourceProto.ImageResource.class) {
              parser = PARSER;
              if (parser == null) {
                parser =
                    new DefaultInstanceBasedParser<androidx.wear.protolayout.proto.ResourceProto.ImageResource>(
                        DEFAULT_INSTANCE);
                PARSER = parser;
              }
            }
          }
          return parser;
      }
      case GET_MEMOIZED_IS_INITIALIZED: {
        return (byte) 1;
      }
      case SET_MEMOIZED_IS_INITIALIZED: {
        return null;
      }
      }
      throw new UnsupportedOperationException();
    }


    // @@protoc_insertion_point(class_scope:androidx.wear.protolayout.proto.ImageResource)
    private static final androidx.wear.protolayout.proto.ResourceProto.ImageResource DEFAULT_INSTANCE;
    static {
      ImageResource defaultInstance = new ImageResource();
      // New instances are implicitly immutable so no need to make
      // immutable.
      DEFAULT_INSTANCE = defaultInstance;
      com.google.protobuf.GeneratedMessageLite.registerDefaultInstance(
        ImageResource.class, defaultInstance);
    }

    public static androidx.wear.protolayout.proto.ResourceProto.ImageResource getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static volatile com.google.protobuf.Parser<ImageResource> PARSER;

    public static com.google.protobuf.Parser<ImageResource> parser() {
      return DEFAULT_INSTANCE.getParserForType();
    }
  }

  public interface ResourcesOrBuilder extends
      // @@protoc_insertion_point(interface_extends:androidx.wear.protolayout.proto.Resources)
      com.google.protobuf.MessageLiteOrBuilder {

    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @return The version.
     */
    java.lang.String getVersion();
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @return The bytes for version.
     */
    com.google.protobuf.ByteString
        getVersionBytes();

    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    int getIdToImageCount();
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    boolean containsIdToImage(
        java.lang.String key);
    /**
     * Use {@link #getIdToImageMap()} instead.
     */
    @java.lang.Deprecated
    java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>
    getIdToImage();
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>
    getIdToImageMap();
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */

    /* nullable */
androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrDefault(
        java.lang.String key,
        /* nullable */
androidx.wear.protolayout.proto.ResourceProto.ImageResource defaultValue);
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */

    androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrThrow(
        java.lang.String key);
  }
  /**
   * <pre>
   * The resources for a layout.
   * </pre>
   *
   * Protobuf type {@code androidx.wear.protolayout.proto.Resources}
   */
  public  static final class Resources extends
      com.google.protobuf.GeneratedMessageLite<
          Resources, Resources.Builder> implements
      // @@protoc_insertion_point(message_implements:androidx.wear.protolayout.proto.Resources)
      ResourcesOrBuilder {
    private Resources() {
      version_ = "";
    }
    public static final int VERSION_FIELD_NUMBER = 1;
    private java.lang.String version_;
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @return The version.
     */
    @java.lang.Override
    public java.lang.String getVersion() {
      return version_;
    }
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @return The bytes for version.
     */
    @java.lang.Override
    public com.google.protobuf.ByteString
        getVersionBytes() {
      return com.google.protobuf.ByteString.copyFromUtf8(version_);
    }
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @param value The version to set.
     */
    private void setVersion(
        java.lang.String value) {
      java.lang.Class<?> valueClass = value.getClass();
  
      version_ = value;
    }
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     */
    private void clearVersion() {
      
      version_ = getDefaultInstance().getVersion();
    }
    /**
     * <pre>
     * The version of this Resources instance.
     * Each tile specifies the version of resources it requires. After fetching a
     * tile, the renderer will use the resources version specified by the tile
     * to separately fetch the resources.
     * This value must match the version of the resources required by the tile
     * for the tile to render successfully, and must match the resource version
     * specified in ResourcesRequest which triggered this request.
     * </pre>
     *
     * <code>string version = 1;</code>
     * @param value The bytes for version to set.
     */
    private void setVersionBytes(
        com.google.protobuf.ByteString value) {
      checkByteStringIsUtf8(value);
      version_ = value.toStringUtf8();
      
    }

    public static final int ID_TO_IMAGE_FIELD_NUMBER = 2;
    private static final class IdToImageDefaultEntryHolder {
      static final com.google.protobuf.MapEntryLite<
          java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> defaultEntry =
              com.google.protobuf.MapEntryLite
              .<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>newDefaultInstance(
                  com.google.protobuf.WireFormat.FieldType.STRING,
                  "",
                  com.google.protobuf.WireFormat.FieldType.MESSAGE,
                  androidx.wear.protolayout.proto.ResourceProto.ImageResource.getDefaultInstance());
    }
    private com.google.protobuf.MapFieldLite<
        java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> idToImage_ =
            com.google.protobuf.MapFieldLite.emptyMapField();
    private com.google.protobuf.MapFieldLite<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>
    internalGetIdToImage() {
      return idToImage_;
    }
    private com.google.protobuf.MapFieldLite<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>
    internalGetMutableIdToImage() {
      if (!idToImage_.isMutable()) {
        idToImage_ = idToImage_.mutableCopy();
      }
      return idToImage_;
    }
    @java.lang.Override

    public int getIdToImageCount() {
      return internalGetIdToImage().size();
    }
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    @java.lang.Override

    public boolean containsIdToImage(
        java.lang.String key) {
      java.lang.Class<?> keyClass = key.getClass();
      return internalGetIdToImage().containsKey(key);
    }
    /**
     * Use {@link #getIdToImageMap()} instead.
     */
    @java.lang.Override
    @java.lang.Deprecated
    public java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> getIdToImage() {
      return getIdToImageMap();
    }
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    @java.lang.Override

    public java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> getIdToImageMap() {
      return java.util.Collections.unmodifiableMap(
          internalGetIdToImage());
    }
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    @java.lang.Override

    public androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrDefault(
        java.lang.String key,
        androidx.wear.protolayout.proto.ResourceProto.ImageResource defaultValue) {
      java.lang.Class<?> keyClass = key.getClass();
      java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> map =
          internalGetIdToImage();
      return map.containsKey(key) ? map.get(key) : defaultValue;
    }
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    @java.lang.Override

    public androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrThrow(
        java.lang.String key) {
      java.lang.Class<?> keyClass = key.getClass();
      java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> map =
          internalGetIdToImage();
      if (!map.containsKey(key)) {
        throw new java.lang.IllegalArgumentException();
      }
      return map.get(key);
    }
    /**
     * <pre>
     * A map of resource_ids to images, which can be used by layouts.
     * </pre>
     *
     * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
     */
    private java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource>
    getMutableIdToImageMap() {
      return internalGetMutableIdToImage();
    }

    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        java.nio.ByteBuffer data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        java.nio.ByteBuffer data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        com.google.protobuf.ByteString data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        com.google.protobuf.ByteString data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(byte[] data)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        byte[] data,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws com.google.protobuf.InvalidProtocolBufferException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, data, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(java.io.InputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseDelimitedFrom(java.io.InputStream input)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseDelimitedFrom(
        java.io.InputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return parseDelimitedFrom(DEFAULT_INSTANCE, input, extensionRegistry);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        com.google.protobuf.CodedInputStream input)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input);
    }
    public static androidx.wear.protolayout.proto.ResourceProto.Resources parseFrom(
        com.google.protobuf.CodedInputStream input,
        com.google.protobuf.ExtensionRegistryLite extensionRegistry)
        throws java.io.IOException {
      return com.google.protobuf.GeneratedMessageLite.parseFrom(
          DEFAULT_INSTANCE, input, extensionRegistry);
    }

    public static Builder newBuilder() {
      return (Builder) DEFAULT_INSTANCE.createBuilder();
    }
    public static Builder newBuilder(androidx.wear.protolayout.proto.ResourceProto.Resources prototype) {
      return (Builder) DEFAULT_INSTANCE.createBuilder(prototype);
    }

    /**
     * <pre>
     * The resources for a layout.
     * </pre>
     *
     * Protobuf type {@code androidx.wear.protolayout.proto.Resources}
     */
    public static final class Builder extends
        com.google.protobuf.GeneratedMessageLite.Builder<
          androidx.wear.protolayout.proto.ResourceProto.Resources, Builder> implements
        // @@protoc_insertion_point(builder_implements:androidx.wear.protolayout.proto.Resources)
        androidx.wear.protolayout.proto.ResourceProto.ResourcesOrBuilder {
      // Construct using androidx.wear.protolayout.proto.ResourceProto.Resources.newBuilder()
      private Builder() {
        super(DEFAULT_INSTANCE);
      }


      /**
       * <pre>
       * The version of this Resources instance.
       * Each tile specifies the version of resources it requires. After fetching a
       * tile, the renderer will use the resources version specified by the tile
       * to separately fetch the resources.
       * This value must match the version of the resources required by the tile
       * for the tile to render successfully, and must match the resource version
       * specified in ResourcesRequest which triggered this request.
       * </pre>
       *
       * <code>string version = 1;</code>
       * @return The version.
       */
      @java.lang.Override
      public java.lang.String getVersion() {
        return instance.getVersion();
      }
      /**
       * <pre>
       * The version of this Resources instance.
       * Each tile specifies the version of resources it requires. After fetching a
       * tile, the renderer will use the resources version specified by the tile
       * to separately fetch the resources.
       * This value must match the version of the resources required by the tile
       * for the tile to render successfully, and must match the resource version
       * specified in ResourcesRequest which triggered this request.
       * </pre>
       *
       * <code>string version = 1;</code>
       * @return The bytes for version.
       */
      @java.lang.Override
      public com.google.protobuf.ByteString
          getVersionBytes() {
        return instance.getVersionBytes();
      }
      /**
       * <pre>
       * The version of this Resources instance.
       * Each tile specifies the version of resources it requires. After fetching a
       * tile, the renderer will use the resources version specified by the tile
       * to separately fetch the resources.
       * This value must match the version of the resources required by the tile
       * for the tile to render successfully, and must match the resource version
       * specified in ResourcesRequest which triggered this request.
       * </pre>
       *
       * <code>string version = 1;</code>
       * @param value The version to set.
       * @return This builder for chaining.
       */
      public Builder setVersion(
          java.lang.String value) {
        copyOnWrite();
        instance.setVersion(value);
        return this;
      }
      /**
       * <pre>
       * The version of this Resources instance.
       * Each tile specifies the version of resources it requires. After fetching a
       * tile, the renderer will use the resources version specified by the tile
       * to separately fetch the resources.
       * This value must match the version of the resources required by the tile
       * for the tile to render successfully, and must match the resource version
       * specified in ResourcesRequest which triggered this request.
       * </pre>
       *
       * <code>string version = 1;</code>
       * @return This builder for chaining.
       */
      public Builder clearVersion() {
        copyOnWrite();
        instance.clearVersion();
        return this;
      }
      /**
       * <pre>
       * The version of this Resources instance.
       * Each tile specifies the version of resources it requires. After fetching a
       * tile, the renderer will use the resources version specified by the tile
       * to separately fetch the resources.
       * This value must match the version of the resources required by the tile
       * for the tile to render successfully, and must match the resource version
       * specified in ResourcesRequest which triggered this request.
       * </pre>
       *
       * <code>string version = 1;</code>
       * @param value The bytes for version to set.
       * @return This builder for chaining.
       */
      public Builder setVersionBytes(
          com.google.protobuf.ByteString value) {
        copyOnWrite();
        instance.setVersionBytes(value);
        return this;
      }

      @java.lang.Override

      public int getIdToImageCount() {
        return instance.getIdToImageMap().size();
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      @java.lang.Override

      public boolean containsIdToImage(
          java.lang.String key) {
        java.lang.Class<?> keyClass = key.getClass();
        return instance.getIdToImageMap().containsKey(key);
      }

      public Builder clearIdToImage() {
        copyOnWrite();
        instance.getMutableIdToImageMap().clear();
        return this;
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */

      public Builder removeIdToImage(
          java.lang.String key) {
        java.lang.Class<?> keyClass = key.getClass();
        copyOnWrite();
        instance.getMutableIdToImageMap().remove(key);
        return this;
      }
      /**
       * Use {@link #getIdToImageMap()} instead.
       */
      @java.lang.Override
      @java.lang.Deprecated
      public java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> getIdToImage() {
        return getIdToImageMap();
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      @java.lang.Override
      public java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> getIdToImageMap() {
        return java.util.Collections.unmodifiableMap(
            instance.getIdToImageMap());
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      @java.lang.Override

      public androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrDefault(
          java.lang.String key,
          androidx.wear.protolayout.proto.ResourceProto.ImageResource defaultValue) {
        java.lang.Class<?> keyClass = key.getClass();
        java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> map =
            instance.getIdToImageMap();
        return map.containsKey(key) ? map.get(key) : defaultValue;
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      @java.lang.Override

      public androidx.wear.protolayout.proto.ResourceProto.ImageResource getIdToImageOrThrow(
          java.lang.String key) {
        java.lang.Class<?> keyClass = key.getClass();
        java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> map =
            instance.getIdToImageMap();
        if (!map.containsKey(key)) {
          throw new java.lang.IllegalArgumentException();
        }
        return map.get(key);
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      public Builder putIdToImage(
          java.lang.String key,
          androidx.wear.protolayout.proto.ResourceProto.ImageResource value) {
        java.lang.Class<?> keyClass = key.getClass();
        java.lang.Class<?> valueClass = value.getClass();
        copyOnWrite();
        instance.getMutableIdToImageMap().put(key, value);
        return this;
      }
      /**
       * <pre>
       * A map of resource_ids to images, which can be used by layouts.
       * </pre>
       *
       * <code>map&lt;string, .androidx.wear.protolayout.proto.ImageResource&gt; id_to_image = 2;</code>
       */
      public Builder putAllIdToImage(
          java.util.Map<java.lang.String, androidx.wear.protolayout.proto.ResourceProto.ImageResource> values) {
        copyOnWrite();
        instance.getMutableIdToImageMap().putAll(values);
        return this;
      }

      // @@protoc_insertion_point(builder_scope:androidx.wear.protolayout.proto.Resources)
    }
    @java.lang.Override
    @java.lang.SuppressWarnings({"unchecked", "fallthrough"})
    protected final java.lang.Object dynamicMethod(
        com.google.protobuf.GeneratedMessageLite.MethodToInvoke method,
        java.lang.Object arg0, java.lang.Object arg1) {
      switch (method) {
        case NEW_MUTABLE_INSTANCE: {
          return new androidx.wear.protolayout.proto.ResourceProto.Resources();
        }
        case NEW_BUILDER: {
          return new Builder();
        }
        case BUILD_MESSAGE_INFO: {
            java.lang.Object[] objects = new java.lang.Object[] {
              "version_",
              "idToImage_",
              IdToImageDefaultEntryHolder.defaultEntry,
            };
            java.lang.String info =
                "\u0000\u0002\u0000\u0000\u0001\u0002\u0002\u0001\u0000\u0000\u0001\u0208\u00022";
            return newMessageInfo(DEFAULT_INSTANCE, info, objects);
        }
        // fall through
        case GET_DEFAULT_INSTANCE: {
          return DEFAULT_INSTANCE;
        }
        case GET_PARSER: {
          com.google.protobuf.Parser<androidx.wear.protolayout.proto.ResourceProto.Resources> parser = PARSER;
          if (parser == null) {
            synchronized (androidx.wear.protolayout.proto.ResourceProto.Resources.class) {
              parser = PARSER;
              if (parser == null) {
                parser =
                    new DefaultInstanceBasedParser<androidx.wear.protolayout.proto.ResourceProto.Resources>(
                        DEFAULT_INSTANCE);
                PARSER = parser;
              }
            }
          }
          return parser;
      }
      case GET_MEMOIZED_IS_INITIALIZED: {
        return (byte) 1;
      }
      case SET_MEMOIZED_IS_INITIALIZED: {
        return null;
      }
      }
      throw new UnsupportedOperationException();
    }


    // @@protoc_insertion_point(class_scope:androidx.wear.protolayout.proto.Resources)
    private static final androidx.wear.protolayout.proto.ResourceProto.Resources DEFAULT_INSTANCE;
    static {
      Resources defaultInstance = new Resources();
      // New instances are implicitly immutable so no need to make
      // immutable.
      DEFAULT_INSTANCE = defaultInstance;
      com.google.protobuf.GeneratedMessageLite.registerDefaultInstance(
        Resources.class, defaultInstance);
    }

    public static androidx.wear.protolayout.proto.ResourceProto.Resources getDefaultInstance() {
      return DEFAULT_INSTANCE;
    }

    private static volatile com.google.protobuf.Parser<Resources> PARSER;

    public static com.google.protobuf.Parser<Resources> parser() {
      return DEFAULT_INSTANCE.getParserForType();
    }
  }


  static {
  }

  // @@protoc_insertion_point(outer_class_scope)
}