//! Query trait for parameterized database queries
useserde::{Serialize,de::DeserializeOwned};/// Trait for defining parameterized queries
////// Queries allow executing specific operations against the test database.
pubtraitQuery: Sized + Send + Sync {/// The type of arguments passed to the query
typeArgs: Serialize +Clone+Send+Sync;/// The type of result returned by the query
typeResult: DeserializeOwned +Send+Sync;/// The name of this query template
fntemplate_name()->&'staticstr;/// Get the arguments for this query
fnargs(&self)->&Self::Args;/// Create an instance from the query result
fnfrom_result(result:Self::Result)->Self;}/// Request body for executing a query
#[derive(Serialize)]pub(crate)structQueryRequest<'a, A: Serialize>{pubtemplate:&'astr,
pubarguments:&'a A,
}