NVIDIA Holoscan SDK v2.0.0
v2.0.0 Download PDF

Class Condition

Base Type

Derived Type

class Condition : public holoscan::Component

Base class for all conditions.

A condition is a predicate that can be evaluated at runtime to determine if an operator should execute. This matches the semantics of GXF’s Scheduling Term.

Subclassed by holoscan::gxf::GXFCondition

Public Functions

Condition() = default
Condition(Condition&&) = default
template<typename ArgT, typename ...ArgsT, typename = std::enable_if_t<!std::is_base_of_v<Condition, std::decay_t<ArgT>> && (std::is_same_v<Arg, std::decay_t<ArgT>> || std::is_same_v<ArgList, std::decay_t<ArgT>>)>>
inline explicit Condition(ArgT &&arg, ArgsT&&... args)
~Condition() override = default
inline Condition &name(const std::string &name) &

Set the name of the condition.

Parameters
Returns
inline Condition &&name(const std::string &name) &&

Set the name of the condition.

Parameters
Returns
inline Condition &fragment(Fragment *fragment)

Set the fragment of the condition.

Parameters
Returns
inline Condition &spec(const std::shared_ptr<ComponentSpec> &spec)

Set the component specification to the condition.

Parameters
Returns
inline ComponentSpec *spec()

Get the component specification of the condition.

Returns
inline std::shared_ptr<ComponentSpec> spec_shared()

Get the shared pointer to the component spec.

Returns
inline virtual void setup(ComponentSpec &spec)

Define the condition specification.

Parameters
virtual YAML::Node to_yaml_node() const override

Get a YAML representation of the condition.

Returns

Protected Attributes

bool is_initialized_ = false

Friends

friend class holoscan::Operator

Previous Class ComponentSpec
Next Class Config
© Copyright 2022-2024, NVIDIA. Last updated on Jun 4, 2024.