Class ByteStreamProto.ReadRequest.Builder

java.lang.Object
com.google.protobuf.AbstractMessageLite.Builder<MessageType,BuilderType>
com.google.protobuf.GeneratedMessageLite.Builder<ByteStreamProto.ReadRequest,ByteStreamProto.ReadRequest.Builder>
com.google.bytestream.ByteStreamProto.ReadRequest.Builder
All Implemented Interfaces:
ByteStreamProto.ReadRequestOrBuilder, com.google.protobuf.MessageLite.Builder, com.google.protobuf.MessageLiteOrBuilder, Cloneable
Enclosing class:
ByteStreamProto.ReadRequest

public static final class ByteStreamProto.ReadRequest.Builder extends com.google.protobuf.GeneratedMessageLite.Builder<ByteStreamProto.ReadRequest,ByteStreamProto.ReadRequest.Builder> implements ByteStreamProto.ReadRequestOrBuilder
 Request object for ByteStream.Read.
 
Protobuf type google.bytestream.ReadRequest
  • Method Details

    • getResourceName

      public String getResourceName()
       The name of the resource to read.
       
      string resource_name = 1 [json_name = "resourceName"];
      Specified by:
      getResourceName in interface ByteStreamProto.ReadRequestOrBuilder
      Returns:
      The resourceName.
    • getResourceNameBytes

      public com.google.protobuf.ByteString getResourceNameBytes()
       The name of the resource to read.
       
      string resource_name = 1 [json_name = "resourceName"];
      Specified by:
      getResourceNameBytes in interface ByteStreamProto.ReadRequestOrBuilder
      Returns:
      The bytes for resourceName.
    • setResourceName

      public ByteStreamProto.ReadRequest.Builder setResourceName(String value)
       The name of the resource to read.
       
      string resource_name = 1 [json_name = "resourceName"];
      Parameters:
      value - The resourceName to set.
      Returns:
      This builder for chaining.
    • clearResourceName

      public ByteStreamProto.ReadRequest.Builder clearResourceName()
       The name of the resource to read.
       
      string resource_name = 1 [json_name = "resourceName"];
      Returns:
      This builder for chaining.
    • setResourceNameBytes

      public ByteStreamProto.ReadRequest.Builder setResourceNameBytes(com.google.protobuf.ByteString value)
       The name of the resource to read.
       
      string resource_name = 1 [json_name = "resourceName"];
      Parameters:
      value - The bytes for resourceName to set.
      Returns:
      This builder for chaining.
    • getReadOffset

      public long getReadOffset()
       The offset for the first byte to return in the read, relative to the start
       of the resource.
      
       A `read_offset` that is negative or greater than the size of the resource
       will cause an `OUT_OF_RANGE` error.
       
      int64 read_offset = 2 [json_name = "readOffset"];
      Specified by:
      getReadOffset in interface ByteStreamProto.ReadRequestOrBuilder
      Returns:
      The readOffset.
    • setReadOffset

      public ByteStreamProto.ReadRequest.Builder setReadOffset(long value)
       The offset for the first byte to return in the read, relative to the start
       of the resource.
      
       A `read_offset` that is negative or greater than the size of the resource
       will cause an `OUT_OF_RANGE` error.
       
      int64 read_offset = 2 [json_name = "readOffset"];
      Parameters:
      value - The readOffset to set.
      Returns:
      This builder for chaining.
    • clearReadOffset

      public ByteStreamProto.ReadRequest.Builder clearReadOffset()
       The offset for the first byte to return in the read, relative to the start
       of the resource.
      
       A `read_offset` that is negative or greater than the size of the resource
       will cause an `OUT_OF_RANGE` error.
       
      int64 read_offset = 2 [json_name = "readOffset"];
      Returns:
      This builder for chaining.
    • getReadLimit

      public long getReadLimit()
       The maximum number of `data` bytes the server is allowed to return in the
       sum of all `ReadResponse` messages. A `read_limit` of zero indicates that
       there is no limit, and a negative `read_limit` will cause an error.
      
       If the stream returns fewer bytes than allowed by the `read_limit` and no
       error occurred, the stream includes all data from the `read_offset` to the
       end of the resource.
       
      int64 read_limit = 3 [json_name = "readLimit"];
      Specified by:
      getReadLimit in interface ByteStreamProto.ReadRequestOrBuilder
      Returns:
      The readLimit.
    • setReadLimit

      public ByteStreamProto.ReadRequest.Builder setReadLimit(long value)
       The maximum number of `data` bytes the server is allowed to return in the
       sum of all `ReadResponse` messages. A `read_limit` of zero indicates that
       there is no limit, and a negative `read_limit` will cause an error.
      
       If the stream returns fewer bytes than allowed by the `read_limit` and no
       error occurred, the stream includes all data from the `read_offset` to the
       end of the resource.
       
      int64 read_limit = 3 [json_name = "readLimit"];
      Parameters:
      value - The readLimit to set.
      Returns:
      This builder for chaining.
    • clearReadLimit

      public ByteStreamProto.ReadRequest.Builder clearReadLimit()
       The maximum number of `data` bytes the server is allowed to return in the
       sum of all `ReadResponse` messages. A `read_limit` of zero indicates that
       there is no limit, and a negative `read_limit` will cause an error.
      
       If the stream returns fewer bytes than allowed by the `read_limit` and no
       error occurred, the stream includes all data from the `read_offset` to the
       end of the resource.
       
      int64 read_limit = 3 [json_name = "readLimit"];
      Returns:
      This builder for chaining.