Applies [Context::set_main_graph] to the parent context and `this` graph. Returns the clone of `this`. # Returns This graph # Example ``` # use ciphercore_base::graphs::create_context; # use ciphercore_base::data_types::{array_type, INT32}; let c = create_context().unwrap(); let g = c.create_graph().unwrap(); let t = array_type(vec![3, 2], INT32); let n = g.input(t).unwrap(); n.set_as_output()
(&self)
| 1475 | /// g.set_as_main().unwrap(); |
| 1476 | /// ``` |
| 1477 | pub fn set_as_main(&self) -> Result<Graph> { |
| 1478 | self.get_context().set_main_graph(self.clone())?; |
| 1479 | Ok(self.clone()) |
| 1480 | } |
| 1481 | |
| 1482 | /// Applies [Context::set_graph_name] to the parent context and `this` graph. Returns the clone of `this`. |
| 1483 | /// |