Struct tikv_client_proto::coprocessor::Request [−][src]
pub struct Request { pub context: Option<Context>, pub tp: i64, pub data: Vec<u8>, pub start_ts: u64, pub ranges: Vec<KeyRange>, pub is_cache_enabled: bool, pub cache_if_match_version: u64, pub schema_ver: i64, pub is_trace_enabled: bool, }
Fields
context: Option<Context>
tp: i64
data: Vec<u8>
start_ts: u64
ranges: Vec<KeyRange>
is_cache_enabled: bool
Expand description
If cache is enabled, TiKV returns cache hit instead of data if
its last version matches this cache_if_match_version
.
cache_if_match_version: u64
schema_ver: i64
Expand description
Any schema-ful storage to validate schema correctness if necessary.
is_trace_enabled: bool
Implementations
impl Request
impl Request
pub fn new_() -> Request
pub fn default_ref() -> &'static Self
pub fn has_context(&self) -> bool
pub fn clear_context(&mut self)
pub fn set_context(&mut self, v: Context)
pub fn get_context(&self) -> &Context
pub fn mut_context(&mut self) -> &mut Context
pub fn take_context(&mut self) -> Context
pub fn clear_tp(&mut self)
pub fn set_tp(&mut self, v: i64)
pub fn get_tp(&self) -> i64
pub fn clear_data(&mut self)
pub fn set_data(&mut self, v: Vec<u8>)
pub fn get_data(&self) -> &[u8]
pub fn mut_data(&mut self) -> &mut Vec<u8>
pub fn take_data(&mut self) -> Vec<u8>
pub fn clear_start_ts(&mut self)
pub fn set_start_ts(&mut self, v: u64)
pub fn get_start_ts(&self) -> u64
pub fn clear_ranges(&mut self)
pub fn set_ranges(&mut self, v: Vec<KeyRange>)
pub fn get_ranges(&self) -> &[KeyRange]
pub fn mut_ranges(&mut self) -> &mut Vec<KeyRange>
pub fn take_ranges(&mut self) -> Vec<KeyRange>
pub fn clear_is_cache_enabled(&mut self)
pub fn set_is_cache_enabled(&mut self, v: bool)
pub fn get_is_cache_enabled(&self) -> bool
pub fn clear_cache_if_match_version(&mut self)
pub fn set_cache_if_match_version(&mut self, v: u64)
pub fn get_cache_if_match_version(&self) -> u64
pub fn clear_schema_ver(&mut self)
pub fn set_schema_ver(&mut self, v: i64)
pub fn get_schema_ver(&self) -> i64
pub fn clear_is_trace_enabled(&mut self)
pub fn set_is_trace_enabled(&mut self, v: bool)
pub fn get_is_trace_enabled(&self) -> bool
Trait Implementations
impl Clear for Request
impl Clear for Request
fn clear(&mut self)
fn clear(&mut self)
Clear this make, make it equivalent to newly created object.
impl Message for Request
[src]
impl Message for Request
[src]fn encode_raw<B>(&self, buf: &mut B) where
B: BufMut,
[src]
B: BufMut,
fn merge_field<B>(
&mut self,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext
) -> Result<(), DecodeError> where
B: Buf,
[src]
&mut self,
tag: u32,
wire_type: WireType,
buf: &mut B,
ctx: DecodeContext
) -> Result<(), DecodeError> where
B: Buf,
fn encoded_len(&self) -> usize
[src]
fn encoded_len(&self) -> usize
[src]Returns the encoded length of the message without a length delimiter.
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError> where
B: BufMut,
[src]
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError> where
B: BufMut,
[src]Encodes the message to a buffer. Read more
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError> where
B: BufMut,
[src]
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError> where
B: BufMut,
[src]Encodes the message with a length-delimiter to a buffer. Read more
fn decode<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
[src]
fn decode<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
[src]Decodes an instance of the message from a buffer. Read more
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
[src]
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError> where
Self: Default,
B: Buf,
[src]Decodes a length-delimited instance of the message from the buffer.
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError> where
B: Buf,
[src]
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError> where
B: Buf,
[src]Decodes an instance of the message from a buffer, and merges it into self
. Read more
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError> where
B: Buf,
[src]
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError> where
B: Buf,
[src]Decodes a length-delimited instance of the message from buffer, and
merges it into self
. Read more
impl Message for Request
impl Message for Request
fn compute_size(&self) -> u32
fn compute_size(&self) -> u32
Compute and cache size of this message and all nested messages
fn get_cached_size(&self) -> u32
fn get_cached_size(&self) -> u32
Get size previously computed by compute_size
.
fn descriptor(&self) -> &'static MessageDescriptor
fn descriptor(&self) -> &'static MessageDescriptor
Message descriptor for this message, used for reflection.
fn default_instance() -> &'static Request
fn default_instance() -> &'static Request
Return a pointer to default immutable message with static lifetime. Read more
fn is_initialized(&self) -> bool
fn is_initialized(&self) -> bool
True iff all required fields are initialized.
Always returns true
for protobuf 3. Read more
fn write_to_with_cached_sizes(
&self,
_os: &mut CodedOutputStream<'_>
) -> ProtobufResult<()>
fn write_to_with_cached_sizes(
&self,
_os: &mut CodedOutputStream<'_>
) -> ProtobufResult<()>
Write message to the stream. Read more
fn merge_from(&mut self, _is: &mut CodedInputStream<'_>) -> ProtobufResult<()>
fn merge_from(&mut self, _is: &mut CodedInputStream<'_>) -> ProtobufResult<()>
Update this message object with fields read from given stream.
fn get_unknown_fields(&self) -> &UnknownFields
fn get_unknown_fields(&self) -> &UnknownFields
Get a reference to unknown fields.
fn mut_unknown_fields(&mut self) -> &mut UnknownFields
fn mut_unknown_fields(&mut self) -> &mut UnknownFields
Get a mutable reference to unknown fields.
fn write_to_bytes(&self) -> ProtobufResult<Vec<u8>>
fn write_to_bytes(&self) -> ProtobufResult<Vec<u8>>
Write the message to bytes vec.
fn merge_from_bytes(&mut self, bytes: &[u8]) -> ProtobufResult<()>
fn merge_from_bytes(&mut self, bytes: &[u8]) -> ProtobufResult<()>
Update this message object with fields read from given stream.
fn parse_from(is: &mut CodedInputStream<'_>) -> Result<Self, ProtobufError>
[src]
fn parse_from(is: &mut CodedInputStream<'_>) -> Result<Self, ProtobufError>
[src]Parse message from stream.
fn write_to(&self, os: &mut CodedOutputStream<'_>) -> Result<(), ProtobufError>
[src]
fn write_to(&self, os: &mut CodedOutputStream<'_>) -> Result<(), ProtobufError>
[src]Write the message to the stream. Read more
fn write_length_delimited_to(
&self,
os: &mut CodedOutputStream<'_>
) -> Result<(), ProtobufError>
[src]
fn write_length_delimited_to(
&self,
os: &mut CodedOutputStream<'_>
) -> Result<(), ProtobufError>
[src]Write the message to the stream prepending the message with message length encoded as varint. Read more
fn write_length_delimited_to_vec(
&self,
vec: &mut Vec<u8, Global>
) -> Result<(), ProtobufError>
[src]
fn write_length_delimited_to_vec(
&self,
vec: &mut Vec<u8, Global>
) -> Result<(), ProtobufError>
[src]Write the message to the vec, prepend the message with message length encoded as varint. Read more
fn parse_from_reader(reader: &mut dyn Read) -> Result<Self, ProtobufError>
[src]
fn parse_from_reader(reader: &mut dyn Read) -> Result<Self, ProtobufError>
[src]Parse message from reader. Parse stops on EOF or when error encountered. Read more
fn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>
[src]
fn parse_from_bytes(bytes: &[u8]) -> Result<Self, ProtobufError>
[src]Parse message from byte array.
fn check_initialized(&self) -> Result<(), ProtobufError>
[src]
fn check_initialized(&self) -> Result<(), ProtobufError>
[src]Check if all required fields of this object are initialized.
fn write_to_writer(&self, w: &mut dyn Write) -> Result<(), ProtobufError>
[src]
fn write_to_writer(&self, w: &mut dyn Write) -> Result<(), ProtobufError>
[src]Write the message to the writer.
fn write_to_vec(&self, v: &mut Vec<u8, Global>) -> Result<(), ProtobufError>
[src]
fn write_to_vec(&self, v: &mut Vec<u8, Global>) -> Result<(), ProtobufError>
[src]Write the message to bytes vec.
fn write_length_delimited_to_writer(
&self,
w: &mut dyn Write
) -> Result<(), ProtobufError>
[src]
fn write_length_delimited_to_writer(
&self,
w: &mut dyn Write
) -> Result<(), ProtobufError>
[src]Write the message to the writer, prepend the message with message length encoded as varint. Read more
fn write_length_delimited_to_bytes(
&self
) -> Result<Vec<u8, Global>, ProtobufError>
[src]
fn write_length_delimited_to_bytes(
&self
) -> Result<Vec<u8, Global>, ProtobufError>
[src]Write the message to the bytes vec, prepend the message with message length encoded as varint. Read more
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
[src]View self as mutable Any
.
fn into_any(self: Box<Self, Global>) -> Box<dyn Any + 'static, Global>
[src]
fn into_any(self: Box<Self, Global>) -> Box<dyn Any + 'static, Global>
[src]Convert boxed self to boxed Any
.
fn descriptor_static() -> &'static MessageDescriptor
[src]
fn descriptor_static() -> &'static MessageDescriptor
[src]Get message descriptor for message type. Read more
impl StructuralPartialEq for Request
[src]
Auto Trait Implementations
impl RefUnwindSafe for Request
impl Send for Request
impl Sync for Request
impl Unpin for Request
impl UnwindSafe for Request
Blanket Implementations
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]pub fn borrow_mut(&mut self) -> &mut T
[src]
pub fn borrow_mut(&mut self) -> &mut T
[src]Mutably borrows from an owned value. Read more
impl<T> ToOwned for T where
T: Clone,
[src]
impl<T> ToOwned for T where
T: Clone,
[src]type Owned = T
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T
[src]
pub fn to_owned(&self) -> T
[src]Creates owned data from borrowed data, usually by cloning. Read more
pub fn clone_into(&self, target: &mut T)
[src]
pub fn clone_into(&self, target: &mut T)
[src]🔬 This is a nightly-only experimental API. (toowned_clone_into
)
recently added
Uses borrowed data to replace owned data, usually by cloning. Read more