[−][src]Struct ieql::output::output::Output
Output
represents a 'match' of a Query. It is the primary
product of an IEQL scan, and contains many variable (and configurable)
pieces of data and metadata.
Note: response
and output
are synonymous in the context of this
documentation.
Outputs have two kinds: Full
and Partial
. Full outputs are for
matches which exist on their own—for example, a match of someone's
name online. Partial outputs, however, are meant to be MapReduced.
For example, if a linguist wanted to count the number of times a certain
word appears online, they would configure their query to produce a Partial
response, which they would then MapReduce.
There is not currently full support for partial IEQL outputs.
Fields
items: Vec<OutputItem>
Contains the data relevant for the user; for example, excerpts of the match.
kind: OutputKind
Represents the kind of the output (Full
or Partial
).
id: Option<String>
This is an optional value for identifying the output, and can vary based on your implementation. In most cases, when present, this is some form of UUID.
query_id: Option<String>
This is the ID of the query that created the output. Note that this will only be present when the query that created the output itself has an id.
Methods
impl Output
[src]
pub fn new(
document: &CompiledDocument,
query: &CompiledQuery,
matches: Vec<PatternMatch>,
id: Option<String>
) -> Output
[src]
document: &CompiledDocument,
query: &CompiledQuery,
matches: Vec<PatternMatch>,
id: Option<String>
) -> Output
Create a new output from the given data. Please note that this operation is expensive!
Arguments
document
: the compiled document that the query matchedquery
: the compiled query that matched the documentmatches
: thePatternMatch
es produced by the queries' triggersid
: the optional ID of the desired output
Trait Implementations
impl Debug for Output
[src]
impl<'de> Deserialize<'de> for Output
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
impl Display for Output
[src]
impl PartialEq<Output> for Output
[src]
impl Serialize for Output
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl StructuralPartialEq for Output
[src]
Auto Trait Implementations
impl RefUnwindSafe for Output
impl Send for Output
impl Sync for Output
impl Unpin for Output
impl UnwindSafe for Output
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToString for T where
T: Display + ?Sized,
[src]
T: Display + ?Sized,
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,