Function comfyui_api::models::prompt::as_node

source ·
pub fn as_node<T: Node + 'static>(node: &dyn Node) -> Option<&T>
Expand description

Get a reference to a node of a specific type.

§Arguments

  • node - The node to get a reference to.

§Returns

A reference to the node of the specified type if the node is of the specified type, otherwise None.