pub trait QueryHook {
// Required method
fn handle(
&self,
incoming: Query,
responses: Box<dyn ResponseStream>,
) -> bool;
}
Required Methods§
Sourcefn handle(&self, incoming: Query, responses: Box<dyn ResponseStream>) -> bool
fn handle(&self, incoming: Query, responses: Box<dyn ResponseStream>) -> bool
Handle an incoming query. If the query is considered malformed or malicious, return false. If the query is valid, return true. Valid queries with no results should still return true, and the response object should be dropped.