File tree Expand file tree Collapse file tree 1 file changed +16
-1
lines changed
datafusion/physical-plan/src Expand file tree Collapse file tree 1 file changed +16
-1
lines changed Original file line number Diff line number Diff line change @@ -24,7 +24,7 @@ use std::fmt::Formatter;
2424
2525use arrow:: datatypes:: SchemaRef ;
2626
27- use datafusion_common:: display:: GraphvizBuilder ;
27+ use datafusion_common:: display:: { GraphvizBuilder , PlanType , StringifiedPlan } ;
2828use datafusion_expr:: display_schema;
2929use datafusion_physical_expr:: LexOrdering ;
3030
@@ -312,6 +312,21 @@ impl<'a> DisplayableExecutionPlan<'a> {
312312 show_schema : self . show_schema ,
313313 }
314314 }
315+
316+ #[ deprecated( since = "47.0.0" , note = "indent() or tree_render() instead" ) ]
317+ pub fn to_stringified (
318+ & self ,
319+ verbose : bool ,
320+ plan_type : PlanType ,
321+ explain_format : DisplayFormatType ,
322+ ) -> StringifiedPlan {
323+ match ( & explain_format, & plan_type) {
324+ ( DisplayFormatType :: TreeRender , PlanType :: FinalPhysicalPlan ) => {
325+ StringifiedPlan :: new ( plan_type, self . tree_render ( ) . to_string ( ) )
326+ }
327+ _ => StringifiedPlan :: new ( plan_type, self . indent ( verbose) . to_string ( ) ) ,
328+ }
329+ }
315330}
316331
317332/// Enum representing the different levels of metrics to display
You can’t perform that action at this time.
0 commit comments