Struct google_api_proto::google::cloud::contentwarehouse::v1::PropertyFilter
source · pub struct PropertyFilter {
pub document_schema_name: String,
pub condition: String,
}
Fields§
§document_schema_name: String
The Document schema name [Document.document_schema_name][google.cloud.contentwarehouse.v1.Document.document_schema_name]. Format: projects/{project_number}/locations/{location}/documentSchemas/{document_schema_id}.
condition: String
The filter condition. The syntax for this expression is a subset of SQL syntax.
Supported operators are: =
, !=
, <
, <=
, >
, >=
, and ~~
where
the left of the operator is a property name and the right of the operator
is a number or a quoted string. You must escape backslash (\) and quote
(") characters.
~~
is the LIKE operator. The right of the operator must be a string. The
only supported property data type for LIKE is text_values. It provides
semantic search functionality by parsing, stemming and doing synonyms
expansion against the input query. It matches if the property contains
semantic similar content to the query. It is not regex matching or wildcard
matching. For example, “property.company ~~ "google"” will match records
whose property property.compnay
have values like “Google Inc.”, “Google
LLC” or “Google Company”.
Supported functions are LOWER(\[property_name\])
to perform a
case insensitive match and EMPTY(\[property_name\])
to filter on the
existence of a key.
Boolean expressions (AND/OR/NOT) are supported up to 3 levels of nesting (for example, “((A AND B AND C) OR NOT D) AND E”), a maximum of 100 comparisons or functions are allowed in the expression. The expression must be < 6000 bytes in length.
Only properties that are marked filterable are allowed ([PropertyDefinition.is_filterable][google.cloud.contentwarehouse.v1.PropertyDefinition.is_filterable]). Property names do not need to be prefixed by the document schema id (as is the case with histograms), however property names will need to be prefixed by its parent hierarchy, if any. For example: top_property_name.sub_property_name.
Sample Query:
(LOWER(driving_license)="class \"a\"" OR EMPTY(driving_license)) AND driving_years > 10
CMEK compliant deployment only supports:
- Operators:
=
,<
,<=
,>
, and>=
. - Boolean expressions: AND and OR.
Trait Implementations§
source§impl Clone for PropertyFilter
impl Clone for PropertyFilter
source§fn clone(&self) -> PropertyFilter
fn clone(&self) -> PropertyFilter
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl Debug for PropertyFilter
impl Debug for PropertyFilter
source§impl Default for PropertyFilter
impl Default for PropertyFilter
source§impl Message for PropertyFilter
impl Message for PropertyFilter
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
self
.source§impl PartialEq for PropertyFilter
impl PartialEq for PropertyFilter
source§fn eq(&self, other: &PropertyFilter) -> bool
fn eq(&self, other: &PropertyFilter) -> bool
self
and other
values to be equal, and is used
by ==
.impl StructuralPartialEq for PropertyFilter
Auto Trait Implementations§
impl Freeze for PropertyFilter
impl RefUnwindSafe for PropertyFilter
impl Send for PropertyFilter
impl Sync for PropertyFilter
impl Unpin for PropertyFilter
impl UnwindSafe for PropertyFilter
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T
in a tonic::Request