36 float r = 85.0f, g = 0.0f, b = 255.0f;
98 if (TYPointCalcul::operator!=(other))
102 if (TYColorInterface::operator!=(other))
162 TYMapIdBool::iterator it_b;
165 DOM_Element tmpNode = domDoc.createElement(
"etatCalcul");
166 domNewElem.appendChild(tmpNode);
168 tmpNode.setAttribute(
"idCalcul", it_b->first.toString());
180 bool hauteurOk =
false;
181 bool formeObjetOk =
false;
182 bool bOldDatas =
false;
184 std::map<TYUUID, LPTYSpectre>* compatibilityVector =
new std::map<TYUUID, LPTYSpectre>();
188 QDomNodeList childs = domElement.childNodes();
189 for (
unsigned int i = 0; i < childs.length(); i++)
191 elemCur = childs.item(i).toElement();
196 if (elemCur.nodeName() ==
"etatCalcul")
199 idCalcul.FromString(strIdCalcul);
203 else if (elemCur.nodeName() ==
"Spectre")
211 idCalcul.FromString(strId);
212 compatibilityVector->operator[](idCalcul) = pSpectre;
216 if (bOldDatas ==
true)
219 std::map<TYUUID, LPTYSpectre>::iterator it;
220 for (it = compatibilityVector->begin(); it != compatibilityVector->end();)
224 it = compatibilityVector->erase(it);
236 delete compatibilityVector;
302 return etat(id_calc);
308 TYMapIdBool::iterator it =
_tabEtats.find(id_calc);
323 assert(pCalc !=
nullptr);
331 TYMapIdBool::iterator it_b;
345 return dynamic_cast<TYProjet*
>(
getParent())->getCurrentCalcul()->getSpectre(
this);
353 TYMapIdBool::iterator it =
_tabEtats.find(
id);
QDomDocument DOM_Document
#define TYDIRPREFERENCEMANAGER
Representation graphique d'un point de controle (fichier header)
TY_EXTENSION_INST(TYPointControl)
TY_EXT_GRAPHIC_INST(TYPointControl)
double _y
y coordinate of OCoord3D
double _z
z coordinate of OCoord3D
double _x
x coordinate of OCoord3D
virtual const char * getClassName() const
static OPrototype * safeDownCast(OPrototype *pObject)
LPTYSiteNode getSite()
Get calculation site.
int fromXML(DOM_Element domElement)
TYColorInterface & operator=(const TYColorInterface &other)
virtual void setColor(const OColor &color)
DOM_Element toXML(DOM_Element &domElement)
TYElement * getParent() const
QString _name
Nom courant de l'element.
bool callFromXMLIfEqual(DOM_Element &domElement, int *pRetVal=NULL)
const TYUUID & getID() const
void setAllUses(void *allUses)
QString generateName(const char *classname)
Retourne le nom de la classe associe a un nombre.
static TYNameManager * get()
Retourne l'instance singleton.
Classe de definition d'un point de calcul.C'est une classe derivee a TYPoint avec en plus un spectrep...
virtual bool deepCopy(const TYElement *pOther, bool copyId=true, bool pUseCopyTag=false)
TYPointCalcul & operator=(TYPointCalcul &other)
Operateur =.
virtual int fromXML(DOM_Element domElement)
virtual DOM_Element toXML(DOM_Element &domElement)
Classe de definition d'un point de controle.Le point de controle est un point de calcul avec une haut...
TYPointControl()
Constructeur par defaut. Constructeur par defaut de la classe TYPointControl.
bool remEtat(TYCalcul *pCalcul)
Remove calcul from "etat" map.
void copyEtats(TYPointControl *pOther)
Copie du map calcul-etat.
void duplicateEtat(const TYUUID &idCalculRef, const TYUUID &idCalculNew)
Duplique l'etat defini pour un calcul pour un autre calcul.
bool operator==(const TYPointControl &other) const
Operateur ==.
int _object
shape of the point in GUI
int getSIGType()
Retourne le type de SIG.
bool operator!=(const TYPointControl &other) const
Operateur !=.
virtual LPTYSpectre getSpectre()
Get du spectre resultat d'un calcul donne.
TYPointControl & operator=(const TYPointControl &other)
Operateur =.
bool _statusSIG
Etat des coordonnees par rapport au SIG (position dans le repere SIG ou pas)
virtual DOM_Element toXML(DOM_Element &domElement)
void toSIG()
Conversion dans le repere du Systeme d'Information Geographique.
TYMapIdBool _tabEtats
L'etat du point pour un calcul donne.
virtual void setEtat(const TYUUID &id_calc, bool etat)
virtual ~TYPointControl()
Destructeur Destructeur de la classe TYPointControl .
double _hauteur
La hauteur du point par rapport a l'altitude.
virtual bool deepCopy(const TYElement *pOther, bool copyId=true, bool pUseCopyTag=false)
virtual std::string toString() const
Copie du map calcul-spectre.
virtual int fromXML(DOM_Element domElement)
classe de definition d'un projet.
LPTYSiteNode getSite()
Get du site.
double getSIG_X()
Get/Set des coordonnees dans le repere du SIG.
int getSIGType()
Get/Set du choix du systeme de repere du SIG.
std::string doubleToStrPre(double val, int precision=2)
std::string doubleToStr(double val)
std::string intToStr(int val)