#pragma once /************************************************************************ MeOS - Orienteering Software Copyright (C) 2009-2018 Melin Software HB This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program. If not, see . Melin Software HB - software@melin.nu - www.melin.nu Eksoppsvägen 16, SE-75646 UPPSALA, Sweden ************************************************************************/ #include class ClassConfigInfo { friend class oEvent; private: bool results; bool starttimes; int maximumLegNumber; public: vector < vector > timeStart; vector individual; vector relay; vector patrol; vector< vector > legNStart; vector< vector > raceNStart; map > legResult; // main leg number -> class selection vector< vector > raceNRes; vector rogainingClasses; // True if predefined forking bool hasMultiCourse; bool hasMultiEvent; // True if there are rented cards bool hasRentedCard; vector classWithoutCourse; void clear(); bool hasIndividual() const {return individual.size()>0;} bool hasRelay() const {return relay.size()>0;} bool hasPatrol() const {return patrol.size()>0;} bool hasRogaining() const {return rogainingClasses.size()>0;} bool empty() const; // Return true of this is an event in a sequence of events. bool isMultiStageEvent() const {return hasMultiEvent;} void getIndividual(set &sel) const; void getRelay(set &sel) const; void getPatrol(set &sel) const; void getTeamClass(set &sel) const; void getRogaining(set &sel) const; bool hasTeamClass() const; void getRaceNStart(int race, set &sel) const; void getLegNStart(int leg, set &sel) const; void getRaceNRes(int race, set &sel) const; void getLegNRes(int leg, set &sel) const; void getTimeStart(int leg, set &sel) const; // Return true if the competiont has any results bool hasResults() const {return results;} // Return true if the competition defines any start times; bool hasStartTimes() const {return starttimes;} int getNumLegsTotal() const {return maximumLegNumber;} };