nodo 0.18.5

A realtime framework for robotics
Documentation
// Copyright 2023 David Weikersdorfer

use serde::{Deserialize, Serialize};

#[derive(Debug, Clone, Copy, PartialEq, Eq, Serialize, Deserialize)]
pub enum DefaultStatus {
    /// The codelet skipped this step as there was no work to do.
    /// Skipped steps are counted separately in statistics and other tools.
    Skipped,

    /// The codelet executed work.
    Running,
}

pub const SKIPPED: Outcome = Ok(DefaultStatus::Skipped);

// TODO to be enabled #[deprecated(note = "use RUNNING instead")]
pub const SUCCESS: Outcome = Ok(DefaultStatus::Running);
pub const RUNNING: Outcome = Ok(DefaultStatus::Running);

/// Result of an task
// TODO to be deprecated
pub type Outcome = eyre::Result<OutcomeKind>;

// TODO to be deprecated
pub type OutcomeKind = DefaultStatus;