capacity_profile_traits.hpp file
Per-owner-kind dispatch table for CapacityProfile / CapacityProfileLP.
CapacityProfileTraits<OwnerLP> is the single point where a new profile-able element type is registered. Each specialization carries:
kind:ProfileOwnerKinddiscriminator valueslack_name: per-block slack column display name ("spillover","unserved", …)output_class_name: LP-row / CSV label preserved from the legacy per-owner profile types (e.g."GeneratorProfile"). Picking this string is what keeps existing CSV consumers green.cols_at(owner, sc, st): returns the per-block column-index map of the owner element at (scenario, stage)
The legacy DemandProfileLP / GeneratorProfileLP classes still exist and follow the same dispatch via ProfileObjectLP::add_profile_to_lp; this header simply hoists the dispatch into a traits table so the unified CapacityProfileLP can switch on CapacityProfile::owner_kind at runtime.
Namespaces
- namespace gtopt
Classes
-
template<>struct gtopt::CapacityProfileTraits<DemandLP>
-
template<>struct gtopt::CapacityProfileTraits<GeneratorLP>