Module config

Source
Expand description

This module defines the configuration of the copper runtime. The configuration is a directed graph where nodes are tasks and edges are connections between tasks. The configuration is serialized in the RON format. The configuration is used to generate the runtime code at compile time.

Re-exportsยง

pub use petgraph::Direction::Incoming;
pub use petgraph::Direction::Outgoing;

Macrosยง

impl_from_numeric_for_value ๐Ÿ”’
impl_from_value_for_int ๐Ÿ”’

Structsยง

Cnx
This represents a connection between 2 tasks (nodes) in the configuration graph.
ComponentConfig
This is the configuration of a component (like a task config or a monitoring config):w It is a map of key-value pairs. It is given to the new method of the task implementation.
CuConfig
CuConfig is the programmatic representation of the configuration graph. It is a directed graph where nodes are tasks and edges are connections between tasks.
CuConfigRepresentation ๐Ÿ”’
This is the main Copper configuration representation.
CuGraph
IncludesConfig
Includes are used to include other configuration files.
LoggingConfig
MissionsConfig
Missions are used to generate alternative DAGs within the same configuration.
MonitorConfig
Node
A node in the configuration graph. A node represents a Task in the system Graph.
Value
Wrapper around the ron::Value to allow for custom serialization.

Enumsยง

ConfigGraphs

Constantsยง

DEFAULT_KEYFRAME_INTERVAL

Functionsยง

config_representation_to_config ๐Ÿ”’
Convert a CuConfigRepresentation to a CuConfig. Uses the deserialize_impl method and validates the logging configuration.
default_as_true ๐Ÿ”’
default_keyframe_interval ๐Ÿ”’
deserialize_config_representation ๐Ÿ”’
Shared implementation for deserializing a CuConfigRepresentation into a CuConfig
parse_config_string ๐Ÿ”’
Read a copper configuration from a String. Parse a RON string into a CuConfigRepresentation, using the standard options. Returns an error if the parsing fails.
process_includes ๐Ÿ”’
Returns a merged CuConfigRepresentation.
read_configuration
Read a copper configuration from a file.
read_configuration_str
substitute_parameters ๐Ÿ”’

Type Aliasesยง

NodeId
NodeId is the unique identifier of a node in the configuration graph for petgraph and the code generation.