Template Struct type_caster< Karana::Core::NumericVar< T > >#
Defined in File pybind11Utils.h
Inheritance Relationships#
Base Type#
public type_caster_base< Karana::Core::NumericVar< T > >
Struct Documentation#
-
template<typename T>
struct type_caster<Karana::Core::NumericVar<T>> : public type_caster_base<Karana::Core::NumericVar<T>># Emit a generic Var annotation while using pybind11’s class conversions.
- Template Parameters:
T – The value returned by the Var’s callable.
Public Static Functions
-
static inline handle cast(const Karana::Core::NumericVar<T> *value, return_value_policy policy, handle parent)#
Cast a native Var and resolve units for quantity-derived instances.
- Parameters:
value – Numeric base pointer.
policy – Python ownership policy.
parent – Parent Python object for reference policies.
- Returns:
Python instance preserving its registered dynamic type.
-
static inline handle cast(const Karana::Core::NumericVar<T> &value, return_value_policy policy, handle parent)#
Cast a referenced Var using the pointer conversion path.
- Parameters:
value – Native Var reference.
policy – Python ownership policy.
parent – Parent Python object for reference policies.
- Returns:
Python instance preserving dynamic type and resolved units.
Public Static Attributes
-
static auto name = const_name<(std::is_same_v<T, float> || std::is_same_v<T, double> || (Karana::KUtils::is_eigen_type_v<T> && !Karana::KUtils::is_eigen_int_type_v<T>))>(const_name("Karana.Core.NumericVar["), const_name("Karana.Core.Var[")) + varValueTypeName<T>() + const_name("]")#
The annotation shared by arguments, return values, and container elements.