pub struct PlanGraph {
pub version: PlanGraphVersion,
pub nodes: Vec<PlanNode>,
pub edges: Vec<PlanEdge>,
pub root_nodes: Vec<PlanNodeId>,
pub annotations: PlanAnnotations,
}Expand description
Immutable DAG describing the planner output.
Fields§
§version: PlanGraphVersion§nodes: Vec<PlanNode>§edges: Vec<PlanEdge>§root_nodes: Vec<PlanNodeId>§annotations: PlanAnnotationsImplementations§
Source§impl PlanGraph
impl PlanGraph
Sourcepub fn builder() -> PlanGraphBuilder
pub fn builder() -> PlanGraphBuilder
Construct a new PlanGraphBuilder.
pub fn is_empty(&self) -> bool
pub fn version(&self) -> PlanGraphVersion
pub fn root_nodes(&self) -> &[PlanNodeId]
pub fn validate(&self) -> Result<(), PlanGraphError>
pub fn to_dot(&self) -> Result<String, PlanGraphError>
pub fn to_json(&self) -> Result<String, PlanGraphError>
pub fn from_json(json: &str) -> Result<PlanGraph, PlanGraphError>
pub fn topological_order(&self) -> Result<Vec<PlanNodeId>, PlanGraphError>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for PlanGraph
impl<'de> Deserialize<'de> for PlanGraph
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PlanGraph, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PlanGraph, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Serialize for PlanGraph
impl Serialize for PlanGraph
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for PlanGraph
Auto Trait Implementations§
impl Freeze for PlanGraph
impl RefUnwindSafe for PlanGraph
impl Send for PlanGraph
impl Sync for PlanGraph
impl Unpin for PlanGraph
impl UnwindSafe for PlanGraph
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
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more