AntaresSimulatorTeam/Antares_Simulator

initializeFromLink is useless ?

Closed this issue · 1 comments

All it does is call the next one

void initializeFromLink(Data::Study* study, Data::AreaLink* link)
{
    // Next
    NextType::initializeFromAreaLink(study, link);
}

But none of these seem to do anything other than that.

I was wrong

void initializeFromAreaLink(Data::Study* study, Data::AreaLink* link)
{
    if (link->useLoopFlow)
    {
        // Flow assessed over all MC years (linear)
        unsigned int height = link->parameters.height;
        (void)::memcpy(pValuesForTheCurrentYear.hour,
                       link->parameters[Data::fhlLoopFlow],
                       sizeof(double) * height);
    }

    // Next
    NextType::initializeFromAreaLink(study, link);
}