public final class

ResourceProto.HttpImageResource

extends <any>

implements ResourceProto.HttpImageResourceOrBuilder

 java.lang.Object

↳<any>

↳androidx.wear.protolayout.proto.ResourceProto.HttpImageResource

Overview

 An image to be loaded from an HTTP source. May not be supported on all
 platforms.
 
Protobuf type androidx.wear.protolayout.proto.HttpImageResource

Summary

Fields
public static final intFORMAT_FIELD_NUMBER

public static final intHEIGHT_PX_FIELD_NUMBER

public static final intPLACEHOLDER_IMAGE_RESOURCE_ID_FIELD_NUMBER

public static final intURL_FIELD_NUMBER

public static final intWIDTH_PX_FIELD_NUMBER

Methods
protected final java.lang.ObjectdynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, java.lang.Object arg0, java.lang.Object arg1)

public static ResourceProto.HttpImageResourcegetDefaultInstance()

public ResourceProto.ImageFormatgetFormat()

 The format of the image to be fetched.

public intgetFormatValue()

 The format of the image to be fetched.

public intgetHeightPx()

 The native height of the image, in pixels.

public java.lang.StringgetPlaceholderImageResourceId()

 Resource ID to look up in Resources#id_to_image to provide a placeholder
 image.

public com.google.protobuf.ByteStringgetPlaceholderImageResourceIdBytes()

 Resource ID to look up in Resources#id_to_image to provide a placeholder
 image.

public java.lang.StringgetUrl()

 The URL from which the image will be fetched.

public com.google.protobuf.ByteStringgetUrlBytes()

 The URL from which the image will be fetched.

public intgetWidthPx()

 The native width of the image, in pixels.

public static ResourceProto.HttpImageResource.BuildernewBuilder()

public static ResourceProto.HttpImageResource.BuildernewBuilder(ResourceProto.HttpImageResource prototype)

public static ResourceProto.HttpImageResourceparseDelimitedFrom(java.io.InputStream input)

public static ResourceProto.HttpImageResourceparseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResourceparseFrom(byte[] data[], com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResourceparseFrom(java.nio.ByteBuffer data)

public static ResourceProto.HttpImageResourceparseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResourceparseFrom(com.google.protobuf.ByteString data)

public static ResourceProto.HttpImageResourceparseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResourceparseFrom(com.google.protobuf.CodedInputStream input)

public static ResourceProto.HttpImageResourceparseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResourceparseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static <any>parser()

from java.lang.Objectclone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Fields

public static final int URL_FIELD_NUMBER

public static final int WIDTH_PX_FIELD_NUMBER

public static final int HEIGHT_PX_FIELD_NUMBER

public static final int FORMAT_FIELD_NUMBER

public static final int PLACEHOLDER_IMAGE_RESOURCE_ID_FIELD_NUMBER

Methods

public java.lang.String getUrl()

 The URL from which the image will be fetched.
 
string url = 1;

Returns:

The url.

public com.google.protobuf.ByteString getUrlBytes()

 The URL from which the image will be fetched.
 
string url = 1;

Returns:

The bytes for url.

public int getWidthPx()

 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.
 
int32 width_px = 2;

Returns:

The widthPx.

public int getHeightPx()

 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.
 
int32 height_px = 3;

Returns:

The heightPx.

public int getFormatValue()

 The format of the image to be fetched. 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.
 
.androidx.wear.protolayout.proto.ImageFormat format = 4;

Returns:

The enum numeric value on the wire for format.

public ResourceProto.ImageFormat getFormat()

 The format of the image to be fetched. 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.
 
.androidx.wear.protolayout.proto.ImageFormat format = 4;

Returns:

The format.

public java.lang.String getPlaceholderImageResourceId()

 Resource ID to look up in Resources#id_to_image to provide a placeholder
 image. The placeholder image will be drawn in the Image or SpanImage
 element which references this resource while the HTTP image is loading.
 Note that this must not point to another HttpImageResource; it should point
 to an image resource which can be immediately loaded.

 If this is empty, no placeholder image will be used (i.e. the Image or
 SpanImage will remain transparent until the image has loaded).
 
string placeholder_image_resource_id = 5;

Returns:

The placeholderImageResourceId.

public com.google.protobuf.ByteString getPlaceholderImageResourceIdBytes()

 Resource ID to look up in Resources#id_to_image to provide a placeholder
 image. The placeholder image will be drawn in the Image or SpanImage
 element which references this resource while the HTTP image is loading.
 Note that this must not point to another HttpImageResource; it should point
 to an image resource which can be immediately loaded.

 If this is empty, no placeholder image will be used (i.e. the Image or
 SpanImage will remain transparent until the image has loaded).
 
string placeholder_image_resource_id = 5;

Returns:

The bytes for placeholderImageResourceId.

public static ResourceProto.HttpImageResource parseFrom(java.nio.ByteBuffer data)

public static ResourceProto.HttpImageResource parseFrom(java.nio.ByteBuffer data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource parseFrom(com.google.protobuf.ByteString data)

public static ResourceProto.HttpImageResource parseFrom(com.google.protobuf.ByteString data, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource parseFrom(byte[] data[], com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource parseFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource parseDelimitedFrom(java.io.InputStream input)

public static ResourceProto.HttpImageResource parseDelimitedFrom(java.io.InputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource parseFrom(com.google.protobuf.CodedInputStream input)

public static ResourceProto.HttpImageResource parseFrom(com.google.protobuf.CodedInputStream input, com.google.protobuf.ExtensionRegistryLite extensionRegistry)

public static ResourceProto.HttpImageResource.Builder newBuilder()

protected final java.lang.Object dynamicMethod(com.google.protobuf.GeneratedMessageLite.MethodToInvoke method, java.lang.Object arg0, java.lang.Object arg1)

public static ResourceProto.HttpImageResource getDefaultInstance()

public static <any> parser()