Skip to main content

GraphClientQueries

Trait GraphClientQueries 

Source
pub trait GraphClientQueries: GraphEdge
where Self::Ends: TypedEdgeEnds,
{ type FromQuery: QueryParams + QueryItemType<Item = Self>; type ToQuery: QueryParams + QueryItemType<Item = Self>; type BetweenQuery: QueryParams + QueryItemType<Item = Self>; // Required methods fn from_query( endpoint: &<<Self::Ends as TypedEdgeEnds>::A as EndpointSpec>::Value, ) -> Self::FromQuery; fn to_query( endpoint: &<<Self::Ends as TypedEdgeEnds>::B as EndpointSpec>::Value, ) -> Self::ToQuery; fn between_query( a: &<<Self::Ends as TypedEdgeEnds>::A as EndpointSpec>::Value, b: &<<Self::Ends as TypedEdgeEnds>::B as EndpointSpec>::Value, ) -> Self::BetweenQuery; }
Expand description

Generated client-query types for one registered edge item.

The #[myko_edge] macro implements this trait, allowing generic Rust client helpers to construct the same ordinary queries emitted by TypeScript graph codegen without exposing query names at call sites.

Required Associated Types§

Required Methods§

Source

fn from_query( endpoint: &<<Self::Ends as TypedEdgeEnds>::A as EndpointSpec>::Value, ) -> Self::FromQuery

Source

fn to_query( endpoint: &<<Self::Ends as TypedEdgeEnds>::B as EndpointSpec>::Value, ) -> Self::ToQuery

Source

fn between_query( a: &<<Self::Ends as TypedEdgeEnds>::A as EndpointSpec>::Value, b: &<<Self::Ends as TypedEdgeEnds>::B as EndpointSpec>::Value, ) -> Self::BetweenQuery

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementors§