diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllConnected.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllConnected.cxx index 1175b2d312..24606aff32 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllConnected.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllConnected.cxx @@ -15,11 +15,11 @@ #include #include -// AllConnected prend toutes les Entites connectees a une Entite donnee -// c-a-d toutes les "Shared" + toutes les "Sharings" et on recommence -// Autrement dit le contenu du "Composant Connexe" du graphe d'ensemble -// qui contient cette entite -// Le calcul est effectue par GetFromEntity (Evaluate n'a rien a faire) +// AllConnected takes all Entities connected to a given Entity +// i.e. all "Shared" + all "Sharings" and we restart +// In other words the content of the "Connected Component" of the overall graph +// which contains this entity +// The calculation is performed by GetFromEntity (Evaluate has nothing to do) IFGraph_AllConnected::IFGraph_AllConnected(const Interface_Graph& agraph) : thegraph(agraph) { @@ -54,4 +54,4 @@ void IFGraph_AllConnected::ResetData() void IFGraph_AllConnected::Evaluate() { GetFromGraph(thegraph); -} // GetFromEntity a tout fait +} // GetFromEntity did everything diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllShared.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllShared.cxx index 695623b0c1..ae17e6d839 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllShared.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_AllShared.cxx @@ -34,7 +34,7 @@ IFGraph_AllShared::IFGraph_AllShared(const Interface_Graph& agraph, void IFGraph_AllShared::GetFromEntity(const Handle(Standard_Transient)& ent) { thegraph.GetFromEntity(ent, Standard_True); -} // le fait pour nous +} // does it for us void IFGraph_AllShared::GetFromIter(const Interface_EntityIterator& iter) { diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Articulations.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Articulations.cxx index 3ddf75c922..31a7f203eb 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Articulations.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Articulations.cxx @@ -17,8 +17,8 @@ #include #include -// Points d'Articulation d'un Graphe : ce sont les "passages obliges" du graphe -// Algorithme tire du Sedgewick, p 392 +// Articulation Points of a Graph: these are the "required passages" of the graph +// Algorithm taken from Sedgewick, p 392 IFGraph_Articulations::IFGraph_Articulations(const Interface_Graph& agraph, const Standard_Boolean whole) : thegraph(agraph) @@ -46,9 +46,9 @@ void IFGraph_Articulations::ResetData() void IFGraph_Articulations::Evaluate() { - // Algorithme, cf Sedgewick "Algorithms", p 392 + // Algorithm, see Sedgewick "Algorithms", p 392 thelist = new TColStd_HSequenceOfInteger(); - // Utilisation de Visit + // Use of Visit Standard_Integer nb = thegraph.Size(); for (Standard_Integer i = 1; i <= nb; i++) { @@ -56,7 +56,7 @@ void IFGraph_Articulations::Evaluate() if (thegraph.IsPresent(i)) Visit(i); } - // Resultat dans thelist + // Result in thelist Reset(); Standard_Integer nbres = thelist->Length(); for (Standard_Integer ires = 1; ires <= nbres; ires++) @@ -82,14 +82,14 @@ Standard_Integer IFGraph_Articulations::Visit(const Standard_Integer num) thegraph.GetFromEntity(ent, Standard_False); nument = thegraph.EntityNumber(ent); } - Standard_Integer statent = thegraph.Status(nument); // pas reevalue + Standard_Integer statent = thegraph.Status(nument); // not reevaluated if (statent == 0) { Standard_Integer mm = Visit(nument); if (mm < min) min = mm; if (mm > thegraph.Status(num)) - thelist->Append(num); // ON EN A UN : num + thelist->Append(num); // WE HAVE ONE: num } else if (statent < min) min = statent; diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Compare.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Compare.cxx index 03450acd22..0e0d4a667e 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Compare.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Compare.cxx @@ -17,10 +17,10 @@ #include #include -// Comparateur de deux sous-ensembles d un Modele -// Au premier sous-ensemble, est attribue le Status 1 -// Au deuxieme sous-ensemble, est attribue le Status 2 -// La partie commune se voit attribuer le Status 3 +// Comparator of two subsets of a Model +// To the first subset, Status 1 is assigned +// To the second subset, Status 2 is assigned +// The common part is assigned Status 3 IFGraph_Compare::IFGraph_Compare(const Interface_Graph& agraph) : thegraph(agraph) { @@ -70,7 +70,7 @@ void IFGraph_Compare::ResetData() void IFGraph_Compare::Evaluate() { Reset(); - GetFromGraph(thegraph); // Evaluation deja faite par le graphe + GetFromGraph(thegraph); // Evaluation already done by the graph } Interface_EntityIterator IFGraph_Compare::Common() const diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_ConnectedComponants.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_ConnectedComponants.cxx index 18176302da..84f82d4be8 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_ConnectedComponants.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_ConnectedComponants.cxx @@ -16,12 +16,12 @@ #include #include -// Pour travailler, ConnectedComponants exploite AllConnected : -// On prend un 1er Vertex, on determine ses AllConnected -> voila un 1er +// To work, ConnectedComponants exploits AllConnected: +// Take a 1st Vertex, determine its AllConnected -> here is a 1st // Connected Component -// On recommence jusqu'a ce qu'il n'y ait plus de Vertex libre -// Honnetement, si ca ne marche pas, cf classe ConnectedVerticesIterator -// de GraphTools qui fait en principe la meme chose +// Restart until there are no more free Vertices +// Honestly, if it doesn't work, see ConnectedVerticesIterator class +// from GraphTools which does basically the same thing IFGraph_ConnectedComponants::IFGraph_ConnectedComponants(const Interface_Graph& agraph, const Standard_Boolean whole) : IFGraph_SubPartsIterator(agraph, whole) @@ -30,9 +30,9 @@ IFGraph_ConnectedComponants::IFGraph_ConnectedComponants(const Interface_Graph& void IFGraph_ConnectedComponants::Evaluate() { - // On part des "loaded" - // Pour chacun : s il est note dans le graphe, on passe - // Sinon, on ajoute les AllConnected en tant que sub-part + // Start from "loaded" + // For each: if it is noted in the graph, we pass + // Otherwise, add the AllConnected as sub-part Interface_EntityIterator loaded = Loaded(); Reset(); for (loaded.Start(); loaded.More(); loaded.Next()) diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cumulate.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cumulate.cxx index bd2b23f45a..fe8238a229 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cumulate.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cumulate.cxx @@ -18,13 +18,13 @@ #include #include -// Calcul de cumul -// Tres simple, on note les entites demandees, et a la fin -// on a le cumul lui-meme, et comme infos derivees, les doubles et les oublis -// Chaque recouvrement correspond a une augmentation de UN du status -// Les status demarrent a 2, ainsi a l ajout d une entite, on distingue bien -// entre les entites nouvelles, liees a cet appel (statut temporaire 1) et les -// autres (statut superieur ou egal a 2) +// Cumulation calculation +// Very simple, we note the requested entities, and at the end +// we have the cumulation itself, and as derived info, the duplicates and omissions +// Each overlap corresponds to an increase of ONE in the status +// Status starts at 2, thus when adding an entity, we distinguish well +// between new entities, linked to this call (temporary status 1) and the +// others (status greater than or equal to 2) IFGraph_Cumulate::IFGraph_Cumulate(const Interface_Graph& agraph) : thegraph(agraph) { @@ -45,13 +45,13 @@ void IFGraph_Cumulate::ResetData() void IFGraph_Cumulate::GetFromIter(const Interface_EntityIterator& iter) { thegraph.GetFromIter(iter, 1, 1, Standard_True); - thegraph.ChangeStatus(1, 2); // une fois le calcul fait + thegraph.ChangeStatus(1, 2); // once the calculation is done } void IFGraph_Cumulate::Evaluate() { Reset(); - GetFromGraph(thegraph); // evaluation deja faite dans le graphe + GetFromGraph(thegraph); // evaluation already done in the graph } Interface_EntityIterator IFGraph_Cumulate::Overlapped() const diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cycles.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cycles.cxx index 52434595a0..1d8e4eb4d0 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cycles.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_Cycles.cxx @@ -16,8 +16,8 @@ #include #include -// Cycles utilise les services de StrongComponants : -// Il retient les Strong Componants qui ne sont pas Single +// Cycles uses the services of StrongComponants : +// It retains the Strong Componants which are not Single IFGraph_Cycles::IFGraph_Cycles(const Interface_Graph& agraph, const Standard_Boolean whole) : IFGraph_SubPartsIterator(agraph, whole) { diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_ExternalSources.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_ExternalSources.cxx index b3368d059c..35b3f6cb40 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_ExternalSources.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_ExternalSources.cxx @@ -16,12 +16,12 @@ #include #include -// ExternalSources exploite les resultats stockes dans le Graphe sur Sharings -// Soit les "Sharings" des entites notees par GetFromEntity et GetFromIter -// Celles des "Sharings" qui n etaient pas deja notees sont ExternalSources -// Les status : -// - Les entites de depart sont au Status 0 -// - Les entites Sharing NOUVELLES (ExternalSources) sont au Status 1 +// ExternalSources exploits the results stored in the Graph on Sharings +// Either the "Sharings" of entities noted by GetFromEntity and GetFromIter +// Those of the "Sharings" that were not already noted are ExternalSources +// The status: +// - The starting entities are at Status 0 +// - The NEW Sharing entities (ExternalSources) are at Status 1 IFGraph_ExternalSources::IFGraph_ExternalSources(const Interface_Graph& agraph) : thegraph(agraph) { diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_SCRoots.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_SCRoots.cxx index a0a68a4f62..b3f386e41b 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_SCRoots.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_SCRoots.cxx @@ -28,10 +28,10 @@ IFGraph_SCRoots::IFGraph_SCRoots(IFGraph_StrongComponants& subparts) { } -// StrongComponants racines d un ensemble donne -// On ne tient pas compte du reste eventuel (c est un autre probleme) -// On part du fait que StrongComponants donne les Composants dans l ordre de -// dependance, le premier ne dependant de rien (les autres, on ne sait pas ...) +// Root StrongComponants of a given set +// We don't consider the possible remainder (it's another problem) +// We start from the fact that StrongComponants gives Components in the order of +// dependence, the first depending on nothing (the others, we don't know ...) void IFGraph_SCRoots::Evaluate() { @@ -48,11 +48,11 @@ void IFGraph_SCRoots::Evaluate() Handle(Standard_Transient) ent = complist.FirstEntity(); Standard_Integer num = G.EntityNumber(ent); #ifdef OCCT_DEBUG - std::cout << " Iteration,num=" << num << (G.IsPresent(num) ? " Pris" : " A prendre") + std::cout << " Iteration,num=" << num << (G.IsPresent(num) ? " Taken" : " To take") << std::endl; #endif if (!G.IsPresent(num)) - { // enregistrer pour suivants + { // register for following G.GetFromEntity(ent, Standard_True); Interface_EntityIterator list = complist.Entities(); AddPart(); @@ -61,7 +61,7 @@ void IFGraph_SCRoots::Evaluate() } } -/* ce qui suit, c etait autre chose : les SC qui n ont pas d ExternalSource +/* what follows, it was something else: the SC that have no ExternalSource Interface_EntityIterator list = complist.Entities(); IFGraph_ExternalSources eval (Model()); eval.GetFromIter(list); diff --git a/src/DataExchange/TKXSBase/IFGraph/IFGraph_SubPartsIterator.cxx b/src/DataExchange/TKXSBase/IFGraph/IFGraph_SubPartsIterator.cxx index c992c4f072..20f88fe9f7 100644 --- a/src/DataExchange/TKXSBase/IFGraph/IFGraph_SubPartsIterator.cxx +++ b/src/DataExchange/TKXSBase/IFGraph/IFGraph_SubPartsIterator.cxx @@ -21,9 +21,9 @@ #include #include -// SubPartsIterator permet de regrouper les entites en plusieurs sous-parties -// A chaque sous-partie est attache un Status : la 1re a 1, la 2e a 2, etc... -// (consequence, les sous-parties sont necessairement disjointes) +// SubPartsIterator allows grouping entities into several sub-parts +// To each sub-part is attached a Status : the 1st has 1, the 2nd has 2, etc... +// (consequence, the sub-parts are necessarily disjoint) IFGraph_SubPartsIterator::IFGraph_SubPartsIterator(const Interface_Graph& agraph, const Standard_Boolean whole) : thegraph(agraph) @@ -52,7 +52,7 @@ IFGraph_SubPartsIterator::IFGraph_SubPartsIterator(IFGraph_SubPartsIterator& oth if (thegraph.Status(i) == thepart) nbent++; } - theparts->Append(nbent); // compte vide + theparts->Append(nbent); // empty count } thepart = 0; thecurr = 1; @@ -62,8 +62,8 @@ void IFGraph_SubPartsIterator::GetParts(IFGraph_SubPartsIterator& other) { if (Model() != other.Model()) throw Interface_InterfaceError("SubPartsIterator : GetParts"); - // On AJOUTE les Parts de other, sans perdre les siennes propres - // (meme principe que le constructeur ci-dessus) + // We ADD the Parts from other, without losing our own + // (same principle as the constructor above) Standard_Integer nb = thegraph.Size(); thepart = theparts->Length(); for (other.Start(); other.More(); other.Next()) @@ -76,7 +76,7 @@ void IFGraph_SubPartsIterator::GetParts(IFGraph_SubPartsIterator& other) if (thegraph.Status(i) == thepart) nbent++; } - theparts->Append(nbent); // compte vide + theparts->Append(nbent); // empty count } } @@ -85,7 +85,7 @@ const Interface_Graph& IFGraph_SubPartsIterator::Graph() const return thegraph; } -// .... Gestion Interne (remplissage, etc...) .... // +// .... Internal Management (filling, etc...) .... // Handle(Interface_InterfaceModel) IFGraph_SubPartsIterator::Model() const { @@ -139,10 +139,9 @@ void IFGraph_SubPartsIterator::Reset() thecurr = 0; } -// .... Resultat (Evaluation, Iterations) .... // +// .... Result (Evaluation, Iterations) .... // -void IFGraph_SubPartsIterator::Evaluate() { -} // par defaut, ne fait rien; redefinie par les sous-classes +void IFGraph_SubPartsIterator::Evaluate() {} // by default, does nothing; redefined by subclasses Interface_GraphContent IFGraph_SubPartsIterator::Loaded() const { @@ -188,7 +187,7 @@ Standard_Integer IFGraph_SubPartsIterator::EntityPartNum( void IFGraph_SubPartsIterator::Start() { Evaluate(); - // On evalue les tailles des contenus des Parts + // Evaluate the sizes of the Parts contents Standard_Integer nb = thegraph.Size(); Standard_Integer nbp = theparts->Length(); if (thepart > nbp) @@ -197,9 +196,9 @@ void IFGraph_SubPartsIterator::Start() { thecurr = 1; return; - } // L Iteration s arrete de suite + } // Iteration stops immediately - // - On fait les comptes (via tableaux pour performances) + // - Perform counts (via arrays for performance) TColStd_Array1OfInteger partcounts(1, nbp); partcounts.Init(0); TColStd_Array1OfInteger partfirsts(1, nbp); @@ -216,7 +215,7 @@ void IFGraph_SubPartsIterator::Start() if (nbent == 0) partfirsts.SetValue(nump, i); } - // - On les met en forme (c-a-d dans les sequences) + // - Format them (i.e. in sequences) theparts->Clear(); thefirsts->Clear(); Standard_Integer lastp = 0; @@ -230,7 +229,7 @@ void IFGraph_SubPartsIterator::Start() } if (lastp < nbp) theparts->Remove(lastp + 1, nbp); - // Enfin, on se prepare a iterer + // Finally, prepare to iterate thecurr = 1; } @@ -247,7 +246,7 @@ void IFGraph_SubPartsIterator::Next() if (thecurr > theparts->Length()) return; if (theparts->Value(thecurr) == 0) - Next(); // sauter parties vides + Next(); // skip empty parts } Standard_Boolean IFGraph_SubPartsIterator::IsSingle() const @@ -277,7 +276,7 @@ Interface_EntityIterator IFGraph_SubPartsIterator::Entities() const if (nument == 0) return iter; if (theparts->Value(thecurr) == 1) - nb = nument; // evident : 1 seule Entite + nb = nument; // obvious: 1 single Entity for (Standard_Integer i = nument; i <= nb; i++) { if (thegraph.Status(i) == thecurr && thegraph.IsPresent(i)) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect.cxx index a9758a6fe1..ed7d22e71f 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect.cxx @@ -15,8 +15,8 @@ #include #include -// Methodes de confort, evitant de devoir connaitre SessionFile, qui est un -// Tool non destine a l export (en particulier, pas un Handle) +// Convenience methods, avoiding having to know SessionFile, which is a +// Tool not intended for export (in particular, not a Handle) Standard_Boolean IFSelect::SaveSession(const Handle(IFSelect_WorkSession)& WS, const Standard_CString file) { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_BasicDumper.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_BasicDumper.cxx index 90ec4d17fd..cf1b9dcc6e 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_BasicDumper.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_BasicDumper.cxx @@ -45,8 +45,8 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_BasicDumper, IFSelect_SessionDumper) // #include #define FIRSTCHAR 1 -// Param litteral "own" sous la forme :"" -> first = 3 -// A present, forme simplifiee : directement -> first = 1 +// Literal param "own" in the form :"" -> first = 3 +// Now, simplified form : directly -> first = 1 IFSelect_BasicDumper::IFSelect_BasicDumper() {} diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ContextModif.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ContextModif.cxx index 75072c6fc1..08bebb3d86 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ContextModif.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ContextModif.cxx @@ -174,7 +174,7 @@ Standard_Boolean IFSelect_ContextModif::IsTransferred(const Handle(Standard_Tran Standard_Boolean IFSelect_ContextModif::IsSelected(const Handle(Standard_Transient)& ent) const { - // Select a deja verifie "IsTransferred" + // Select already verified "IsTransferred" Standard_Integer num = thegraf.EntityNumber(ent); if (num == 0) return Standard_False; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispGlobal.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispGlobal.cxx index 90a21860ae..2f264b1baf 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispGlobal.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispGlobal.cxx @@ -21,7 +21,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_DispGlobal, IFSelect_Dispatch) -// Genere un seul paquet avec la sortie finale +// Generates a single packet with the final output IFSelect_DispGlobal::IFSelect_DispGlobal() {} TCollection_AsciiString IFSelect_DispGlobal::Label() const @@ -36,7 +36,7 @@ Standard_Boolean IFSelect_DispGlobal::LimitedMax(const Standard_Integer /* nbent return Standard_True; } -// 1 packet ( a partir de UniqueResult) +// 1 packet (from UniqueResult) void IFSelect_DispGlobal::Packets(const Interface_Graph& G, IFGraph_SubPartsIterator& packs) const { packs.AddPart(); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerCount.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerCount.cxx index 910f8dde09..ad68770931 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerCount.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerCount.cxx @@ -69,9 +69,9 @@ void IFSelect_DispPerCount::Packets(const Interface_Graph& G, IFGraph_SubPartsIt IFGraph_SCRoots roots(G, Standard_False); roots.SetLoad(); roots.GetFromIter(FinalSelection()->UniqueResult(G)); - // SCRoots a initie la resolution : decoupage en StrongComponants + selection - // des racines. Un paquet correspond des lors a racines - // Donc, il faut iterer sur les Parts de roots et les prendre par + // SCRoots initiated the resolution: splitting into StrongComponents + selection + // of roots. A packet then corresponds to roots + // Therefore, we must iterate on the Parts of roots and take them by Standard_Integer i = 0; for (roots.Start(); roots.More(); roots.Next()) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerFiles.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerFiles.cxx index 505c795527..8813942f22 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerFiles.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerFiles.cxx @@ -42,7 +42,7 @@ Standard_Integer IFSelect_DispPerFiles::CountValue() const if (!thecount.IsNull()) pcount = thecount->Value(); if (pcount <= 0) - pcount = 1; // option prise par defaut + pcount = 1; // default option taken return pcount; } @@ -63,23 +63,23 @@ Standard_Boolean IFSelect_DispPerFiles::LimitedMax(const Standard_Integer /* nbe void IFSelect_DispPerFiles::Packets(const Interface_Graph& G, IFGraph_SubPartsIterator& packs) const { - // Ressemble a DispPerOne, mais fait "count" AddPart racines + // Resembles DispPerOne, but does "count" AddPart roots Standard_Integer pcount = CountValue(); IFGraph_SCRoots roots(G, Standard_False); roots.SetLoad(); roots.GetFromIter(FinalSelection()->UniqueResult(G)); - // SCRoots a initie la resolution : decoupage en StrongComponants + selection - // des racines. Un paquet correspond des lors a racines - // Donc, il faut iterer sur les Parts de roots et les prendre par - roots.Start(); // Start fait Evaluate specifique + // SCRoots initiated the resolution: breakdown into StrongComponents + selection + // of roots. A packet then corresponds to roots + // Therefore, we need to iterate over the Parts of roots and take them by + roots.Start(); // Start performs specific Evaluate Standard_Integer nb = roots.NbParts(); if (pcount > 0) - pcount = (nb - 1) / pcount + 1; // par packet + pcount = (nb - 1) / pcount + 1; // per packet Standard_Integer i = 0; for (; roots.More(); roots.Next()) - { // Start deja fait + { // Start already done if (i == 0) packs.AddPart(); i++; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerOne.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerOne.cxx index a29aa42596..b307b4c242 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerOne.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_DispPerOne.cxx @@ -23,7 +23,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_DispPerOne, IFSelect_Dispatch) -// Genere un paquet par racine (strong comp.) locale a la liste transmise +// Generates one packet per root (strong comp.) local to the transmitted list IFSelect_DispPerOne::IFSelect_DispPerOne() {} TCollection_AsciiString IFSelect_DispPerOne::Label() const @@ -40,10 +40,10 @@ Standard_Boolean IFSelect_DispPerOne::LimitedMax(const Standard_Integer nbent, void IFSelect_DispPerOne::Packets(const Interface_Graph& G, IFGraph_SubPartsIterator& packs) const { - IFGraph_SCRoots packsc(G, Standard_False); // OK pour SubPartsIterator + IFGraph_SCRoots packsc(G, Standard_False); // OK for SubPartsIterator packsc.SetLoad(); packsc.GetFromIter(FinalSelection()->UniqueResult(G)); - // SCRoots a initie la resolution : decoupage en StrongComponants + selection - // des Racines. Chaque Racine correspond a un Packet. CQFD + // SCRoots initiated the resolution: splitting into StrongComponents + selection + // of Roots. Each Root corresponds to a Packet. QED packs.GetParts(packsc); } diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Dispatch.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Dispatch.cxx index 64d38bba7a..0dbe53cce9 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Dispatch.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Dispatch.cxx @@ -54,7 +54,7 @@ IFSelect_SelectionIterator IFSelect_Dispatch::Selections() const iter.AddItem(thefinal); for (; iter.More(); iter.Next()) { - iter.Value()->FillIterator(iter); // Iterateur qui se court apres + iter.Value()->FillIterator(iter); // Iterator that runs itself after } return iter; } @@ -81,7 +81,7 @@ Interface_EntityIterator IFSelect_Dispatch::Packeted(const Interface_Graph& G) c Interface_EntityIterator remain = Remainder(G); if (remain.NbEntities() == 0) return total; - // sinon, faire la difference ! + // otherwise, make the difference! IFGraph_Compare GC(G); GC.GetFromIter(total, Standard_True); GC.GetFromIter(remain, Standard_False); @@ -92,4 +92,4 @@ Interface_EntityIterator IFSelect_Dispatch::Remainder(const Interface_Graph&) co { Interface_EntityIterator iter; return iter; -} // par defaut vide +} // empty by default diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_EditForm.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_EditForm.cxx index 4b573aa487..44ea322238 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_EditForm.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_EditForm.cxx @@ -155,7 +155,7 @@ Standard_Integer IFSelect_EditForm::NameNumber(const Standard_CString name) cons Standard_Integer res = theeditor->NameNumber(name); if (thecomplete || res == 0) return res; - // Sinon, chercher res dans thenums + // Otherwise, search res in thenums Standard_Integer i, nb = thenums.Length(); for (i = 1; i <= nb; i++) { @@ -170,7 +170,7 @@ Standard_Integer IFSelect_EditForm::NameRank(const Standard_CString name) const Standard_Integer res = theeditor->NameNumber(name); if (thecomplete || res == 0) return res; - // Sinon, chercher res dans thenums + // Otherwise, search res in thenums Standard_Integer i, nb = thenums.Length(); for (i = 1; i <= nb; i++) { @@ -520,7 +520,7 @@ void IFSelect_EditForm::PrintValues(Standard_OStream& S, else { - // Donnees sur lesquelles on a travaille + // Data on which we worked if (themodel.IsNull()) { if (theent.IsNull()) @@ -543,7 +543,7 @@ void IFSelect_EditForm::PrintValues(Standard_OStream& S, << "****************************************************" << std::endl << std::endl; - // Affichage des valeurs + // Display of values Standard_Boolean nams = names; Standard_Integer maxnam = theeditor->MaxNameLength(names ? 0 : -1); if (maxnam == 0) @@ -562,7 +562,7 @@ void IFSelect_EditForm::PrintValues(Standard_OStream& S, Standard_Integer jv = NumberFromRank(iv); Standard_CString name = theeditor->Name(jv, !nams); - // Original ou Final + // Original or Final if (what != 0) { Handle(TCollection_HAsciiString) str; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Editor.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Editor.cxx index 4d6291b14e..1fda90194c 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Editor.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Editor.cxx @@ -238,7 +238,7 @@ Standard_Integer IFSelect_Editor::NameNumber(const Standard_CString name) const Standard_Integer res; if (thenames.Find(name, res)) return res; - res = atoi(name); // si c est un entier, on tente le coup + res = atoi(name); // if it's an integer, we try it if (res < 1 || res > NbValues()) res = 0; return res; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Functions.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Functions.cxx index da53838ed6..da2e5d3553 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Functions.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Functions.cxx @@ -83,7 +83,7 @@ static void SplitFileName(const Standard_CString filename, nomlon = resfile.Length(); nomdeb = resfile.SearchFromEnd("/"); if (nomdeb <= 0) - nomdeb = resfile.SearchFromEnd("\\"); // pour NT + nomdeb = resfile.SearchFromEnd("\\"); // for NT if (nomdeb < 0) nomdeb = 0; nomfin = resfile.SearchFromEnd("."); @@ -97,11 +97,11 @@ static void SplitFileName(const Standard_CString filename, suffix = resfile.SubString(nomfin, nomlon); } -// Functions definit un certain nombre de commandes -// enregistrees dans le Dictionnaire de Activator (par des Act unitaires) -// Les actions elles-memes sont regroupees en fin de fichier +// Functions defines a certain number of commands +// registered in the Activator Dictionary (by unit Acts) +// The actions themselves are grouped at the end of file -// Les definitions +// The definitions static IFSelect_ReturnStatus funstatus(const Handle(IFSelect_SessionPilot)&) { @@ -153,8 +153,8 @@ static IFSelect_ReturnStatus fun3(const Handle(IFSelect_SessionPilot)& pilot) } IFSelect_ReturnStatus status = WS->ReadFile(arg1); - // status : 0 OK, 1 erreur lecture, 2 Fail(try/catch), - // -1 fichier non trouve, -2 lecture faite mais resultat vide + // status: 0 OK, 1 read error, 2 Fail(try/catch), + // -1 file not found, -2 reading done but empty result switch (status) { case IFSelect_RetVoid: @@ -381,8 +381,8 @@ static IFSelect_ReturnStatus funcount(const Handle(IFSelect_SessionPilot)& pilot // return IFSelect_RetError; // } - // Ajout : si Selection, on applique un GraphCounter - // Et en ce cas, on peut en avoir plusieurs : la limite est le mot-cle "on" + // Addition: if Selection, we apply a GraphCounter + // And in this case, we can have several: the limit is the keyword "on" Standard_Integer onflag = 0; Standard_Integer i; // svv Jan11 2000 : porting on DEC for (i = 2; i < argc; i++) @@ -398,7 +398,7 @@ static IFSelect_ReturnStatus funcount(const Handle(IFSelect_SessionPilot)& pilot DeclareAndCast(IFSelect_SelectDeduct, seld, sel); if (!seld.IsNull()) { - // Si onflag, faire une SelectSuite + // If onflag, create a SelectSuite if (onflag > 2) { Handle(IFSelect_SelectSuite) suite = new IFSelect_SelectSuite; @@ -607,7 +607,7 @@ static IFSelect_ReturnStatus fun11(const Handle(IFSelect_SessionPilot)& pilot) niv = 10; break; default: - sout << "Unknown Mode . data tout court pour help" << std::endl; + sout << "Unknown Mode . data simply for help" << std::endl; return IFSelect_RetError; } WS->TraceDumpModel(niv); @@ -745,7 +745,7 @@ static IFSelect_ReturnStatus fun14(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 1) { - sout << "Donner la valeur entiere pour IntParam" << std::endl; + sout << "Give integer value for IntParam" << std::endl; return IFSelect_RetError; } Handle(IFSelect_IntParam) intpar = new IFSelect_IntParam; @@ -783,7 +783,7 @@ static IFSelect_ReturnStatus fun16(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 1) { - sout << "Donner la valeur texte pour TextParam" << std::endl; + sout << "Give text value for TextParam" << std::endl; return IFSelect_RetError; } Handle(TCollection_HAsciiString) textpar = new TCollection_HAsciiString(); @@ -845,7 +845,7 @@ static IFSelect_ReturnStatus fun20(const Handle(IFSelect_SessionPilot)& pilot) return IFSelect_RetError; } - // MakeList : sur Pointed existante ou a creer + // MakeList: on existing Pointed or to be created Handle(IFSelect_SelectPointed) pnt; if (mode == 'm') { @@ -1193,7 +1193,7 @@ static IFSelect_ReturnStatus fun30(const Handle(IFSelect_SessionPilot)& pilot) if (argc < 2) { if (WS->FilePrefix().IsNull()) - sout << "Pas de prefixe defini" << std::endl; + sout << "No prefix defined" << std::endl; else sout << "Prefixe : " << WS->FilePrefix()->ToCString() << std::endl; sout << "Pour changer : filepref newprefix" << std::endl; @@ -1233,16 +1233,16 @@ static IFSelect_ReturnStatus fun32(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Dispatch et nom de Root" << std::endl; + sout << "Give Dispatch and Root name" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Dispatch, disp, WS->NamedItem(arg1)); if (argc < 3) { if (WS->FileRoot(disp).IsNull()) - sout << "Pas de racine definie pour " << arg1 << std::endl; + sout << "No root defined for " << arg1 << std::endl; else - sout << "Racine pour " << arg1 << " : " << WS->FileRoot(disp)->ToCString() << std::endl; + sout << "Root for " << arg1 << " : " << WS->FileRoot(disp)->ToCString() << std::endl; sout << "Pour changer : fileroot nomdisp newroot" << std::endl; return IFSelect_RetVoid; } @@ -1261,7 +1261,7 @@ static IFSelect_ReturnStatus fun33(const Handle(IFSelect_SessionPilot)& pilot) if (argc < 2) { if (WS->DefaultFileRoot().IsNull()) - sout << "Pas de racine par defaut definie" << std::endl; + sout << "No default root defined" << std::endl; else sout << "Racine par defaut : " << WS->DefaultFileRoot()->ToCString() << std::endl; sout << "Pour changer : filedef newdef" << std::endl; @@ -1278,7 +1278,7 @@ static IFSelect_ReturnStatus fun34(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (!WS->HasModel()) { - sout << "Pas de Modele charge, abandon" << std::endl; + sout << "No Model loaded, abort" << std::endl; return IFSelect_RetFail; } @@ -1316,7 +1316,7 @@ static IFSelect_ReturnStatus fun36(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); IFSelect_ReturnStatus stat = IFSelect_RetVoid; if (argc < 2) - sout << "Split : derniere liste de dispatches definie" << std::endl; + sout << "Split : last dispatch list defined" << std::endl; else { WS->ClearShareOut(Standard_True); @@ -1391,7 +1391,7 @@ static IFSelect_ReturnStatus fun38(const Handle(IFSelect_SessionPilot)& pilot) DeclareAndCast(IFSelect_Selection, sel, WS->NamedItem(arg1)); if (sel.IsNull()) { - sout << "Pas de Selection de Nom : " << arg1 << std::endl; + sout << "No Selection with Name : " << arg1 << std::endl; return IFSelect_RetError; } if (arg2[0] == 'k') @@ -1441,7 +1441,7 @@ static IFSelect_ReturnStatus fun41(const Handle(IFSelect_SessionPilot)& pilot) DeclareAndCast(IFSelect_GeneralModifier, modif, WS->NamedItem(arg1)); if (modif.IsNull()) { - sout << "Pas de Modifier de Nom : " << arg1 << std::endl; + sout << "No Modifier with Name : " << arg1 << std::endl; return IFSelect_RetVoid; } Handle(IFSelect_IntParam) low, up; @@ -1483,13 +1483,13 @@ static IFSelect_ReturnStatus fun42(const Handle(IFSelect_SessionPilot)& pilot) if (argc < 2) { sout << "Donner Nom Modifier; + Nom Selection optionnel\n" - << "Selection pour Mettre une Selection, sinon Annule" << std::endl; + << "Selection to Set a Selection, otherwise Cancel" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_GeneralModifier, modif, WS->NamedItem(arg1)); if (modif.IsNull()) { - sout << "Pas un nom de Modifier : " << arg1 << std::endl; + sout << "Not a Modifier name : " << arg1 << std::endl; return IFSelect_RetError; } Handle(IFSelect_Selection) sel; @@ -1498,7 +1498,7 @@ static IFSelect_ReturnStatus fun42(const Handle(IFSelect_SessionPilot)& pilot) sel = GetCasted(IFSelect_Selection, WS->NamedItem(arg2)); if (sel.IsNull()) { - sout << "Pas un nom de Selection : " << arg2 << std::endl; + sout << "Not a Selection name : " << arg2 << std::endl; return IFSelect_RetError; } } @@ -1525,7 +1525,7 @@ static IFSelect_ReturnStatus fun43(const Handle(IFSelect_SessionPilot)& pilot) DeclareAndCast(IFSelect_GeneralModifier, modif, WS->NamedItem(arg1)); if (modif.IsNull()) { - sout << "Pas un nom de Modifier : " << arg1 << std::endl; + sout << "Not a Modifier name : " << arg1 << std::endl; return IFSelect_RetError; } Handle(Standard_Transient) item; @@ -1560,7 +1560,7 @@ static IFSelect_ReturnStatus fun44(const Handle(IFSelect_SessionPilot)& pilot) DeclareAndCast(IFSelect_GeneralModifier, modif, WS->NamedItem(arg1)); if (modif.IsNull()) { - sout << "Pas un nom de Modifier : " << arg1 << std::endl; + sout << "Not a Modifier name : " << arg1 << std::endl; return IFSelect_RetError; } if (!WS->ResetAppliedModifier(modif)) @@ -1579,7 +1579,7 @@ static IFSelect_ReturnStatus fun45(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 4) { - sout << "modifmove MF rang1 rang2, M pour Model F pour File" << std::endl; + sout << "modifmove MF rang1 rang2, M for Model F for File" << std::endl; return IFSelect_RetError; } Standard_Boolean formodel; @@ -1589,7 +1589,7 @@ static IFSelect_ReturnStatus fun45(const Handle(IFSelect_SessionPilot)& pilot) formodel = Standard_False; else { - sout << "preciser M pour Model, F pour File" << std::endl; + sout << "specify M for Model, F for File" << std::endl; return IFSelect_RetError; } Standard_Integer before = atoi(arg2); @@ -1620,13 +1620,13 @@ static IFSelect_ReturnStatus fun51(const Handle(IFSelect_SessionPilot)& pilot) DeclareAndCast(IFSelect_Dispatch, disp, WS->NamedItem(arg1)); if (disp.IsNull()) { - sout << "Pas un nom de Dispatch : " << arg1 << std::endl; + sout << "Not a Dispatch name : " << arg1 << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Selection, sel, WS->NamedItem(arg2)); if (sel.IsNull()) { - sout << "Pas un nom de Selection : " << arg2 << std::endl; + sout << "Not a Selection name : " << arg2 << std::endl; return IFSelect_RetError; } if (!WS->SetItemSelection(disp, sel)) @@ -1659,13 +1659,13 @@ static IFSelect_ReturnStatus fun_dispcount(const Handle(IFSelect_SessionPilot)& Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Nom IntParam pour Count" << std::endl; + sout << "Give IntParam Name for Count" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_IntParam, par, WS->NamedItem(arg1)); if (par.IsNull()) { - sout << "Pas un nom de IntParam : " << arg1 << std::endl; + sout << "Not an IntParam name : " << arg1 << std::endl; return IFSelect_RetError; } Handle(IFSelect_DispPerCount) disp = new IFSelect_DispPerCount; @@ -1682,13 +1682,13 @@ static IFSelect_ReturnStatus fun_dispfiles(const Handle(IFSelect_SessionPilot)& Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Nom IntParam pour NbFiles" << std::endl; + sout << "Give IntParam Name for NbFiles" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_IntParam, par, WS->NamedItem(arg1)); if (par.IsNull()) { - sout << "Pas un nom de IntParam : " << arg1 << std::endl; + sout << "Not an IntParam name : " << arg1 << std::endl; return IFSelect_RetError; } Handle(IFSelect_DispPerFiles) disp = new IFSelect_DispPerFiles; @@ -1711,7 +1711,7 @@ static IFSelect_ReturnStatus fun_dispsign(const Handle(IFSelect_SessionPilot)& p DeclareAndCast(IFSelect_Signature, sig, WS->NamedItem(arg1)); if (sig.IsNull()) { - sout << "Pas un nom de Signature : " << arg1 << std::endl; + sout << "Not a Signature name : " << arg1 << std::endl; return IFSelect_RetError; } Handle(IFSelect_DispPerSignature) disp = new IFSelect_DispPerSignature; @@ -1738,17 +1738,17 @@ static IFSelect_ReturnStatus fun56(const Handle(IFSelect_SessionPilot)& pilot) return IFSelect_RetError; } Standard_Integer num = WS->DispatchRank(disp); - sout << "Dispatch de Nom : " << arg1 << " , en ShareOut, Numero " << num << " : "; + sout << "Dispatch with Name : " << arg1 << " , in ShareOut, Number " << num << " : "; Handle(IFSelect_Selection) sel = WS->ItemSelection(disp); Handle(TCollection_HAsciiString) selname = WS->Name(sel); if (sel.IsNull()) - sout << "Pas de Selection Finale" << std::endl; + sout << "No Final Selection" << std::endl; else if (selname.IsNull()) sout << "Selection Finale : #" << WS->ItemIdent(sel) << std::endl; else sout << "Selection Finale : " << selname->ToCString() << std::endl; if (disp->HasRootName()) - sout << "-- Racine nom de fichier : " << disp->RootName()->ToCString() << std::endl; + sout << "-- Root file name : " << disp->RootName()->ToCString() << std::endl; return IFSelect_RetVoid; } @@ -1990,7 +1990,7 @@ static IFSelect_ReturnStatus fun61(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Nom de Transformer" << std::endl; + sout << "Give Transformer Name" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Transformer, tsf, WS->NamedItem(arg1)); @@ -2004,10 +2004,10 @@ static IFSelect_ReturnStatus fun61(const Handle(IFSelect_SessionPilot)& pilot) sout << "Erreur, Transformation ignoree" << std::endl; break; case -2: - sout << "Erreur sur edition sur place, risque de corruption (verifier)" << std::endl; + sout << "Error on in-place editing, risk of corruption (check)" << std::endl; break; case -1: - sout << "Erreur sur edition locale, risque de corruption (verifier)" << std::endl; + sout << "Error on local editing, risk of corruption (check)" << std::endl; break; case 0: if (tsf.IsNull()) @@ -2058,20 +2058,20 @@ static IFSelect_ReturnStatus fun6465(const Handle(IFSelect_SessionPilot)& pilot) // **** Run Modifier avec Standard Copy **** // **** Run Modifier avec OnTheSpot **** Standard_Boolean runcopy = (pilot->Arg(0)[3] == 'c'); - // soit c est un nom, sinon c est une commande + // either it's a name, otherwise it's a command Handle(IFSelect_Modifier) modif; if (WS->NameIdent(arg1) > 0) modif = GetCasted(IFSelect_Modifier, WS->NamedItem(arg1)); else { - pilot->RemoveWord(0); // c etait la commande run + pilot->RemoveWord(0); // it was the run command pilot->Perform(); modif = GetCasted(IFSelect_Modifier, pilot->RecordedItem()); } Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (modif.IsNull()) { - sout << "Pas un nom de Modifier : " << arg1 << std::endl; + sout << "Not a Modifier name : " << arg1 << std::endl; return IFSelect_RetError; } @@ -2096,10 +2096,10 @@ static IFSelect_ReturnStatus fun6465(const Handle(IFSelect_SessionPilot)& pilot) sout << "Erreur, Transformation ignoree" << std::endl; break; case -2: - sout << "Erreur sur edition sur place, risque de corruption (verifier)" << std::endl; + sout << "Error on in-place editing, risk of corruption (check)" << std::endl; break; case -1: - sout << "Erreur sur edition locale, risque de corruption (verifier)" << std::endl; + sout << "Error on local editing, risk of corruption (check)" << std::endl; break; case 0: if (modif.IsNull()) @@ -2153,7 +2153,7 @@ static IFSelect_ReturnStatus fun70(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Nom de Selection" << std::endl; + sout << "Give Selection Name" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Selection, sel, WS->NamedItem(arg1)); @@ -2217,7 +2217,7 @@ static IFSelect_ReturnStatus fun73(const Handle(IFSelect_SessionPilot)& pilot) if (argc < 2) { sout << "Donner la description du SelectRange" - << " Formes admises :\n : Range de a \n" + << " Accepted forms :\n : Range from to \n" << " tout seul : Range n0 \n from : Range From \n" << " until : Range Until " << std::endl; return IFSelect_RetVoid; @@ -2293,7 +2293,7 @@ static IFSelect_ReturnStatus fun76(const Handle(IFSelect_SessionPilot)& pilot) return IFSelect_RetFail; Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 3) - sout << "Diff sans input : ne pas oublier de les definir (ctlmain, ctlsec)!" << std::endl; + sout << "Diff without input : don't forget to define them (ctlmain, ctlsec)!" << std::endl; DeclareAndCast(IFSelect_Selection, selmain, WS->NamedItem(arg1)); DeclareAndCast(IFSelect_Selection, selsec, WS->NamedItem(arg2)); if (argc >= 2) @@ -2315,14 +2315,14 @@ static IFSelect_ReturnStatus fun77(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 3) { - sout << "Donner Noms de Control et MainInput" << std::endl; + sout << "Give Control and MainInput Names" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Selection, sel, WS->NamedItem(arg1)); DeclareAndCast(IFSelect_Selection, selmain, WS->NamedItem(arg2)); if (WS->SetControl(sel, selmain, Standard_True)) return IFSelect_RetDone; - sout << "Nom incorrect ou Selection " << arg1 << " pas de type Control" << std::endl; + sout << "Incorrect name or Selection " << arg1 << " not of Control type" << std::endl; return IFSelect_RetFail; } @@ -2336,14 +2336,14 @@ static IFSelect_ReturnStatus fun78(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 3) { - sout << "Donner Noms de Control et SecondInput" << std::endl; + sout << "Give Control and SecondInput Names" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_Selection, sel, WS->NamedItem(arg1)); DeclareAndCast(IFSelect_Selection, seldif, WS->NamedItem(arg2)); if (WS->SetControl(sel, seldif, Standard_False)) return IFSelect_RetDone; - sout << "Nom incorrect ou Selection " << arg1 << " pas de type Control" << std::endl; + sout << "Incorrect name or Selection " << arg1 << " not of Control type" << std::endl; return IFSelect_RetFail; } @@ -2405,7 +2405,7 @@ static IFSelect_ReturnStatus fun82(const Handle(IFSelect_SessionPilot)& pilot) Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (argc < 2) { - sout << "Donner Nom IntParam pour n0 Entite" << std::endl; + sout << "Give IntParam Name for Entity n0" << std::endl; return IFSelect_RetError; } DeclareAndCast(IFSelect_IntParam, par, WS->NamedItem(arg1)); @@ -2513,7 +2513,7 @@ static IFSelect_ReturnStatus fun91(const Handle(IFSelect_SessionPilot)& pilot) sout << "Pas une SelectPointed:" << arg1 << std::endl; return IFSelect_RetError; } - const Handle(Interface_InterfaceModel)& model = WS->Model(); // pour Print + const Handle(Interface_InterfaceModel)& model = WS->Model(); // for Print if (argc == 2) { // listage simple Standard_Integer nb = sp->NbItems(); @@ -2581,7 +2581,7 @@ static IFSelect_ReturnStatus fun91(const Handle(IFSelect_SessionPilot)& pilot) } else { - sout << "Ignore:" << argi << " , donner n0 PRECEDE de + ou - ou /" << std::endl; + sout << "Ignore:" << argi << " , give n0 PRECEDED by + or - or /" << std::endl; } } return IFSelect_RetDone; @@ -2770,7 +2770,7 @@ static IFSelect_ReturnStatus fun_editvalue(const Handle(IFSelect_SessionPilot)& return IFSelect_RetError; Standard_Boolean islist = edf->Editor()->IsList(num); - Standard_CString name = edf->Editor()->Name(num, Standard_True); // vrai nom + Standard_CString name = edf->Editor()->Name(num, Standard_True); // real name Handle(TColStd_HSequenceOfHAsciiString) listr; Handle(TCollection_HAsciiString) str; sout << "Value Name : " << name << (edf->IsModified(num) ? "(already edited) : " : " : "); @@ -3200,7 +3200,7 @@ void IFSelect_Functions::Init() IFSelect_Act::AddFunc("settext", "Name:TextParam newValue:string : Change valeur TextParam", fun17); - IFSelect_Act::AddFunc("dumpsel", "Dump Selection suivi du Nom de la Selection a dumper", fun19); + IFSelect_Act::AddFunc("dumpsel", "Dump Selection followed by Name of Selection to dump", fun19); IFSelect_Act::AddFunc("evalsel", "name:Selection [num/sel] : Evalue une Selection", fun20); IFSelect_Act::AddFunc("givelist", "num/sel [num/sel ...] : Evaluates GiveList", fun20); IFSelect_Act::AddFunc("giveshort", "num/sel [num/sel ...] : GiveList in short form", fun20); @@ -3248,14 +3248,14 @@ void IFSelect_Functions::Init() IFSelect_Act::AddFunc("listmodif", "List Final Modifiers", fun40); IFSelect_Act::AddFunc("dumpmodif", "modif:Modifier : Affiche le Statut d'un Modifier", fun41); IFSelect_Act::AddFunc("modifsel", - "modif:Modifier [sel:Selection] : Change/Annule Selection de Modifier", + "modif:Modifier [sel:Selection] : Change/Cancel Selection of Modifier", fun42); IFSelect_Act::AddFunc( "setapplied", "modif:Modifier [name:un item sinon sortie fichier] : Applique un Modifier", fun43); IFSelect_Act::AddFunc("resetapplied", - "modif:Modifier : Enleve un Modifier de la sortie fichier", + "modif:Modifier : Remove a Modifier from file output", fun44); IFSelect_Act::AddFunc( "modifmove", @@ -3263,7 +3263,7 @@ void IFSelect_Functions::Init() fun45); IFSelect_Act::AddFunc("dispsel", - "disp:Dispatch sel:Selection -> Selection Finale de Dispatch", + "disp:Dispatch sel:Selection -> Final Selection of Dispatch", fun51); IFSelect_Act::AddFSet("dispone", "cree DispPerOne", fun_dispone); IFSelect_Act::AddFSet("dispglob", "cree DispGlobal", fun_dispglob); @@ -3272,7 +3272,7 @@ void IFSelect_Functions::Init() IFSelect_Act::AddFSet("dispsign", "sign:Signature : cree DispPerSignature", fun_dispsign); IFSelect_Act::AddFunc("dumpdisp", "disp:Dispatch : Affiche le Statut d'un Dispatch", fun56); - IFSelect_Act::AddFunc("xremove", "nom : Remove a Control Item de la Session", fun57); + IFSelect_Act::AddFunc("xremove", "nom : Remove a Control Item from the Session", fun57); IFSelect_Act::AddFunc("evaldisp", "mode=[0-3] disp:Dispatch : Evaluates one or more Dispatch(es)", fun58); @@ -3284,7 +3284,7 @@ void IFSelect_Functions::Init() "writedisp", "filepattern disp:Dispatch [givelist] : Writes Entities by Splitting by a Dispatch", fun_writedisp); - IFSelect_Act::AddFunc("evalcomplete", "Evaluation Complete de la Repartition", fun59); + IFSelect_Act::AddFunc("evalcomplete", "Complete Evaluation of the Distribution", fun59); IFSelect_Act::AddFunc("runcheck", "affiche LastRunCheckList (write,modif)", fun60); IFSelect_Act::AddFunc("runtranformer", "transf:Transformer : Applique un Transformer", fun61); @@ -3305,7 +3305,7 @@ void IFSelect_Functions::Init() "sel:Selection genre Deduct ou Extract input:Selection : Set Input", fun71); IFSelect_Act::AddFSet("modelroots", "cree SelectModelRoots", fun72); - IFSelect_Act::AddFSet("range", "options... : cree SelectRange ...; tout court pour help", fun73); + IFSelect_Act::AddFSet("range", "options... : create SelectRange ...; simply for help", fun73); IFSelect_Act::AddFSet("roots", "cree SelectRoots (local roots)", fun74); IFSelect_Act::AddFSet("shared", "cree SelectShared", fun75); IFSelect_Act::AddFSet("diff", "[main:Selection diff:Selection] : cree SelectDiff", fun76); @@ -3335,10 +3335,10 @@ void IFSelect_Functions::Init() IFSelect_Act::AddFSet("typecontain", "type:string : cree SelectTextType Contains", fun89); IFSelect_Act::AddFSet("pointed", "cree SelectPointed [num/sel num/sel]", fun90); IFSelect_Act::AddFunc("setpointed", - "sel:SelectPointed : edition SelectPointed. tout court pour help", + "sel:SelectPointed : edit SelectPointed. simply for help", fun91); IFSelect_Act::AddFunc("setlist", - "sel:SelectPointed : edition SelectPointed. tout court pour help", + "sel:SelectPointed : edit SelectPointed. simply for help", fun91); IFSelect_Act::AddFSet("incorrect", "cree SelectIncorrectEntities (computed)", fun92); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ModelCopier.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ModelCopier.cxx index 6ac105666e..8728d18b06 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ModelCopier.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ModelCopier.cxx @@ -47,7 +47,7 @@ void IFSelect_ModelCopier::SetShareOut(const Handle(IFSelect_ShareOut)& sho) } // ######################################################################## -// ######## OPERATIONS DE TRANSFERT GLOBAL (memorise ou non) ######## +// ######## GLOBAL TRANSFER OPERATIONS (memorized or not) ######## void IFSelect_ModelCopier::ClearResult() { @@ -121,7 +121,7 @@ Standard_Boolean IFSelect_ModelCopier::ClearAppliedModifiers(const Standard_Inte return Standard_True; } -// .... Copy : Opere les Transferts, les Memorise (pas d envoi fichier ici) +// .... Copy : Performs Transfers, Memorizes them (no file sending here) Interface_CheckIterator IFSelect_ModelCopier::Copy(IFSelect_ShareOutResult& eval, const Handle(IFSelect_WorkLibrary)& WL, @@ -131,7 +131,7 @@ Interface_CheckIterator IFSelect_ModelCopier::Copy(IFSelect_ShareOutResult& return Copying(eval, WL, protocol, TC); } -// Copy Interne +// Internal Copy Interface_CheckIterator IFSelect_ModelCopier::Copying(IFSelect_ShareOutResult& eval, const Handle(IFSelect_WorkLibrary)& WL, @@ -172,7 +172,7 @@ Interface_CheckIterator IFSelect_ModelCopier::Copying(IFSelect_ShareOutResult& return checks; } -// Send a deux arguments : Envoi Fichier du Resultat deja memorise +// Send with two arguments : File Sending of Result already memorized Interface_CheckIterator IFSelect_ModelCopier::SendCopied(const Handle(IFSelect_WorkLibrary)& WL, const Handle(Interface_Protocol)& protocol) @@ -213,7 +213,7 @@ Interface_CheckIterator IFSelect_ModelCopier::SendCopied(const Handle(IFSelect_W return checks; } -// .... Send a 4 arguments : Calcul du Transfert et Envoi sur Fichier +// .... Send with 4 arguments : Transfer Calculation and File Sending Interface_CheckIterator IFSelect_ModelCopier::Send(IFSelect_ShareOutResult& eval, const Handle(IFSelect_WorkLibrary)& WL, @@ -281,7 +281,7 @@ Interface_CheckIterator IFSelect_ModelCopier::Sending(IFSelect_ShareOutResult& return checks; } -// .... SendAll : Donnees a tranferer dans G, aucun split, envoi sur fichier +// .... SendAll : Data to transfer in G, no split, file sending Interface_CheckIterator IFSelect_ModelCopier::SendAll(const Standard_CString filename, const Interface_Graph& G, @@ -329,8 +329,8 @@ Interface_CheckIterator IFSelect_ModelCopier::SendAll(const Standard_CString return checks; } -// .... SendSelected : Donnees a tranferer dans G, filtrees par iter, -// aucun split, envoi sur fichier +// .... SendSelected : Data to transfer in G, filtered by iter, +// no split, file sending Interface_CheckIterator IFSelect_ModelCopier::SendSelected( const Standard_CString filename, @@ -347,9 +347,9 @@ Interface_CheckIterator IFSelect_ModelCopier::SendSelected( return checks; Handle(Interface_InterfaceModel) newmod = original->NewEmptyModel(); Interface_CopyTool TC(original, protocol); - TC.FillModel(newmod); // pour Header ... + TC.FillModel(newmod); // for Header ... - // Pas de copie : AddWithRefs plus declaration de Bind + // No copy : AddWithRefs plus Bind declaration Interface_GeneralLib lib(protocol); for (list.Start(); list.More(); list.Next()) { @@ -377,7 +377,7 @@ Interface_CheckIterator IFSelect_ModelCopier::SendSelected( newmod, applied, checks); - // Alimenter Remaining : les entites copiees sont a noter + // Feed Remaining : copied entities are to be noted Handle(Standard_Transient) ent1, ent2; for (Standard_Integer ic = TC.LastCopiedAfter(0, ent1, ent2); ic > 0; ic = TC.LastCopiedAfter(ic, ent1, ent2)) @@ -400,7 +400,7 @@ Interface_CheckIterator IFSelect_ModelCopier::SendSelected( } // ########################################################################## -// ######## UN TRANSFERT UNITAIRE (avec Modifications) ######## +// ######## A UNIT TRANSFER (with Modifications) ######## void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, const Handle(IFSelect_WorkLibrary)& WL, @@ -414,11 +414,11 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, Handle(IFSelect_AppliedModifiers)& applied, Interface_CheckIterator& checks) const { - // ... Premiere partie "standard" : remplissage du modele ... - // On cree le Modele, on le remplit avec les Entites, et avec le Header depart + // ... First "standard" part : filling the model ... + // We create the Model, we fill it with Entities, and with the starting Header - // ATTENTION : dispnum = 0 signifie prendre modele original, ne rien copier - // et aussi : pas de Dispatch (envoi en bloc) + // WARNING : dispnum = 0 means take original model, copy nothing + // and also : no Dispatch (bulk sending) applied.Nullify(); const Handle(Interface_InterfaceModel)& original = G.Model(); @@ -429,7 +429,7 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, WL->CopyModel(original, newmod, tocopy, TC); Handle(Standard_Transient) ent1, ent2; - // Alimenter Remaining : les entites copiees sont a noter + // Feed Remaining : copied entities are to be noted for (Standard_Integer ic = TC.LastCopiedAfter(0, ent1, ent2); ic > 0; ic = TC.LastCopiedAfter(ic, ent1, ent2)) { @@ -440,7 +440,7 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, else if (newmod.IsNull()) newmod = original; - // ... Ensuite : On prend en compte les Model Modifiers ... + // ... Then : We take into account the Model Modifiers ... Standard_Integer nbmod = 0; if (!theshareout.IsNull()) nbmod = theshareout->NbModifiers(Standard_True); @@ -449,12 +449,12 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, { Handle(IFSelect_Modifier) unmod = theshareout->ModelModifier(i); - // D abord, critere Dispatch/Packet + // First, Dispatch/Packet criterion if (dispnum > 0) if (!unmod->Applies(theshareout->Dispatch(dispnum))) continue; IFSelect_ContextModif ctx(G, TC, filename.ToCString()); - // Ensuite, la Selection + // Then, the Selection Handle(IFSelect_Selection) sel = unmod->Selection(); if (!sel.IsNull()) { @@ -467,7 +467,7 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, Interface_CheckIterator checklst = ctx.CheckList(); checks.Merge(checklst); - // Faut-il enregistrer les erreurs dans newmod ? bonne question + // Should we record errors in newmod ? good question // if (!checks.IsEmpty(Standard_False)) { // Message::SendWarning() << // " Messages on Copied Model n0 "<NbModifiers(Standard_False); @@ -486,22 +486,22 @@ void IFSelect_ModelCopier::CopiedModel(const Interface_Graph& G, { Handle(IFSelect_GeneralModifier) unmod = theshareout->GeneralModifier(Standard_False, i); - // D abord, critere Dispatch/Packet + // First, Dispatch/Packet criterion if (dispnum > 0) if (!unmod->Applies(theshareout->Dispatch(dispnum))) continue; - // Ensuite, la Selection + // Then, the Selection Handle(IFSelect_Selection) sel = unmod->Selection(); if (sel.IsNull()) - applied->AddModif(unmod); // vide -> on prend tout + applied->AddModif(unmod); // empty -> we take all else { Interface_EntityIterator list = sel->UniqueResult(G); Handle(Standard_Transient) newent; - // Entites designees par la Selection et Copiees ? - // -> s ilyena au moins une, le Modifier s applique, sinon il est rejete - // -> et cette liste est exploitable par le Modifier ... + // Entities designated by the Selection and Copied ? + // -> if there is at least one, the Modifier applies, otherwise it is rejected + // -> and this list is exploitable by the Modifier ... for (list.Start(); list.More(); list.Next()) { if (TC.Search(list.Value(), newent)) @@ -537,7 +537,7 @@ void IFSelect_ModelCopier::CopiedRemaining(const Interface_Graph& G newmod.Nullify(); else { - // CE QUI SUIT NE DOIT PAS ETRE SUPPRIME ! cf theremain + // WHAT FOLLOWS MUST NOT BE DELETED ! cf theremain Handle(Standard_Transient) ent1, ent2; for (Standard_Integer ic = TC.LastCopiedAfter(0, ent1, ent2); ic > 0; ic = TC.LastCopiedAfter(ic, ent1, ent2)) @@ -545,7 +545,7 @@ void IFSelect_ModelCopier::CopiedRemaining(const Interface_Graph& G if (ic <= theremain->Upper()) theremain->SetValue(ic, 1); } -// qq impressions de mise au point +// some debugging prints #ifdef MISOPOINT std::cout << " Remaining Model : " << newmod->NbEntities() << " Entities" << std::endl; Standard_Integer ne = 0; @@ -554,7 +554,7 @@ void IFSelect_ModelCopier::CopiedRemaining(const Interface_Graph& G if (theremain->Value(i) == 0) { if (ne == 0) - std::cout << " Refractaires : "; + std::cout << " Refractory : "; ne++; std::cout << " " << i; } @@ -584,7 +584,7 @@ Standard_Boolean IFSelect_ModelCopier::SetRemaining(Interface_Graph& CG) const } // ########################################################################## -// ######## RESULTAT de la Memorisation des Transferts ######## +// ######## RESULT of Transfer Memorization ######## Standard_Integer IFSelect_ModelCopier::NbFiles() const { @@ -613,12 +613,12 @@ void IFSelect_ModelCopier::BeginSentFiles(const Handle(IFSelect_ShareOut)& sho, thesentfiles.Nullify(); if (record) thesentfiles = new TColStd_HSequenceOfHAsciiString(); - // et numerotation des fichiers par defaut : detenue par ShareOut + // and default file numbering : held by ShareOut if (sho.IsNull()) return; Standard_Integer lastrun = sho->LastRun(); sho->ClearResult(Standard_True); - sho->SetLastRun(lastrun); // on ne s interesse quaux numeros + sho->SetLastRun(lastrun); // we are only interested in the numbers } void IFSelect_ModelCopier::AddSentFile(const Standard_CString filename) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ParamEditor.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ParamEditor.cxx index 509db05ad8..7373e3aabf 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ParamEditor.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ParamEditor.cxx @@ -59,7 +59,7 @@ TCollection_AsciiString IFSelect_ParamEditor::Label() const Standard_Boolean IFSelect_ParamEditor::Recognize(const Handle(IFSelect_EditForm)& /*form*/) const { return Standard_True; -} // pas de contrainte +} // no constraint Handle(TCollection_HAsciiString) IFSelect_ParamEditor::StringValue( const Handle(IFSelect_EditForm)& /*form*/, diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectAnyList.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectAnyList.cxx index 675efd33d2..71e1dea8b6 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectAnyList.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectAnyList.cxx @@ -23,7 +23,7 @@ #include IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectAnyList, IFSelect_SelectDeduct) -// .... Definition de liste : methodes "deferred" NbItems & FillResult +// .... List definition: "deferred" methods NbItems & FillResult void IFSelect_SelectAnyList::SetRange(const Handle(IFSelect_IntParam)& rankfrom, const Handle(IFSelect_IntParam)& rankto) { @@ -82,7 +82,7 @@ Standard_Integer IFSelect_SelectAnyList::UpperValue() const return theupper->Value(); } -// On prend les sous-entites de lower a upper (inclus) +// Take the sub-entities from lower to upper (included) Interface_EntityIterator IFSelect_SelectAnyList::RootResult(const Interface_Graph& G) const { Interface_EntityIterator input = InputResult(G); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectBase.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectBase.cxx index 316c2ecef4..c32525ddf0 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectBase.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectBase.cxx @@ -18,4 +18,4 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectBase, IFSelect_Selection) void IFSelect_SelectBase::FillIterator(IFSelect_SelectionIterator&) const { -} // rien a faire, une SelectBase ne depend d aucune autre Selection +} // nothing to do, a SelectBase doesn't depend on any other Selection diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectEntityNumber.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectEntityNumber.cxx index c7205ac03d..f51deecbec 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectEntityNumber.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectEntityNumber.cxx @@ -40,7 +40,7 @@ Interface_EntityIterator IFSelect_SelectEntityNumber::RootResult(const Interface if (!thenum.IsNull()) num = thenum->Value(); if (num < 1) - return iter; // vide si num < 1 ou num > NbEntities + return iter; // empty if num < 1 or num > NbEntities if (num <= G.Size()) iter.GetOneItem(G.Entity(num)); return iter; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectErrorEntities.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectErrorEntities.cxx index d9af6b195f..360fa23a66 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectErrorEntities.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectErrorEntities.cxx @@ -25,7 +25,7 @@ Standard_Boolean IFSelect_SelectErrorEntities::Sort( const Standard_Integer, const Handle(Standard_Transient)& ent, const Handle(Interface_InterfaceModel)& model) const -//.. ne peut pas marcher, il faut aussi le modele ! ex. via le graphe ... +//.. cannot work, the model is also needed ! ex. via the graph ... { return model->IsErrorEntity(model->Number(ent)); } diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExplore.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExplore.cxx index 57a8ab0c96..1f85d742f1 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExplore.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExplore.cxx @@ -34,17 +34,17 @@ Standard_Integer IFSelect_SelectExplore::Level() const Interface_EntityIterator IFSelect_SelectExplore::RootResult(const Interface_Graph& G) const { - // Attention, voila comme on procede - // On a une IndexedMapOfTransient en entree (entites deja traitees/a traiter) - // Elle est initialisee par InputResult - // Et une map en sortie (resultats pris) -> le resultat sera unique - // En entree, un curseur d entite courante - // Pour chaque entite, on appelle Explore. 3 cas possibles : - // retour False, on passe - // retour True et liste vide, on prend cette entite sans aller plus loin - // retour True et liste non vide, on ne prend pas cette entite mais on - // considere son resultat. - // Si dernier niveau, on le prend en entier. Sinon, il alimente l entree + // Attention, here's how we proceed + // We have an IndexedMapOfTransient as input (entities already processed/to process) + // It is initialized by InputResult + // And a map as output (results taken) -> the result will be unique + // As input, a cursor of current entity + // For each entity, we call Explore. 3 possible cases: + // return False, we skip + // return True and empty list, we take this entity without going further + // return True and non-empty list, we don't take this entity but we + // consider its result. + // If last level, we take it entirely. Otherwise, it feeds the input Standard_Integer nb = G.Size(); TColStd_IndexedMapOfTransient entrees(nb); @@ -76,8 +76,8 @@ Interface_EntityIterator IFSelect_SelectExplore::RootResult(const Interface_Grap if (!Explore(level, ent, G, exp)) continue; - // On prend en compte : entite a prendre directement ? - // reprendre liste en entree (niveau pas atteint) ou resultat (niveau atteint) + // We take into account : entity to take directly ? + // take back input list (level not reached) or result (level reached) if (exp.NbEntities() == 0) { j = result.Add(ent); @@ -95,7 +95,7 @@ Interface_EntityIterator IFSelect_SelectExplore::RootResult(const Interface_Grap } } - // On recolte le resultat + // We collect the result Interface_EntityIterator res; nb = result.Extent(); for (j = 1; j <= nb; j++) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExtract.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExtract.cxx index 9bf2150657..5083b2819d 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExtract.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectExtract.cxx @@ -39,7 +39,7 @@ void IFSelect_SelectExtract::SetDirect(const Standard_Boolean direct) Interface_EntityIterator IFSelect_SelectExtract::RootResult(const Interface_Graph& G) const { Interface_EntityIterator iter; - Interface_EntityIterator inputer = InputResult(G); // tient compte de tout + Interface_EntityIterator inputer = InputResult(G); // takes everything into account Standard_Integer rank = 0; for (inputer.Start(); inputer.More(); inputer.Next()) { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectInList.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectInList.cxx index f616e3240f..00c29bd6a7 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectInList.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectInList.cxx @@ -18,8 +18,8 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectInList, IFSelect_SelectAnyList) -// .... Specialisation de SelectAnyList dans laquelle on traite une liste -// dont chaque item est une Entite +// .... Specialization of SelectAnyList in which we process a list +// where each item is an Entity void IFSelect_SelectInList::FillResult(const Standard_Integer n1, const Standard_Integer n2, const Handle(Standard_Transient)& ent, diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectPointed.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectPointed.cxx index 6fe102b9be..e4f0ff0387 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectPointed.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectPointed.cxx @@ -103,7 +103,7 @@ Standard_Boolean IFSelect_SelectPointed::Toggle(const Handle(Standard_Transient) Standard_Boolean IFSelect_SelectPointed::AddList(const Handle(TColStd_HSequenceOfTransient)& list) { - // Optimise avec une Map + // Optimized with a Map Standard_Boolean res = Standard_False; if (list.IsNull()) return res; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRootComps.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRootComps.cxx index 29d75d4e5d..fbc86508eb 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRootComps.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRootComps.cxx @@ -25,33 +25,33 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectRootComps, IFSelect_SelectExtract) IFSelect_SelectRootComps::IFSelect_SelectRootComps() {} -// Refait pour travailler en une fois -// ATTENTION, il ne faut pas s interesser aux ENTITES mais aux COMPOSANTS -// c-a-d gerer les CYCLES s il y en a +// Redone to work at once +// WARNING, we must not be interested in ENTITIES but in COMPONENTS +// i.e. manage CYCLES if there are any Interface_EntityIterator IFSelect_SelectRootComps::RootResult(const Interface_Graph& G) const { Interface_EntityIterator IEIinput = InputResult(G); Interface_EntityIterator iter; - // ICI, extraire les Componants, puis considerer une Entite de chacun + // HERE, extract the Components, then consider one Entity from each IFGraph_StrongComponants comps(G, Standard_False); comps.SetLoad(); comps.GetFromIter(IEIinput); - Interface_EntityIterator inp1; // IEIinput reduit a une Entite par Composant + Interface_EntityIterator inp1; // IEIinput reduced to one Entity per Component IFGraph_Cumulate GC(G); - // On note dans le graphe : le cumul de chaque ensemble (Entite + Shared tous - // niveaux). Les Roots initiales comptees une seule fois sont bonnes - // Pour Entite : une par Componant (peu importe) + // We note in the graph: the cumulation of each set (Entity + Shared all + // levels). Initial Roots counted only once are good + // For Entity: one per Component (doesn't matter) for (comps.Start(); comps.More(); comps.Next()) { Handle(Standard_Transient) ent = comps.FirstEntity(); GC.GetFromEntity(ent); inp1.GetOneItem(ent); } - // A present, on retient, parmi les inputs, celles comptees une seule fois - // (N.B.: on prend inp1, qui donne UNE entite par composant, simple ou cycle) + // Now, we retain, among the inputs, those counted only once + // (N.B.: we take inp1, which gives ONE entity per component, simple or cycle) for (inp1.Start(); inp1.More(); inp1.Next()) { const Handle(Standard_Transient)& ent = inp1.Value(); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRoots.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRoots.cxx index e55674788e..3f7307ebf2 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRoots.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectRoots.cxx @@ -24,7 +24,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectRoots, IFSelect_SelectExtract) IFSelect_SelectRoots::IFSelect_SelectRoots() {} -// Refait pour travailler en une fois +// Redone to work at once Interface_EntityIterator IFSelect_SelectRoots::RootResult(const Interface_Graph& G) const { @@ -32,14 +32,14 @@ Interface_EntityIterator IFSelect_SelectRoots::RootResult(const Interface_Graph& Interface_EntityIterator iter; IFGraph_Cumulate GC(G); - // On note dans le graphe : le cumul de chaque ensemble (Entite + Shared tous - // niveaux). Les Roots initiales comptees une seule fois sont bonnes + // We note in the graph: the cumulation of each set (Entity + Shared all + // levels). The initial Roots counted only once are good for (input.Start(); input.More(); input.Next()) { const Handle(Standard_Transient)& ent = input.Value(); GC.GetFromEntity(ent); } - // A present, on retient, parmi les inputs, celles comptees une seule fois + // Now, we retain, among the inputs, those counted only once for (input.Start(); input.More(); input.Next()) { const Handle(Standard_Transient)& ent = input.Value(); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectShared.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectShared.cxx index 4930263015..029d289796 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectShared.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectShared.cxx @@ -21,7 +21,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectShared, IFSelect_SelectDeduct) IFSelect_SelectShared::IFSelect_SelectShared() {} -// Entites partagees par d autres (a 1 niveau et au sens Strict) +// Entities shared by others (at 1 level and in Strict sense) Interface_EntityIterator IFSelect_SelectShared::RootResult(const Interface_Graph& G) const { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSharing.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSharing.cxx index 6b190d443b..486c64bdd4 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSharing.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSharing.cxx @@ -21,7 +21,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectSharing, IFSelect_SelectDeduct) IFSelect_SelectSharing::IFSelect_SelectSharing() {} -// Entites en partageant d autres (a 1 niveau et au sens Strict) +// Entities sharing others (at 1 level and in Strict sense) Interface_EntityIterator IFSelect_SelectSharing::RootResult(const Interface_Graph& G) const { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignature.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignature.cxx index 4b77320ab2..c017cec2fc 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignature.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignature.cxx @@ -22,10 +22,10 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SelectSignature, IFSelect_SelectExtract) -// theexact : -1 OUI 0 NON une seule valeur > 0 NON nb de valeurs -// signmode : 1 prendre si contenu, 2 refuser si contenu -// 3 prendre si egal, 4 refuser si egal -// ou test numerique, ajouter : 16 < 24 <= 32 > 40 >= +// theexact : -1 YES 0 NO single value > 0 NO number of values +// signmode: 1 take if contained, 2 refuse if contained +// 3 take if equal, 4 refuse if equal +// or numeric test, add : 16 < 24 <= 32 > 40 >= static Standard_Integer multsign(const TCollection_AsciiString& signtext, TColStd_SequenceOfAsciiString& signlist, TColStd_SequenceOfInteger& signmode) @@ -82,7 +82,7 @@ static Standard_Integer multsign(const TCollection_AsciiString& signtext, { signlist.Append(item); signmode.Append(imod); - // mode ++; valait un au depart + // mode ++; was one at start } return mode; } @@ -145,13 +145,13 @@ Standard_Boolean IFSelect_SelectSignature::SortInGraph(const Standard_Integer, return IFSelect_Signature::MatchValue(txt, thesigntext, (theexact < 0)); } - // sinon : liste - // Analyse en sequence : si alternance prend/prend-pas, le dernier a raison - // en consequence, si que des prend ou que des prend-pas, c est commutatif - // DONC recommendation : mettre les prend-pas en fin + // otherwise: list + // Sequence analysis: if take/don't-take alternation, the last one is right + // consequently, if only takes or only don't-takes, it's commutative + // THEREFORE recommendation: put the don't-takes at the end - // AU DEPART : prendre = ne prendre que. prend-pas = prend-tout-sauf ... - // Donc si le premier est un prend-pas, je commence par tout prendre + // AT START: take = take only. don't-take = take-all-except ... + // So if the first is a don't-take, I start by taking everything Standard_Integer hmod = thesignmode.Value(1); Standard_Integer jmod = hmod / 8; Standard_Integer imod = hmod - (jmod * 8); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedShared.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedShared.cxx index e279b00e63..145c4d592b 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedShared.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedShared.cxx @@ -55,13 +55,13 @@ Standard_Boolean IFSelect_SelectSignedShared::Explore(const Standard_Integer if (thematcher->Matches(ent, G.Model(), thesigntext, theexact)) return Standard_True; - // sinon, on fait le tri ici + // otherwise, we do the sorting here Interface_EntityIterator list = G.Shareds(ent); - // Si plus de Shared, alors c est cuit + // If no more Shared, then it's finished if (list.NbEntities() == 0) return Standard_False; - // Sinon, trier si on est au niveau + // Otherwise, sort if we are at the level if (level < Level()) { explored = list; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedSharing.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedSharing.cxx index 63cfb3c92a..7d9d2cbf90 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedSharing.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSignedSharing.cxx @@ -56,13 +56,13 @@ Standard_Boolean IFSelect_SelectSignedSharing::Explore(const Standard_Integer if (thematcher->Matches(ent, G.Model(), thesigntext, theexact)) return Standard_True; - // sinon, on fait le tri ici + // otherwise, we do the sorting here Interface_EntityIterator list = G.Sharings(ent); - // Si plus de Sharing, alors c est cuit + // If no more Sharing, then it's finished if (list.NbEntities() == 0) return Standard_False; - // Sinon, trier si on est au niveau + // Otherwise, sort if we are at the level if (level < Level()) { explored = list; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSuite.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSuite.cxx index 0bc77c449d..d768242584 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSuite.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SelectSuite.cxx @@ -72,8 +72,8 @@ Interface_EntityIterator IFSelect_SelectSuite::RootResult(const Interface_Graph& Standard_Boolean firstin = (HasInput() || HasAlternate()); if (firstin) iter = InputResult(G); - // Demarrage : on prend l Input/Alternate SI un des 2 est mis - // Sinon, on demarre sur la definition de base de la premiere selection + // Starting : we take the Input/Alternate IF one of the 2 is set + // Otherwise, we start on the basic definition of the first selection Standard_Integer i, nb = NbItems(); for (i = 1; i <= nb; i++) @@ -81,7 +81,7 @@ Interface_EntityIterator IFSelect_SelectSuite::RootResult(const Interface_Graph& Handle(IFSelect_SelectDeduct) anitem = Item(i); if (firstin) anitem->Alternate()->SetList(iter.Content()); - firstin = Standard_True; // ensuite c est systematique + firstin = Standard_True; // then it's systematic iter = anitem->UniqueResult(G); } return iter; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Selection.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Selection.cxx index 4c618671b4..568bafbda2 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Selection.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Selection.cxx @@ -25,7 +25,7 @@ Standard_Boolean IFSelect_Selection::HasUniqueResult() const return Standard_False; } // eminemment redefinissable -// UniqueResult, c est RootResult passe par une Map (-> mis a plat) +// UniqueResult, it is RootResult passed through a Map (-> flattened) Interface_EntityIterator IFSelect_Selection::UniqueResult(const Interface_Graph& G) const { @@ -34,20 +34,20 @@ Interface_EntityIterator IFSelect_Selection::UniqueResult(const Interface_Graph& return iter; Interface_Graph GG(G); GG.GetFromIter(iter, 0); - return Interface_GraphContent(GG); // EntityIterator specialise (meme taille) + return Interface_GraphContent(GG); // specialized EntityIterator (same size) } -// CompleteResult, c est RootResult + propagation du partage (Shareds) +// CompleteResult, it is RootResult + propagation of sharing (Shareds) Interface_EntityIterator IFSelect_Selection::CompleteResult(const Interface_Graph& G) const { Interface_EntityIterator iter = RootResult(G); - // On peut utiliser le Graphe a present + // We can use the Graph now Interface_Graph GG(G); for (iter.Start(); iter.More(); iter.Next()) { const Handle(Standard_Transient)& ent = iter.Value(); - GG.GetFromEntity(ent, Standard_True); // et voila + GG.GetFromEntity(ent, Standard_True); // and there we go } - return Interface_GraphContent(GG); // EntityIterator specialise (meme taille) + return Interface_GraphContent(GG); // specialized EntityIterator (same size) } diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionFile.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionFile.cxx index 6c86c0598b..a08f5bd098 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionFile.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionFile.cxx @@ -41,7 +41,7 @@ IFSelect_SessionFile::IFSelect_SessionFile(const Handle(IFSelect_WorkSession)& W ClearLines(); themode = Standard_False; if (!deja) - { // au moins celui-la : + { // at least this one : Handle(IFSelect_BasicDumper) basedumper = new IFSelect_BasicDumper; deja = 1; } @@ -56,7 +56,7 @@ IFSelect_SessionFile::IFSelect_SessionFile(const Handle(IFSelect_WorkSession)& W ClearLines(); themode = Standard_True; if (!deja) - { // au moins celui-la : + { // at least this one : Handle(IFSelect_BasicDumper) basedumper = new IFSelect_BasicDumper; deja = 1; } @@ -65,7 +65,7 @@ IFSelect_SessionFile::IFSelect_SessionFile(const Handle(IFSelect_WorkSession)& W thelastgen = 0; thesess = WS; thedone = (Write(filename) == 0); - // Close fait par Write (selon les cas) + // Close done by Write (depending on cases) } void IFSelect_SessionFile::ClearLines() @@ -113,8 +113,8 @@ Standard_Boolean IFSelect_SessionFile::ReadFile(const Standard_CString filename) if (!lefic) return Standard_False; ClearLines(); - // read mode : lire les lignes - // On charge le fichier dans "thelist" + // read mode : read the lines + // Load the file into "thelist" Standard_Boolean header = Standard_False; for (;;) { @@ -125,14 +125,14 @@ Standard_Boolean IFSelect_SessionFile::ReadFile(const Standard_CString filename) } if (ligne[0] == '\0') continue; - // D abord ligne initiale ? + // First initial line ? if (!header) { if (!RecognizeFile(ligne)) break; header = Standard_True; } - ligne[200] = '\0'; // fin forcee ... + ligne[200] = '\0'; // forced end ... TCollection_AsciiString onemore(ligne); thelist.Append(onemore); } @@ -157,7 +157,7 @@ Standard_Boolean IFSelect_SessionFile::RecognizeFile(const Standard_CString head sout << "Lineno." << thenl << " : File Header Description Incorrect" << std::endl; return Standard_False; } - // Value(3) definit la VERSION du format de fichier + // Value(3) defines the VERSION of the file format return Standard_True; } @@ -186,13 +186,13 @@ Standard_Integer IFSelect_SessionFile::Read(const Standard_CString filename) } // ################################################################## -// ######## WriteSession : Ecriture du contenu ######## +// ######## WriteSession : Writing the content ######## Standard_Integer IFSelect_SessionFile::WriteSession() { char laligne[200]; thedone = Standard_True; - // ... Preparation Specifique + // ... Specific Preparation thenames.Clear(); Standard_Integer nbidents = thesess->MaxIdent(); thenums = new TColStd_HArray1OfInteger(0, nbidents); @@ -205,7 +205,7 @@ Standard_Integer IFSelect_SessionFile::WriteSession() thenums->SetValue(i, -1); } - // ... ECRITURE + // ... WRITING Sprintf(laligne, "!XSTEP SESSION V1 %s", thesess->DynamicType()->Name()); WriteLine(laligne, '\n'); Sprintf(laligne, "!GENERALS"); @@ -266,8 +266,8 @@ Standard_Integer IFSelect_SessionFile::WriteSession() i = idents->Value(j); Handle(IFSelect_Selection) P = thesess->Selection(i); NewItem(i, P); - // .. Ecritures particulieres - // -> Traiter les principaux sous-types : Extract,AnyList,AnyType + // .. Particular writings + // -> Handle the main sub-types : Extract,AnyList,AnyType DeclareAndCast(IFSelect_SelectExtract, sxt, P); if (!sxt.IsNull()) { @@ -283,7 +283,7 @@ Standard_Integer IFSelect_SessionFile::WriteSession() SendItem(sli->Upper()); SetOwn(Standard_True); } - // .. Ecritures specifiques selon dumpers + // .. Specific writings according to dumpers WriteOwn(P); WriteLine("", '\n'); } @@ -315,12 +315,12 @@ Standard_Integer IFSelect_SessionFile::WriteSession() WriteLine("!MODIFIERS", '\n'); for (j = 1; j <= nb; j++) { - // Description de base des Modifiers, donc sans Selection ni Dispatch-Rank + // Basic description of Modifiers, so without Selection or Dispatch-Rank i = idents->Value(j); Handle(IFSelect_GeneralModifier) P = thesess->GeneralModifier(i); NewItem(i, P); SetOwn(Standard_True); - // .. Ecritures specifiques selon dumpers + // .. Specific writings according to dumpers WriteOwn(P); WriteLine("", '\n'); } @@ -331,12 +331,12 @@ Standard_Integer IFSelect_SessionFile::WriteSession() WriteLine("!TRANSFORMERS", '\n'); for (j = 1; j <= nb; j++) { - // Description des Transformers + // Description of Transformers i = idents->Value(j); Handle(IFSelect_Transformer) P = thesess->Transformer(i); NewItem(i, P); SetOwn(Standard_True); - // .. Ecritures specifiques selon dumpers + // .. Specific writings according to dumpers WriteOwn(P); WriteLine("", '\n'); } @@ -355,7 +355,7 @@ Standard_Integer IFSelect_SessionFile::WriteSession() SetOwn(Standard_False); SendItem(P->FinalSelection()); SetOwn(Standard_True); - // .. Ecritures specifiques selon dumpers + // .. Specific writings according to dumpers WriteOwn(P); WriteLine("", '\n'); } @@ -399,13 +399,13 @@ Standard_Integer IFSelect_SessionFile::WriteSession() WriteLine("", '\n'); } - // Pour les Modifiers, ATTENTION car il faut respecter l ORDRE effectif - // Or il y a deux listes : Model Modifiers; File Modifiers - // Les Modifiers eux-memes ont deja ete ecrits - // Ici, on ecrit simplement leur utilisation dans l envoi final + // For Modifiers, CAUTION because we must respect the effective ORDER + // Now there are two lists : Model Modifiers; File Modifiers + // The Modifiers themselves have already been written + // Here, we simply write their use in the final sending for (Standard_Integer formod = 1; formod >= 0; formod--) { - idents = thesess->FinalModifierIdents((formod > 0)); // donnes dans l ordre d application + idents = thesess->FinalModifierIdents((formod > 0)); // given in application order nb = idents->Length(); if (nb == 0) continue; @@ -419,7 +419,7 @@ Standard_Integer IFSelect_SessionFile::WriteSession() Handle(IFSelect_GeneralModifier) P = thesess->GeneralModifier(i); SetOwn(Standard_False); SendItem(P); - // .. Parametres Generaux (les specifiques ont deja ete envoyes) + // .. General Parameters (the specific ones have already been sent) SendItem(P->Selection()); SendItem(P->Dispatch()); WriteLine("", '\n'); @@ -433,7 +433,7 @@ Standard_Integer IFSelect_SessionFile::WriteSession() Standard_Integer IFSelect_SessionFile::WriteEnd() { - WriteLine("!XSTEP END", '\n'); // sinon, cf sous-types de SessionFile ... + WriteLine("!XSTEP END", '\n'); // otherwise, see SessionFile sub-types ... return 0; } @@ -470,17 +470,17 @@ Standard_Boolean IFSelect_SessionFile::WriteOwn(const Handle(Standard_Transient) } // ################################################################## -// ######## ReadSession : Lecture du contenu ######## +// ######## ReadSession : Content Reading ######## Standard_Integer IFSelect_SessionFile::ReadSession() { Message_Messenger::StreamBuffer sout = Message::SendInfo(); thedone = Standard_True; - // ... Preparation Specifique + // ... Specific Preparation thenums.Nullify(); thenames.Clear(); - // .. Donnees generales, controle + // .. General data, control if (!ReadLine()) return 1; if (theline.Length() != 4) @@ -495,11 +495,11 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : File Header Description Incorrect" << std::endl; return 1; } - // Value(3) definit la VERSION du format de fichier + // Value(3) defines the VERSION of the file format if (!ReadLine()) return 1; - // .. Parametres Generaux + // .. General Parameters Standard_Integer rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!GENERALS")); while (rubr) { @@ -509,7 +509,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() continue; const TCollection_AsciiString& ungen = theline.Value(1); if (ungen.Value(1) == '!') - break; // fin des generaux + break; // end of generals if (ungen.IsEqual("ErrorHandle")) { if (theline.Length() != 2) @@ -535,7 +535,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() } // .. IntParams - // deja fait if (!ReadLine()) return 1; + // already done if (!ReadLine()) return 1; rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!INTEGERS")); while (rubr) { @@ -553,7 +553,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() AddItem(par); } - // .. TextParams (ligne de garde deja lue) + // .. TextParams (guard line already read) rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!TEXTS")); while (rubr) { @@ -566,7 +566,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Text Parameter is badly defined" << std::endl; continue; } - // Attention, un texte peut contenir des blancs ... repartir de line(thenl) + // Caution, a text can contain blanks ... restart from line(thenl) TCollection_AsciiString oneline = thelist.Value(thenl); Standard_Integer iw = 0, inc = 0; for (Standard_Integer ic = 1; ic <= oneline.Length(); ic++) @@ -582,7 +582,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() AddItem(new TCollection_HAsciiString(oneline.ToCString())); } - // .. Selections (ligne de garde deja lue) + // .. Selections (guard line already read) rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!SELECTIONS")); while (rubr) { @@ -595,7 +595,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Selection is badly defined" << std::endl; continue; } - // .. Analyse de certains cas generaux + // .. Analysis of certain general cases Handle(IFSelect_IntParam) low, up; Standard_Integer firstown = 3; Standard_Integer direct = 0; @@ -620,7 +620,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() } SetLastGeneral(firstown - 1); } - Handle(Standard_Transient) item; // a fournir ... + Handle(Standard_Transient) item; // to be provided ... ReadOwn(item); if (item.IsNull()) continue; @@ -663,7 +663,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() continue; } Standard_Integer nbs = atoi(theline.Value(2).ToCString()); - // .. Differents cas reconnus + // .. Different recognized cases DeclareAndCast(IFSelect_SelectExtract, sxt, sel); if (!sxt.IsNull()) { @@ -698,7 +698,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() } } - // ... Modifiers en tout genre + // ... Modifiers of all kinds rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!MODIFIERS")); while (rubr) { @@ -711,7 +711,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Modifier is badly defined" << std::endl; continue; } - Handle(Standard_Transient) item; // a fournir ... + Handle(Standard_Transient) item; // to be provided ... ReadOwn(item); if (item.IsNull()) continue; @@ -721,7 +721,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Modifier has not been Recognized" << std::endl; continue; } - AddItem(modif, Standard_False); // active plus tard + AddItem(modif, Standard_False); // active later } // ... Transformers @@ -737,7 +737,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Transformer is badly defined" << std::endl; continue; } - Handle(Standard_Transient) item; // a fournir ... + Handle(Standard_Transient) item; // to be provided ... ReadOwn(item); if (item.IsNull()) continue; @@ -747,10 +747,10 @@ Standard_Integer IFSelect_SessionFile::ReadSession() sout << "Lineno." << thenl << " : A Transformer has not been Recognized" << std::endl; continue; } - AddItem(trf, Standard_False); // active plus tard + AddItem(trf, Standard_False); // active later } - // ... Dispatches (ligne de garde deja lue) + // ... Dispatches (guard line already read) rubr = (theline.Length() == 1 && theline.Value(1).IsEqual("!DISPATCHES")); while (rubr) { @@ -765,7 +765,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() } DeclareAndCast(IFSelect_Selection, input, ItemValue(3)); SetLastGeneral(3); - Handle(Standard_Transient) item; // a fournir ... + Handle(Standard_Transient) item; // to be provided ... ReadOwn(item); if (item.IsNull()) continue; @@ -779,8 +779,8 @@ Standard_Integer IFSelect_SessionFile::ReadSession() thesess->SetItemSelection(disp, input); } - // ... FileNaming (ligne de garde deja lue) - // .. Modifiers deja lus et charges + // ... FileNaming (guard line already read) + // .. Modifiers already read and loaded rubr = (theline.Length() == 4 && theline.Value(1).IsEqual("!FILENAMING")); if (rubr) { @@ -806,8 +806,8 @@ Standard_Integer IFSelect_SessionFile::ReadSession() thesess->SetFileRoot(disp, theline.Value(2).ToCString()); } - // ... Modifiers (ligne de garde deja lue) - // ... Attention, deux listes (MODELMODIFIERS et FILEMODIFIERS) + // ... Modifiers (guard line already read) + // ... Caution, two lists (MODELMODIFIERS and FILEMODIFIERS) for (Standard_Integer formod = 1; formod >= 0; formod--) { rubr = (theline.Length() == 1 @@ -846,7 +846,7 @@ Standard_Integer IFSelect_SessionFile::ReadSession() } } - // ... Conclusion : voir ReadEnd (separe) + // ... Conclusion: see ReadEnd (separate) return 0; } @@ -868,7 +868,7 @@ Standard_Boolean IFSelect_SessionFile::ReadLine() return Standard_False; thenl++; Standard_CString ligne = thelist.Value(thenl).ToCString(); - // Lignes vides ? + // Empty lines? if (ligne[0] == '\0') return ReadLine(); SplitLine(ligne); @@ -916,7 +916,7 @@ Standard_Boolean IFSelect_SessionFile::ReadOwn(Handle(Standard_Transient)& item) return Standard_False; const TCollection_AsciiString& type = theline.Value(2); if (thelastgen < 2) - thelastgen = 2; // mini : ident+type d abord + thelastgen = 2; // mini : ident+type first // thelastgen = theline.Length(); // for (Standard_Integer i = theline.Length(); i > 0; i --) { // if (theline.Value(i).Value(1) == ':') thelastgen = i - 1; @@ -965,7 +965,7 @@ Handle(IFSelect_WorkSession) IFSelect_SessionFile::WorkSession() const return thesess; } -// ######## Actions Unitaires d ECRITURE ######## +// ######## Unit WRITING Actions ######## void IFSelect_SessionFile::NewItem(const Standard_Integer ident, const Handle(Standard_Transient)& par) @@ -1028,7 +1028,7 @@ void IFSelect_SessionFile::SendText(const Standard_CString text) WriteLine(laligne); } -// ######## Actions Unitaires de LECTURE ######## +// ######## Unit READING Actions ######## void IFSelect_SessionFile::SetLastGeneral(const Standard_Integer lastgen) { @@ -1108,4 +1108,4 @@ Handle(Standard_Transient) IFSelect_SessionFile::ItemValue(const Standard_Intege return thesess->Item(id); } -void IFSelect_SessionFile::Destroy() {} // agit si File non ferme, sinon ne fait rien +void IFSelect_SessionFile::Destroy() {} // acts if File not closed, otherwise does nothing diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionPilot.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionPilot.cxx index c5589ede17..0d160701c8 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionPilot.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SessionPilot.cxx @@ -36,7 +36,7 @@ static TCollection_AsciiString nulword; // #define DEBUG_TRACE -// Nb Maxi de words : cf thewords et method SetCommandLine +// Max Nb of words : cf thewords and method SetCommandLine IFSelect_SessionPilot::IFSelect_SessionPilot(const Standard_CString prompt) : theprompt(prompt), @@ -100,7 +100,7 @@ void IFSelect_SessionPilot::SetCommandLine(const TCollection_AsciiString& comman { Standard_Integer lc = command.Length(); if (lc > 200) - std::cout << " Commande TRES LONGUE : " << lc << " caracteres :" << std::endl + std::cout << " VERY LONG Command : " << lc << " characters :" << std::endl << command.ToCString() << std::endl; thecommand = command; if (thecommand.Value(lc) <= ' ') @@ -151,12 +151,12 @@ void IFSelect_SessionPilot::SetCommandLine(const TCollection_AsciiString& comman thewords(thenbwords).AssignCat(unarg); #ifdef DEBUG_TRACE std::cout << "thewords(" << thenbwords << ")=" << unarg << std::endl - << " .. Fin avec thenbwords=" << thenbwords + 1 << std::endl; + << " .. End with thenbwords=" << thenbwords + 1 << std::endl; #endif thenbwords++; } /* - aligner sur MAXWORDS + align on MAXWORDS char l0[80],l1[80],l2[80],l3[80],l4[80],l5[80],l6[80],l7[80],l8[80],l9[80]; char m0[80],m1[80],m2[80],m3[80],m4[80],m5[80],m6[80],m7[80],m8[80],m9[80]; thenbwords = sscanf @@ -237,14 +237,14 @@ Standard_Boolean IFSelect_SessionPilot::RemoveWord(const Standard_Integer num) } thewords(thenbwords).Clear(); thenbwords--; - // Et refaire thecommand. Si num = 0, on supprime le debut (facile) + // And redo thecommand. If num = 0, we remove the beginning (easy) if (num == 0) { thecommand.Remove(1, thewordeb(1)); } else { - // Sinon, reconstituer, a partir des words + // Otherwise, reconstitute, from the words thecommand.Clear(); for (i = 0; i < thenbwords; i++) { @@ -284,7 +284,7 @@ void IFSelect_SessionPilot::Clear() } // ####################################################################### -// ######## CONTROLE D EXECUTION +// ######## EXECUTION CONTROL IFSelect_ReturnStatus IFSelect_SessionPilot::ReadScript(const Standard_CString file) { @@ -318,10 +318,10 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::ReadScript(const Standard_CString f } if (ligne[0] == '\0') continue; - // On interprete cette commande + // We interpret this command TCollection_AsciiString command(ligne); if (lefic) - std::cout << file << ":" << command; // le return est dans la ligne ... ! + std::cout << file << ":" << command; // the return is in the line ... ! stat = Execute(command); if (stat == IFSelect_RetStop) break; @@ -337,10 +337,10 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::ReadScript(const Standard_CString f std::cout << "End of Reading Script File " << file << std::endl; if (stat == IFSelect_RetError || stat == IFSelect_RetFail) return stat; - return IFSelect_RetVoid; // fin fichier : depiler + return IFSelect_RetVoid; // end file : unstack } -// On boucle sur la lecture jusqu a une commande de fin ou un EOF +// We loop on reading until an end command or an EOF IFSelect_ReturnStatus IFSelect_SessionPilot::Perform() { @@ -348,22 +348,22 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Perform() if (thenbwords == 0) return stat; if (thewords(0).Value(1) == '#') - return stat; // commentaire + return stat; // comment theobjrec.Nullify(); - // Est-ce un nom ? + // Is it a name ? - // Commande pour un Acteur + // Command for an Actor Handle(IFSelect_Activator) actor; Standard_Integer num; if (IFSelect_Activator::Select(thewords(0).ToCString(), num, actor)) { stat = actor->Do(num, this); - // Prise en compte des commandes a resultat - // Ici, resultat non nomme; Resultat nomme par commande x (plus loin) + // Taking into account commands with result + // Here, unnamed result; Result named by command x (further) if (!theobjrec.IsNull()) { - thesession->RemoveItem(theobjrec); //// depannage ? + thesession->RemoveItem(theobjrec); //// troubleshooting ? Standard_Integer addws = thesession->AddItem(theobjrec); if (addws == 0) { @@ -384,7 +384,7 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Perform() return stat; } std::cout << " Command : " << thewords(0) << " unknown" << std::endl; - return IFSelect_RetError; // pas reconnu donc incorrect + return IFSelect_RetError; // not recognized therefore incorrect } IFSelect_ReturnStatus IFSelect_SessionPilot::ExecuteAlias(const TCollection_AsciiString& alias) @@ -412,7 +412,7 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::ExecuteCounter( counter->AddModel(thesession->Model()); else { - // on demande un givelist + // we request a givelist Handle(TColStd_HSequenceOfTransient) list = thesession->GiveList(CommandPart(numword)); if (list.IsNull()) { @@ -443,7 +443,7 @@ Standard_Integer IFSelect_SessionPilot::Number(const Standard_CString val) const IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer number, const Handle(IFSelect_SessionPilot)& session) { - // Commandes Propres : x, exit, undo, redo, ?, help + // Own Commands : x, exit, undo, redo, ?, help IFSelect_ReturnStatus stat = IFSelect_RetVoid; Standard_Integer argc = NbWords(); const Standard_CString arg1 = Word(1).ToCString(); @@ -453,17 +453,17 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer case -1: // **** HELP-XSNEW modhelp = 1; std::cout << " -- Commands candidate for xsnew --" << std::endl; - // HELP : soit complet (par defaut) soit limite a xsnew + // HELP : either complete (by default) or limited to xsnew Standard_FALLTHROUGH case 0: { // **** HELP Handle(TColStd_HSequenceOfAsciiString) list; - // Help complet : on donne la liste des commandes, sans plus (deja pas mal) + // Complete Help : we give the list of commands, nothing more (already not bad) if (thenbwords <= 1) { list = IFSelect_Activator::Commands(modhelp); Standard_Integer nbcom = 0; Standard_Integer nb = list->Length(); - std::cout << " -- Liste des Commands Disponibles --" << std::endl; + std::cout << " -- List of Available Commands --" << std::endl; for (Standard_Integer i = 1; i <= nb; i++) { const TCollection_AsciiString& uncom = list->Value(i); @@ -482,11 +482,11 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer } if (nbcom > 0) std::cout << std::endl; - std::cout << "\nhelp * liste toutes les commandes avec un help sur chacune\n" - << "help liste la ou les commande debutant par " - << " avec un help sur chacune" << std::endl; + std::cout << "\nhelp * lists all commands with help on each\n" + << "help lists the command(s) starting with " + << " with help on each" << std::endl; - // Un Help particulier + // A particular Help } else { @@ -515,17 +515,16 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer return IFSelect_RetVoid; } case 1: - return IFSelect_RetStop; // **** Fin de session + return IFSelect_RetStop; // **** End of session case 2: { // **** HELP return Do(0, this); } case 3: { // **** COMMAND if (argc < 2) { - std::cout << "Donner une option :\n" - << "a : analyse une ligne r : toggle record mode\n" - << "l : list recorded c : clear f nom : sauver dans fichier de nom" - << std::endl; + std::cout << "Give an option :\n" + << "a : analyze a line r : toggle record mode\n" + << "l : list recorded c : clear f name : save in file of name" << std::endl; return IFSelect_RetVoid; } switch (arg1[0]) @@ -545,16 +544,16 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer case 'f': { if (argc < 3) { - std::cout << "Donner nom de fichier" << std::endl; + std::cout << "Give file name" << std::endl; return IFSelect_RetError; } Standard_Integer nb = session->NbCommands(); if (nb == 0) { - std::cout << "Aucune commande enregistree" << std::endl; + std::cout << "No command recorded" << std::endl; break; } - std::cout << "Nb Commandes enregistrees : " << nb << std::endl; + std::cout << "Nb Recorded Commands : " << nb << std::endl; std::ofstream fout(Word(2).ToCString(), std::ios::out); for (Standard_Integer i = 1; i <= nb; i++) fout << session->Command(i) << std::endl; @@ -562,11 +561,11 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer } case 'l': { // **** command list if (session->RecordMode()) - std::cout << " -- Record Mode Actif" << std::endl; + std::cout << " -- Record Mode Active" << std::endl; else - std::cout << " -- Record Mode Inactif" << std::endl; + std::cout << " -- Record Mode Inactive" << std::endl; Standard_Integer nb = session->NbCommands(); - std::cout << "Nb Commandes enregistrees : " << nb << " :" << std::endl; + std::cout << "Nb Recorded Commands : " << nb << " :" << std::endl; for (Standard_Integer i = 1; i <= nb; i++) { std::cout << " " << i << " " << session->Command(i) << std::endl; @@ -576,14 +575,14 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer case 'r': { // **** command record Standard_Boolean mode = session->RecordMode(); if (mode) - std::cout << " -- Record Mode a present Inactif" << std::endl; + std::cout << " -- Record Mode now Inactive" << std::endl; else - std::cout << " -- Record Mode a present Actif" << std::endl; + std::cout << " -- Record Mode now Active" << std::endl; session->SetRecordMode(!mode); break; } default: - std::cout << "Option de controle de commande non comprise" << std::endl; + std::cout << "Command control option not understood" << std::endl; } return IFSelect_RetVoid; } @@ -591,18 +590,18 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer case 4: { // **** FILE if (argc < 2) { - std::cout << "Donner nom de fichier" << std::endl; + std::cout << "Give file name" << std::endl; return IFSelect_RetError; } return session->ReadScript(TCollection_AsciiString(session->Word(1)).ToCString()); - // On recopie la string parce que Word(1) change tout le temps ! + // We copy the string because Word(1) changes all the time ! } case 5: { // **** XSTEP if (argc < 2) { - std::cout << "xstep : prefixe neutre pour toute commande xstep-draw" << std::endl - << "xstep command args equivaut a command args" << std::endl; + std::cout << "xstep : neutral prefix for any xstep-draw command" << std::endl + << "xstep command args equivalent to command args" << std::endl; return Do(2, this); } else @@ -614,8 +613,8 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer case 6: { // **** XSNEW(variable) if (argc < 3) { - std::cout << "xsnew nomvar command [args] creates an item" << std::endl - << " nomvar : name of item (must be a new name) in the session" << std::endl; + std::cout << "xsnew varname command [args] creates an item" << std::endl + << " varname : name of item (must be a new name) in the session" << std::endl; return Do(-1, this); } else @@ -623,7 +622,7 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer theobjrec.Nullify(); TCollection_AsciiString name = Word(1); - // Le nom ne doit pas etre deja pris ! + // The name must not be already taken ! if (thesession.IsNull()) { std::cout << "Command with a Name and no Session defined !" << std::endl; @@ -635,17 +634,17 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer RemoveWord(0); RemoveWord(0); - // Commande pour un Acteur + // Command for an Actor Handle(IFSelect_Activator) actor; Standard_Integer num; if (IFSelect_Activator::Select(thewords(0).ToCString(), num, actor)) { theobjrec.Nullify(); stat = actor->Do(num, this); - // Prise en compte des commandes a resultat + // Taking into account commands with result if (!theobjrec.IsNull()) { - thesession->RemoveItem(theobjrec); //// depannage ? + thesession->RemoveItem(theobjrec); //// troubleshooting ? Standard_Integer addws = thesession->AddNamedItem(name.ToCString(), theobjrec); theobjrec.Nullify(); if (addws == 0) @@ -660,7 +659,7 @@ IFSelect_ReturnStatus IFSelect_SessionPilot::Do(const Standard_Integer return stat; } std::cout << " Command : " << thewords(0) << " unknown" << std::endl; - return IFSelect_RetError; // pas reconnu donc incorrect + return IFSelect_RetError; // not recognized therefore incorrect } } default: @@ -673,17 +672,17 @@ Standard_CString IFSelect_SessionPilot::Help(const Standard_Integer number) cons switch (number) { case 1: - return "exit ou x : Fin de session"; + return "exit or x : End of session"; case 2: - return "Liste les commandes. ? : commandes debutant par "; + return "Lists the commands. ? : commands starting with <title>"; case 3: - return "controle de commande. command tout court pour help complet"; + return "command control. command alone for complete help"; case 4: - return "lit les commandes depuis un fichier"; + return "reads commands from a file"; case 5: - return "prefixe neutre pour xstep-draw"; + return "neutral prefix for xstep-draw"; case 6: - return "creation item : donner nom_item puis commande args"; + return "item creation : give item_name then command args"; default: return ""; } diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOut.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOut.cxx index b5a486c8e1..97f1af49f3 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOut.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOut.cxx @@ -74,7 +74,7 @@ void IFSelect_ShareOut::SetLastRun(const Standard_Integer lastrun) } // ####################################################################### -// #### DISPATCHES (ENVOI DES FICHIERS) #### +// #### DISPATCHES (FILE SENDING) #### Standard_Integer IFSelect_ShareOut::NbDispatches() const { @@ -218,8 +218,8 @@ Standard_Boolean IFSelect_ShareOut::RemoveModifier(const Standard_Boolean formod return Standard_True; } -// ChangeModifierRank revient a une permutation circulaire : -// before est mis en after, ceux qui sont entre tournent +// ChangeModifierRank amounts to a circular permutation : +// before is put in after, those that are between rotate Standard_Boolean IFSelect_ShareOut::ChangeModifierRank(const Standard_Boolean formodel, const Standard_Integer before, const Standard_Integer after) @@ -257,8 +257,8 @@ Standard_Boolean IFSelect_ShareOut::ChangeModifierRank(const Standard_Boolean fo } // ####################################################################### -// #### NOMINATION DES FICHIERS #### -// Rq : thenbdefs s applique tant que l on ne change pas les termes principaux +// #### FILE NAMING #### +// Note : thenbdefs applies as long as we don't change the main terms Standard_Boolean IFSelect_ShareOut::SetRootName(const Standard_Integer num, const Handle(TCollection_HAsciiString)& name) @@ -364,7 +364,7 @@ TCollection_AsciiString IFSelect_ShareOut::FileName(const Standard_Integer dnum, thenbdefs++; num = thenbdefs; npac = 0; - sufnum = Standard_True; // numeroter sur noms par defaut, des le 1er sans 0 + sufnum = Standard_True; // number on default names, from the 1st without 0 } TCollection_AsciiString res; @@ -375,13 +375,13 @@ TCollection_AsciiString IFSelect_ShareOut::FileName(const Standard_Integer dnum, // Suffixe numerique if (sufnum) - { // sinon, pas de suffixe numerique - // Nom du PacketSuffix : _ suivi du numero <num> - // Si nbpack non nul, alors on a un majorant et on peut preceder de zeros - // Ex.: nbpack = 50 (donc 2 chiffres), num = 3, cela donnera _03 - // idnum pas utilise : cette methode peut etre redefinie et utiliser idnum ... - // Si nbpack = 0 ou 1, num = 1 pas de suffixe, sinon suffixe "_num" tel quel - // MODIF du 3-NOV-1995 -> pour eviter toute confusion, num = 1 donne aussi _1 + { // otherwise, no numeric suffix + // PacketSuffix name : _ followed by number <num> + // If nbpack non-zero, then we have an upper bound and we can precede with zeros + // Ex.: nbpack = 50 (so 2 digits), num = 3, this will give _03 + // idnum not used : this method can be redefined and use idnum ... + // If nbpack = 0 or 1, num = 1 no suffix, otherwise suffix "_num" as is + // MODIF of 3-NOV-1995 -> to avoid any confusion, num = 1 also gives _1 Standard_Integer nbch = 0; char format[30], suffixe[30]; format[1] = ' '; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOutResult.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOutResult.cxx index 3224ba4386..913c3bdbb4 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOutResult.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_ShareOutResult.cxx @@ -79,7 +79,7 @@ void IFSelect_ShareOutResult::Reset() void IFSelect_ShareOutResult::Evaluate() { if (theeval) - return; // deja fait. si pas OK, faire Reset avant + return; // already done. if not OK, do Reset before Prepare(); theeval = Standard_True; } @@ -134,14 +134,14 @@ void IFSelect_ShareOutResult::Prepare() if (iter.NbEntities() == 0) continue; thedispres.AddPart(); - thedispres.GetFromIter(iter); // on enregistre ce paquet + thedispres.GetFromIter(iter); // we register this packet A.ResetData(); A.GetFromIter(iter); - thedisplist.Append(i); // n0 du dispatch producteur + thedisplist.Append(i); // n0 of producer dispatch } } thedispnum = thepacknum = 1; - thepackdisp = 1; // calcul sur 1er Dispatch + thepackdisp = 1; // calculation on 1st Dispatch thenbindisp = 0; for (i = thepacknum; i <= thedisplist.Length(); i++) { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCategory.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCategory.cxx index f4ff3cc098..a19db880b3 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCategory.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCategory.cxx @@ -24,7 +24,7 @@ static Standard_CString nulsign = ""; IFSelect_SignCategory::IFSelect_SignCategory() : IFSelect_Signature("Category") { - Interface_Category::Init(); // si pas deja fait + Interface_Category::Init(); // if not already done Standard_Integer i, nb = Interface_Category::NbCategories(); for (i = 1; i <= nb; i++) AddCase(Interface_Category::Name(i)); diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCounter.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCounter.cxx index 07010c43de..6817e2ed04 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCounter.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignCounter.cxx @@ -72,7 +72,7 @@ void IFSelect_SignCounter::AddSign(const Handle(Standard_Transient)& ent, char nulsign[2]; nulsign[0] = '\0'; if (ent.IsNull() || thematcher.IsNull()) - Add(ent, nulsign); // pour compter les Nuls + Add(ent, nulsign); // to count the Nulls else Add(ent, thematcher->Value(ent, model)); } @@ -98,7 +98,7 @@ void IFSelect_SignCounter::AddModel(const Handle(Interface_InterfaceModel)& mode if (model.IsNull()) return; Standard_Integer nb = model->NbEntities(); - // Si on part de vide, on sait que chque entite est unique dans le modele + // If we start from empty, we know that each entity is unique in the model Standard_Boolean mapstat = themapstat; if (themap.Extent() == 0) themapstat = Standard_False; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignMultiple.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignMultiple.cxx index d639af8440..4543f22a87 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignMultiple.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignMultiple.cxx @@ -19,7 +19,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_SignMultiple, IFSelect_Signature) -static TCollection_AsciiString theval; // temporaire pour construire Value +static TCollection_AsciiString theval; // temporary to build Value IFSelect_SignMultiple::IFSelect_SignMultiple(const Standard_CString name) : IFSelect_Signature(name) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Signature.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Signature.cxx index 43c3ef1d5c..f7b6c78ae4 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Signature.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Signature.cxx @@ -119,7 +119,7 @@ Standard_Boolean IFSelect_Signature::MatchValue(const Standard_CString v { if (val[i] == cardeb) { - // un candidat + // a candidate Standard_Boolean res = Standard_True; for (j = 1; j < ln; j++) { diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignatureList.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignatureList.cxx index 0a7aec8a18..a05f412b95 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignatureList.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_SignatureList.cxx @@ -260,7 +260,7 @@ void IFSelect_SignatureList::PrintSum(Standard_OStream& S) const if (nbent > maxent) maxent = nbent; const TCollection_AsciiString& name = iter.Key(); - // if (!name.IsIntegerValue()) continue; pas bien fiable + // if (!name.IsIntegerValue()) continue; not very reliable Standard_Integer ic, nc = name.Length(); Standard_Boolean iaint = Standard_True; for (ic = 1; ic <= nc; ic++) diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_TransformStandard.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_TransformStandard.cxx index e6d5021e85..0d9f921b0b 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_TransformStandard.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_TransformStandard.cxx @@ -174,11 +174,11 @@ Standard_Boolean IFSelect_TransformStandard::ApplyModifiers( if (unmod->MayChangeGraph()) chg = Standard_True; - // Appliquer ce Modifier (nb : le Dispatch, on s en moque) - // D abord, la Selection + // Apply this Modifier (nb : the Dispatch, we don't care about it) + // First, the Selection IFSelect_ContextModif ctx(G, TC); - // Ensuite, la Selection - // S il y en a une ici, elle a priorite. Sinon, chaque Modifier a la sienne + // Then, the Selection + // If there is one here, it has priority. Otherwise, each Modifier has its own Handle(IFSelect_Selection) sel = thesel; if (sel.IsNull()) @@ -192,8 +192,8 @@ Standard_Boolean IFSelect_TransformStandard::ApplyModifiers( continue; unmod->Perform(ctx, newmod, protocol, TC); - // Report des Erreurs - // Faut-il les enregistrer dans newmod ? bonne question + // Error Reporting + // Should we record them in newmod ? good question Interface_CheckIterator checklist = ctx.CheckList(); if (!checklist.IsEmpty(Standard_False)) { @@ -210,7 +210,7 @@ Standard_Boolean IFSelect_TransformStandard::ApplyModifiers( } } - // Modele pas modifie et Graphe pas modifie : le dire + // Model not modified and Graph not modified: say it if (newmod == original && !chg) newmod.Nullify(); return res; diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Transformer.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Transformer.cxx index f17177d5c7..de6bf01365 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_Transformer.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_Transformer.cxx @@ -23,5 +23,5 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_Transformer, Standard_Transient) Standard_Boolean IFSelect_Transformer::ChangeProtocol(Handle(Interface_Protocol)&) const { - return Standard_False; // par defaut, protocole inchange + return Standard_False; // by default, protocol unchanged } diff --git a/src/DataExchange/TKXSBase/IFSelect/IFSelect_WorkSession.cxx b/src/DataExchange/TKXSBase/IFSelect/IFSelect_WorkSession.cxx index f74b33f764..d7db8bd590 100644 --- a/src/DataExchange/TKXSBase/IFSelect/IFSelect_WorkSession.cxx +++ b/src/DataExchange/TKXSBase/IFSelect/IFSelect_WorkSession.cxx @@ -72,7 +72,7 @@ IMPLEMENT_STANDARD_RTTIEXT(IFSelect_WorkSession, Standard_Transient) #define Flag_Incorrect 2 // (Bit Map n0 2) -static Standard_Boolean errhand; // pb : un seul a la fois, mais ca va si vite +static Standard_Boolean errhand; // pb : only one at a time, but it goes so fast static TCollection_AsciiString bufstr; // ################################################################# @@ -130,7 +130,7 @@ void IFSelect_WorkSession::SetShareOut(const Handle(IFSelect_ShareOut)& shareout { theshareout = shareout; thecopier->SetShareOut(theshareout); - // ... faudrait ajouter les Params, Dispatches, etc... + // ... should add Params, Dispatches, etc... } //================================================================================================= @@ -146,11 +146,11 @@ void IFSelect_WorkSession::SetModel(const Handle(Interface_InterfaceModel)& mode myModel->SetGTool(thegtool); thegraph.Nullify(); - ComputeGraph(); // fait qqchose si Protocol present. Sinon, ne fait rien - ClearData(3); // RAZ CheckList, a refaire + ComputeGraph(); // does something if Protocol present. Otherwise, does nothing + ClearData(3); // Reset CheckList, to be redone thecheckrun.Clear(); - // MISE A JOUR des SelectPointed C-A-D on efface leur contenu + // UPDATE of SelectPointed I.E. clear their content if (clearpointed) ClearData(4); ClearData(0); @@ -180,7 +180,7 @@ IFSelect_ReturnStatus IFSelect_WorkSession::ReadFile(const Standard_CString file catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption ReadFile par Exception : ****\n"; + sout << " **** ReadFile Interruption by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; status = IFSelect_RetFail; @@ -219,7 +219,7 @@ IFSelect_ReturnStatus IFSelect_WorkSession::ReadStream(const Standard_CString th catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption ReadFile par Exception : ****\n"; + sout << " **** ReadFile Interruption by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; status = IFSelect_RetFail; @@ -244,7 +244,7 @@ Standard_Integer IFSelect_WorkSession::NbStartingEntities() const Handle(Standard_Transient) IFSelect_WorkSession::StartingEntity(const Standard_Integer num) const { - Handle(Standard_Transient) res; // Null par defaut + Handle(Standard_Transient) res; // Null by default if (myModel.IsNull()) return res; if (num < 1 || num > myModel->NbEntities()) @@ -266,8 +266,8 @@ Standard_Integer IFSelect_WorkSession::NumberFromLabel(const Standard_CString va { Standard_Integer i, cnt = 0, num = atoi(val); if (num > 0 || myModel.IsNull()) - return num; // un n0 direct : gagne ! - // Sinon, on considere que c est un label; a traiter en CaseNonSensitive ... + return num; // a direct n0 : won ! + // Otherwise, consider it as a label; to be treated in CaseNonSensitive ... if (num > myModel->NbEntities()) { num = 0; @@ -367,9 +367,9 @@ void IFSelect_WorkSession::ClearData(const Standard_Integer mode) break; } case 4: { - // MISE A JOUR des SelectPointed C-A-D on efface leur contenu - // AINSI que des editeurs (en fait, les EditForm) - // Des compteurs C-A-D on efface leur contenu (a reevaluer) + // UPDATE of SelectPointed I.E. clear their content + // AS WELL AS editors (in fact, the EditForm) + // Counters I.E. we erase their content (to reevaluate) Handle(TColStd_HSequenceOfInteger) list = ItemIdents(STANDARD_TYPE(IFSelect_SelectPointed)); Standard_Integer nb = list->Length(); Standard_Integer i; // svv #1 @@ -424,7 +424,7 @@ Standard_Boolean IFSelect_WorkSession::ComputeGraph(const Standard_Boolean enfor } if (myModel->NbEntities() == 0) return Standard_False; - // Il faut calculer le graphe pour de bon + // We must calculate the graph for good thegraph = new Interface_HGraph(myModel, themodelstat); Standard_Integer nb = myModel->NbEntities(); if (themodelstat) @@ -440,7 +440,7 @@ Standard_Boolean IFSelect_WorkSession::ComputeGraph(const Standard_Boolean enfor thecheckdone = Standard_True; if (themodelstat) { - // Calcul des categories, a present memorisees dans le modele + // Calculation of categories, now memorized in the model Interface_Category categ(thegtool); Interface_ShareTool sht(thegraph); Standard_Integer i = 1; @@ -529,7 +529,7 @@ Standard_Boolean IFSelect_WorkSession::ComputeCheck(const Standard_Boolean enfor myModel->FillSemanticChecks(checklist, Standard_False); if (themodelstat) { - // Et on met a jour le Graphe (BitMap) ! Flag Incorrect (STX + SEM) + // And we update the Graph (BitMap) ! Flag Incorrect (STX + SEM) Interface_BitMap& BM = CG.CBitMap(); BM.Init(Standard_False, Flag_Incorrect); Standard_Integer num, nb = CG.Size(); @@ -594,7 +594,7 @@ Interface_CheckIterator IFSelect_WorkSession::CheckOne(const Handle(Standard_Tra } // ##################################################################### -// .... LES VARIABLES .... +// .... THE VARIABLES .... //================================================================================================= @@ -637,7 +637,7 @@ Handle(Standard_Transient) IFSelect_WorkSession::NamedItem(const Standard_CStrin if (name[0] == '\0') return res; if (name[0] == '#') - { // #nnn : pas un nom mais un n0 id. + { // #nnn : not a name but an id number Standard_Integer id = atoi(&name[1]); return Item(id); } @@ -665,7 +665,7 @@ Standard_Integer IFSelect_WorkSession::NameIdent(const Standard_CString name) co if (name[0] == '\0') return 0; if (name[0] == '#') - { // #nnn : pas un nom mais un n0 id. + { // #nnn : not a name but an id number Standard_Integer id = atoi(&name[1]); return id; } @@ -721,7 +721,7 @@ Standard_Integer IFSelect_WorkSession::AddItem(const Handle(Standard_Transient)& else id = theitems.Add(item, item); - // Cas particuliers : Dispatch,Modifier + // Special cases : Dispatch,Modifier if (active) SetActive(item, Standard_True); return id; @@ -737,8 +737,8 @@ Standard_Integer IFSelect_WorkSession::AddNamedItem(const Standard_CString return 0; if (name[0] == '#' || name[0] == '!') return 0; - // #nnn : pas un nom mais un numero. !... : reserve (interdit pour un nom) - // nom deja pris : on ecrase l ancienne valeur + // #nnn : not a name but a number. !... : reserved (forbidden for a name) + // name already taken : we overwrite the old value if (name[0] != '\0') thenames.Bind(name, item); @@ -750,7 +750,7 @@ Standard_Integer IFSelect_WorkSession::AddNamedItem(const Standard_CString att = item; if (name[0] != '\0') { - // if (!att->IsKind(STANDARD_TYPE(TCollection_HAsciiString))) ecrasement admis ! + // if (!att->IsKind(STANDARD_TYPE(TCollection_HAsciiString))) overwriting allowed ! att = new TCollection_HAsciiString(name); } } @@ -759,7 +759,7 @@ Standard_Integer IFSelect_WorkSession::AddNamedItem(const Standard_CString else id = theitems.Add(item, item); - // Cas particuliers : Dispatch,Modifier + // Special cases : Dispatch,Modifier if (active) SetActive(item, Standard_True); return id; @@ -788,7 +788,7 @@ Standard_Boolean IFSelect_WorkSession::SetActive(const Handle(Standard_Transient if (num <= theshareout->LastRun()) return Standard_False; theshareout->RemoveDispatch(num); - SetFileRoot(disp, ""); // si onlynamed : nettoie aussi ShareOut + SetFileRoot(disp, ""); // if onlynamed : also cleans ShareOut return Standard_True; } } @@ -804,7 +804,7 @@ Standard_Boolean IFSelect_WorkSession::RemoveNamedItem(const Standard_CString na if (item.IsNull()) return Standard_False; if (!RemoveItem(item)) - return Standard_False; // qui se charge de tout + return Standard_False; // which takes care of everything return Standard_True; } @@ -815,7 +815,7 @@ Standard_Boolean IFSelect_WorkSession::RemoveName(const Standard_CString name) Handle(Standard_Transient) item = NamedItem(name); if (item.IsNull()) return Standard_False; - theitems.Add(item, item); // reste mais sans nom + theitems.Add(item, item); // remains but without name return thenames.UnBind(name); } @@ -830,12 +830,12 @@ Standard_Boolean IFSelect_WorkSession::RemoveItem(const Handle(Standard_Transien return Standard_False; Handle(Standard_Transient)& att = theitems.ChangeFromIndex(id); if (att.IsNull()) - return Standard_False; // deja annulle + return Standard_False; // already canceled - // Cas particuliers : Dispatch,Modifier + // Special cases : Dispatch,Modifier theshareout->RemoveItem(item); - // Marquer "Removed" dans la Map (on ne peut pas la vider) + // Mark "Removed" in the Map (we cannot empty it) if (att->IsKind(STANDARD_TYPE(TCollection_HAsciiString))) { if (!thenames.UnBind(GetCasted(TCollection_HAsciiString, att)->ToCString())) @@ -971,7 +971,7 @@ Handle(TColStd_HSequenceOfHAsciiString) IFSelect_WorkSession::ItemNames( return list; } -// .. Recherche par label : recherche en liste(noms) ou iterative +// .. Search by label : search in list(names) or iterative //================================================================================================= @@ -1029,14 +1029,14 @@ Standard_Integer IFSelect_WorkSession::NextIdentForLabel(const Standard_CString return i; break; default: - break; // break du switch + break; // break from switch } } - return 0; // ici : pas trouve + return 0; // here : not found } // ################################################################# -// .... Parametres (Int et Text) .... +// .... Parameters (Int and Text) .... //================================================================================================= @@ -1182,12 +1182,12 @@ Interface_EntityIterator IFSelect_WorkSession::EvalSelection( try { OCC_CATCH_SIGNALS - iter = EvalSelection(sel); // appel normal (donc, code pas duplique) + iter = EvalSelection(sel); // normal call (therefore, code not duplicated) } catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption EvalSelection par Exception : ****\n"; + sout << " **** EvalSelection Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -1226,7 +1226,7 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::SelectionResult( catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption SelectionResult par Exception : ****\n"; + sout << " **** SelectionResult Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -1260,7 +1260,7 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::SelectionResultFromLi if (deduct.IsNull()) return SelectionResult(sel); - // On va chercher la derniere deduction de la chaine des inputs + // We will search for the last deduction in the input chain Handle(IFSelect_Selection) ssel, newinput; ssel = sel; Standard_Integer i, nb = MaxIdent(); @@ -1273,14 +1273,14 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::SelectionResultFromLi ssel = newinput; } - // on y est (enfin, on devrait) - // ssel est la derniere selection auscultee, deduct son downcast - // input son Input (nulle si sel pas une deduction) + // we're there (finally, we should be) + // ssel is the last selection examined, deduct its downcast + // input its Input (null if sel is not a deduction) deduct = GetCasted(IFSelect_SelectDeduct, ssel); deduct->Alternate()->SetList(list); - // On execute puis on nettoie + // We execute then we clean Handle(TColStd_HSequenceOfTransient) res = SelectionResult(sel); //// deduct->SetInput (newinput); return res; @@ -1336,7 +1336,7 @@ Handle(IFSelect_Selection) IFSelect_WorkSession::ItemSelection( return disp->FinalSelection(); if (ItemIdent(modif) > 0) return modif->Selection(); - return sel; // Nul ou inconnu -> Null + return sel; // Null or unknown -> Null } // ###################################################################### @@ -1441,7 +1441,7 @@ Handle(TColStd_HSequenceOfInteger) IFSelect_WorkSession::FinalModifierIdents( const Standard_Boolean formodel) const { // return ItemIdents(STANDARD_TYPE(IFSelect_Modifier)); - // On donne la liste dans l ordre du ModelCopier, qui fait foi + // We give the list in ModelCopier order, which is authoritative Handle(TColStd_HSequenceOfInteger) list = new TColStd_HSequenceOfInteger(); Standard_Integer nbm = theshareout->NbModifiers(formodel); for (Standard_Integer i = 1; i <= nbm; i++) @@ -1594,7 +1594,7 @@ Standard_Integer IFSelect_WorkSession::RunTransformer(const Handle(IFSelect_Tran if (newmod.IsNull()) return (res ? 1 : -1); - // MISE A JOUR des SelectPointed + // UPDATE of SelectPointed Handle(TColStd_HSequenceOfInteger) list = ItemIdents(STANDARD_TYPE(IFSelect_SelectPointed)); Standard_Integer nb = list->Length(); for (Standard_Integer i = 1; i <= nb; i++) @@ -1670,7 +1670,7 @@ Handle(IFSelect_Transformer) IFSelect_WorkSession::NewTransformStandard(const St return stf; } -// Ceci est une action directe : pourrait etre fait par un Transformer ... +// This is a direct action: could be done by a Transformer ... //================================================================================================= Standard_Boolean IFSelect_WorkSession::SetModelContent(const Handle(IFSelect_Selection)& sel, @@ -1711,10 +1711,10 @@ Standard_Boolean IFSelect_WorkSession::SetModelContent(const Handle(IFSelect_Sel TC.FillModel(newmod); if (newmod->NbEntities() == 0) return Standard_False; - // Mettre a jour (ne pas oublier SelectPointed) + // Update (don't forget SelectPointed) theoldel = myModel; SetModel(newmod, Standard_False); - // MISE A JOUR des SelectPointed + // UPDATE of SelectPointed Handle(TColStd_HSequenceOfInteger) pts = ItemIdents(STANDARD_TYPE(IFSelect_SelectPointed)); nb = pts->Length(); for (i = 1; i <= nb; i++) @@ -1821,7 +1821,7 @@ Standard_CString IFSelect_WorkSession::GiveFileRoot(const Standard_CString file) Standard_CString IFSelect_WorkSession::GiveFileComplete(const Standard_CString file) const { - // ajouter si besoin : Prefix; Extension + // add if needed: Prefix; Extension bufstr.Clear(); bufstr.AssignCat(file); Standard_Integer i, j = 0, nb = bufstr.Length(); @@ -1882,12 +1882,12 @@ void IFSelect_WorkSession::EvaluateFile() try { OCC_CATCH_SIGNALS - EvaluateFile(); // appel normal (donc, code pas duplique) + EvaluateFile(); // normal call (therefore, code not duplicated) } catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption EvaluateFile par Exception : ****\n"; + sout << " **** EvaluateFile Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; checks.CCheck(0)->AddFail("Exception Raised -> Abandon"); @@ -1951,7 +1951,7 @@ Handle(TColStd_HSequenceOfHAsciiString) IFSelect_WorkSession::SentFiles() const } // ######################################################################### -// .... Action de Transfert proprement dite : la grande affaire ! .... +// .... Transfer Action properly speaking: the big deal! .... //================================================================================================= @@ -1966,12 +1966,12 @@ Standard_Boolean IFSelect_WorkSession::SendSplit() try { OCC_CATCH_SIGNALS - return SendSplit(); // appel normal (donc, code pas duplique) + return SendSplit(); // normal call (therefore, code not duplicated) } catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption SendSplit par Exception : ****\n"; + sout << " **** SendSplit Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; checks.CCheck(0)->AddFail("Exception Raised -> Abandon"); @@ -2024,7 +2024,7 @@ Standard_Boolean IFSelect_WorkSession::SendSplit() Interface_EntityIterator iter = packs.Entities(); if (iter.NbEntities() == 0) continue; - // Ecrire une liste d entites + // Write a list of entities Handle(IFSelect_SelectPointed) sp = new IFSelect_SelectPointed; sp->SetList(iter.Content()); nf++; @@ -2135,7 +2135,7 @@ Standard_Boolean IFSelect_WorkSession::SetRemaining(const IFSelect_RemainMode mo { theoldel = myModel; SetModel(newmod, Standard_False); - // MISE A JOUR des SelectPointed + // UPDATE of SelectPointed Handle(TColStd_HSequenceOfInteger) list = ItemIdents(STANDARD_TYPE(IFSelect_SelectPointed)); Standard_Integer nb = list->Length(); for (Standard_Integer i = 1; i <= nb; i++) @@ -2220,7 +2220,7 @@ IFSelect_ReturnStatus IFSelect_WorkSession::SendAll(const Standard_CString filen catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption SendAll par Exception : ****\n"; + sout << " **** SendAll Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; errhand = theerrhand; @@ -2268,12 +2268,12 @@ IFSelect_ReturnStatus IFSelect_WorkSession::SendSelected(const Standard_CString { OCC_CATCH_SIGNALS ComputeGraph(computegraph); - return SendSelected(filename, sel); // appel normal + return SendSelected(filename, sel); // normal call } catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption SendSelected par Exception : ****\n"; + sout << " **** SendSelected Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; checks.CCheck(0)->AddFail("Exception Raised -> Abandon"); @@ -2321,7 +2321,7 @@ IFSelect_ReturnStatus IFSelect_WorkSession::WriteFile(const Standard_CString } // ################################################################ -// .... Actions particulieres sur les Selections .... +// .... Specific Actions on Selections .... //================================================================================================= @@ -2502,7 +2502,7 @@ Standard_Boolean IFSelect_WorkSession::SetSelectPointed( } // ########################################################################### -// .... Analyse d un CheckIterator par rapport a un graphe .... +// .... Analysis of a CheckIterator in relation to a graph .... //================================================================================================= @@ -2518,7 +2518,7 @@ static void IFSelect_QueryProp(Interface_IntList& list, if (i > 1) list.SetNumber(num); // because recursive call + depth first Standard_Integer n = list.Value(i); - // y a t il lieu de propager ? + // is there a need to propagate? // 1 W/place 2 F/place 3 Wprop 4Wprop+W/place 5Wprop+F/place // 6 Fprop 7 Fprop+W/place 8 Fprop+F/place char val = ana.Value(n); @@ -2579,11 +2579,11 @@ void IFSelect_WorkSession::QueryCheckList(const Interface_CheckIterator& chl) else if (ach->HasWarnings()) thecheckana.SetValue(num, '1'); } - // analyse selon le graphe ... codes : blc = rien + // analysis according to the graph ... codes : blc = nothing // 1 W/place 2 F/place 3 Wprop 4Wprop+W/place 5Wprop+F/place // 6 Fprop 7 Fprop+W/place 8 Fprop+F/place Interface_IntList list; // = thegraph->Graph().SharingNums(0); - // deux passes : d abord Warning, puis Fail + // two passes : first Warning, then Fail for (i = 1; i <= nb; i++) { char val = thecheckana.Value(i); @@ -2652,8 +2652,8 @@ Standard_Integer IFSelect_WorkSession::QueryParent(const Handle(Standard_Transie return -1; if (ndad == nson) return 0; - // on va calculer : pour chaque pere immediat, de <son>, status avec <dad> + 1 - // nb : pas protege contre les boucles ... + // we will calculate: for each immediate parent, of <son>, status with <dad> + 1 + // nb: not protected against loops ... Handle(TColStd_HSequenceOfTransient) list = thegraph->Graph().Sharings(entson).Content(); if (list.IsNull()) return -1; @@ -2670,7 +2670,7 @@ Standard_Integer IFSelect_WorkSession::QueryParent(const Handle(Standard_Transie } // ########################################################################### -// .... Dumps et Evaluations, pas faciles a passer en arguments .... +// .... Dumps and Evaluations, not easy to pass as arguments .... // #### #### #### #### #### #### #### #### #### // .... DumpShare .... @@ -2691,11 +2691,11 @@ void IFSelect_WorkSession::SetParams(const NCollection_Vector<Handle(Standard_Tr editor->AddValue(val); } AddNamedItem("xst-params-edit", editor); - // Les EditForm + // The EditForm Handle(IFSelect_EditForm) paramsall = editor->Form(Standard_False); AddNamedItem("xst-params-all", paramsall); - // On attaque les EditForms partielles + // We tackle the partial EditForms TColStd_SequenceOfInteger listgen, listload, listsend, listsplit, listread, listwrite; for (i = uselist.Lower(); i <= uselist.Upper(); i++) { @@ -2845,8 +2845,8 @@ void IFSelect_WorkSession::TraceStatics(const Standard_Integer use, } } - // LISTER LES STATICS - // Passer par les ParamEditor ... + // LIST THE STATICS + // Go through the ParamEditor ... // Fin if (use > 0) @@ -3040,8 +3040,8 @@ Handle(IFSelect_Selection) IFSelect_WorkSession::GiveSelection(const Standard_CS } Handle(Standard_Transient) item = NamedItem(nomsel); - // Parentheses ? essayer Signature (plus tard : Selection parametree) - // NB : on compte les niveaux de parentheses (imbrications repercutees) + // Parentheses? try Signature (later: parameterized Selection) + // NB: we count the levels of parentheses (reflected nesting) if (np > 0 && nf > 0) { Handle(IFSelect_SelectSignature) selsign; @@ -3059,7 +3059,7 @@ Handle(IFSelect_Selection) IFSelect_WorkSession::GiveSelection(const Standard_CS return sel; } - selsign->SetInput(new IFSelect_SelectModelEntities); // par defaut + selsign->SetInput(new IFSelect_SelectModelEntities); // by default sel = selsign; } @@ -3074,16 +3074,16 @@ Handle(IFSelect_Selection) IFSelect_WorkSession::GiveSelection(const Standard_CS Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveList( const Handle(Standard_Transient)& obj) const { - // Deja une liste + // Already a list DeclareAndCast(TColStd_HSequenceOfTransient, list, obj); if (!list.IsNull()) return list; - // Rien du tout : retourne rien du tout + // Nothing at all: returns nothing at all if (obj.IsNull()) return list; - // Une selection : son resultat (standard) + // A selection: its result (standard) DeclareAndCast(IFSelect_Selection, sel, obj); if (!sel.IsNull()) { @@ -3091,7 +3091,7 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveList( return iter.Content(); } - // Le modele : son contenu + // The model: its content list = new TColStd_HSequenceOfTransient(); if (obj == myModel) { @@ -3100,11 +3100,11 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveList( list->Append(myModel->Value(i)); } - // Une entite du modele : cette entite + // A model entity: this entity else if (StartingNumber(obj) > 0) list->Append(obj); - // Un Texte : son interpretation + // A Text: its interpretation else { DeclareAndCast(TCollection_HAsciiString, str, obj); @@ -3112,7 +3112,7 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveList( return GiveList(str->ToCString()); } - // Si c est pas tout ca : une liste vide + // If it's not all that: an empty list return list; } @@ -3130,8 +3130,8 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveList( if (second && second[0] == ' ') return GiveList(first, &second[1]); - // list NULLE sera interpretee comme SelectionResult (selection toute crue) - // sinon comme SelectionResultFromList + // NULL list will be interpreted as SelectionResult (raw selection) + // otherwise as SelectionResultFromList if (second && second[0] != '\0') list = GiveList(second, ""); @@ -3148,10 +3148,10 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveListFromList( Handle(TColStd_HSequenceOfTransient) list; Standard_Integer num; - // LISTE DEFINIE D OFFICE (en ce cas, la liste d entree est ignoree) + // LIST DEFINED BY DEFAULT (in this case, the input list is ignored) if (selname[0] == '(') { - // liste d entites donnees a la queue leu leu : (ID,ID,ID...) + // list of entities given one after another: (ID,ID,ID...) char entid[50]; Standard_Integer i, j = 0; TColStd_MapOfInteger numap; @@ -3185,11 +3185,11 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveListFromList( if (num > 0) return GiveList(StartingEntity(num)); - // Autres cas : y atil une liste d entree. + // Other cases: is there an input list. // Si OUI -> SelectionResultFromList. Si NON -> SelectionResult - // Si une entite isolee -> on en fait une liste + // If an isolated entity -> we make it a list - list = GiveList(ent); // ent NULL -> list NULL sinon intreprete + list = GiveList(ent); // ent NULL -> list NULL otherwise interpreted // Decomposition term1 term2 ... @@ -3254,7 +3254,7 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveListCombined( list->Append(ent); } - // ents de l1 pas deja dans l2 + // entities from l1 not already in l2 n = l1->Length(); for (i = n; i > 0; i--) { @@ -3264,13 +3264,13 @@ Handle(TColStd_HSequenceOfTransient) IFSelect_WorkSession::GiveListCombined( if (numap.Contains(ent)) { - // dans l1 et dans l2 + // in l1 and in l2 if (mode == 0) list->Append(ent); } else { - // dans l1 mais pas dans l2 + // in l1 but not in l2 if (mode != 0) list->Append(ent); } @@ -3361,7 +3361,7 @@ void IFSelect_WorkSession::DumpModel(const Standard_Integer level, Standard_OStr catch (Standard_Failure const&) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption DumpModel (Check) par Exception ****\n"; + sout << " **** DumpModel (Check) Interrupted by Exception ****\n"; S << " ** ** Exception Raised during Check ! ** **\n"; S << " --> what could be determined is listed" << std::endl; } @@ -3371,7 +3371,7 @@ void IFSelect_WorkSession::DumpModel(const Standard_Integer level, Standard_OStr else C = CT.CompleteCheckList(); - // Check List : si vide (pas demandee), naturellement passee + // Check List: if empty (not requested), naturally passed try { OCC_CATCH_SIGNALS @@ -3380,7 +3380,7 @@ void IFSelect_WorkSession::DumpModel(const Standard_Integer level, Standard_OStr catch (Standard_Failure const& anException) { Message_Messenger::StreamBuffer sout = Message::SendInfo(); - sout << " **** Interruption DumpModel par Exception : ****\n"; + sout << " **** DumpModel Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -3563,11 +3563,11 @@ void IFSelect_WorkSession::EvaluateSelection(const Handle(IFSelect_Selection)& s try { OCC_CATCH_SIGNALS - EvaluateSelection(sel); // appel normal (->code unique) + EvaluateSelection(sel); // normal call (->unique code) } catch (Standard_Failure const& anException) { - sout << " **** Interruption EvaluateSelection par Exception **** Intitule\n"; + sout << " **** EvaluateSelection Interrupted by Exception **** Title\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -3605,11 +3605,11 @@ void IFSelect_WorkSession::EvaluateDispatch(const Handle(IFSelect_Dispatch)& dis try { OCC_CATCH_SIGNALS - EvaluateDispatch(disp, mode); // appel normal (->code unique) + EvaluateDispatch(disp, mode); // normal call (->unique code) } catch (Standard_Failure const& anException) { - sout << " **** Interruption EvaluateDispatch par Exception **** Intitule\n"; + sout << " **** EvaluateDispatch Interrupted by Exception **** Title\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -3699,11 +3699,11 @@ void IFSelect_WorkSession::EvaluateComplete(const Standard_Integer mode) const try { OCC_CATCH_SIGNALS - EvaluateComplete(mode); // appel normal (donc, code pas duplique) + EvaluateComplete(mode); // normal call (therefore, code not duplicated) } catch (Standard_Failure const& anException) { - sout << " **** Interruption EvaluateComplete par Exception : ****\n"; + sout << " **** EvaluateComplete Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } @@ -3877,7 +3877,7 @@ void IFSelect_WorkSession::ListEntities(const Interface_EntityIterator& iter, } catch (Standard_Failure const& anException) { - sout << " **** Interruption ListEntities par Exception : ****\n"; + sout << " **** ListEntities Interrupted by Exception : ****\n"; sout << anException.GetMessageString(); sout << "\n Abandon" << std::endl; } diff --git a/src/DataExchange/TKXSBase/Interface/Interface_BitMap.cxx b/src/DataExchange/TKXSBase/Interface/Interface_BitMap.cxx index 995511045a..b99f451bbc 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_BitMap.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_BitMap.cxx @@ -61,7 +61,7 @@ void Interface_BitMap::Initialize(const Interface_BitMap& other, const Standard_ void Interface_BitMap::Reservate(const Standard_Integer moreflags) { Standard_Integer nb = theflags->Upper(); - Standard_Integer nbflags = nb / thenbwords - 1; // flag 0 non compte ... + Standard_Integer nbflags = nb / thenbwords - 1; // flag 0 not counted ... if (nbflags >= thenbflags + moreflags) return; Standard_Integer nbw = thenbwords * (thenbflags + moreflags + 2); @@ -187,7 +187,7 @@ Standard_Integer Interface_BitMap::FlagNumber(const Standard_CString name) const return 0; } -// Les valeurs ... +// Values ... Standard_Boolean Interface_BitMap::Value(const Standard_Integer item, const Standard_Integer flag) const diff --git a/src/DataExchange/TKXSBase/Interface/Interface_Check.cxx b/src/DataExchange/TKXSBase/Interface/Interface_Check.cxx index 5e5c79c985..6fcb736263 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_Check.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_Check.cxx @@ -22,8 +22,8 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_Check, Standard_Transient) -// Un Check est cree au depart sans liste de message : celle ci est creee -// seulement si au moins une erreur doit y etre enregitree (Fail-Warning) +// A Check is created initially without a message list: this is created +// only if at least one error must be recorded (Fail-Warning) //================================================================================================= Interface_Check::Interface_Check() {} // construit a vide @@ -35,7 +35,7 @@ Interface_Check::Interface_Check(const Handle(Standard_Transient)& anentity) theent = anentity; } -// .... Ajout de message d Erreur vraie (Fail) +// .... Adding a true Error message (Fail) //================================================================================================= @@ -133,7 +133,7 @@ Handle(TColStd_HSequenceOfHAsciiString) Interface_Check::Fails(const Standard_Bo return (final ? thefails : thefailo); } -// .... Ajout de message de Warning +// .... Adding a Warning message //================================================================================================= @@ -232,7 +232,7 @@ Handle(TColStd_HSequenceOfHAsciiString) Interface_Check::Warnings( return (final ? thewarns : thewarno); } -// .... Ajout de message d Info simple (not yet completed) +// .... Adding a simple Info message (not yet completed) //================================================================================================= @@ -286,7 +286,7 @@ Handle(TColStd_HSequenceOfHAsciiString) Interface_Check::InfoMsgs( return (final ? theinfos : theinfoo); } -// .... Gestion generale +// .... General management //================================================================================================= @@ -530,7 +530,7 @@ Standard_Boolean Interface_Check::Mend(const Standard_CString pref, const Standa return Standard_True; } } - // Cas courant + // Common case if (num == 0) { n1 = 1; @@ -541,7 +541,7 @@ Standard_Boolean Interface_Check::Mend(const Standard_CString pref, const Standa } else if (num < 0 || num > NbFails()) return Standard_False; - // Un message + // A message Handle(TCollection_HAsciiString) strf = thefails->Value(num); Handle(TCollection_HAsciiString) stro = thefailo->Value(num); if (pref && pref[0] != '\0') @@ -578,11 +578,11 @@ void Interface_Check::GetEntity(const Handle(Standard_Transient)& anentity) SetEntity(anentity); } -// .. GetMessages, reprend les messages en les cumulant aux siens propres -// .. GetAsWarning, reprend les messages en les cumulant et en les -// considerant tous comme "Warning" . En outre, selon <failsonly> -// failsonly True : ne pas reprendre les Warnings originaux -// failsonly False : les prendre aussi +// .. GetMessages, takes messages by accumulating them with its own +// .. GetAsWarning, takes messages by accumulating them and +// considering them all as "Warning". Furthermore, according to <failsonly> +// failsonly True : do not take original Warnings +// failsonly False : take them as well //================================================================================================= @@ -694,7 +694,7 @@ void Interface_Check::Print(Standard_OStream& S, } } - // InfoMsg : regle causant (user message) + // InfoMsg : causal rule (user message) if (level >= 0) { nb = NbInfoMsgs(); diff --git a/src/DataExchange/TKXSBase/Interface/Interface_CheckIterator.cxx b/src/DataExchange/TKXSBase/Interface/Interface_CheckIterator.cxx index 81cc10c873..39d423918b 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_CheckIterator.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_CheckIterator.cxx @@ -93,7 +93,7 @@ void Interface_CheckIterator::Merge(Interface_CheckIterator& other) void Interface_CheckIterator::Add(const Handle(Interface_Check)& ach, const Standard_Integer num) { - // Add <meme num que le dernier> -> cumul des Checks + // Add <same num as the last> -> accumulate Checks if (ach->NbWarnings() + ach->NbFails() == 0) return; Standard_Integer nm = num; @@ -122,14 +122,14 @@ void Interface_CheckIterator::Add(const Handle(Interface_Check)& ach, const Stan Handle(Interface_Check) lch = thelist->ChangeValue(numpos); lch->GetMessages(ach); } - // Cas normal : on ajoute en fin de liste + // Normal case: add at end of list else { thelist->Append(ach); thenums->Append(nm); } } - // Pas encore vu passe : inutile de chercher + // Not yet seen passed: no need to search else { thelist->Append(ach); diff --git a/src/DataExchange/TKXSBase/Interface/Interface_CheckTool.cxx b/src/DataExchange/TKXSBase/Interface/Interface_CheckTool.cxx index 7e903d9623..2de263421a 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_CheckTool.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_CheckTool.cxx @@ -55,9 +55,9 @@ static void raisecheck(Standard_Failure& theException, Handle(Interface_Check)& } } -// thestat : evite a CheckSuccess de refaire un calcul prealablement fait : -// bit valeur 1 : Verify fait, valeur 4 : et ilya des erreurs -// bit valeur 2 : Analyse fait, valeur 8 : et ilya des erreurs +// thestat : avoids CheckSuccess redoing a previously done calculation : +// bit value 1 : Verify done, value 4 : and there are errors +// bit value 2 : Analysis done, value 8 : and there are errors //================================================================================================= @@ -105,13 +105,13 @@ void Interface_CheckTool::FillCheck(const Handle(Standard_Transient)& ent, Standard_Integer CN; if (thegtool->Select(ent, module, CN)) { - // Sans try/catch (fait par l appelant, evite try/catch en boucle) + // Without try/catch (done by caller, avoids try/catch in loop) if (!errh) { module->CheckCase(CN, ent, sh, ach); return; } - // Avec try/catch + // With try/catch try { OCC_CATCH_SIGNALS @@ -162,9 +162,9 @@ void Interface_CheckTool::Print(const Interface_CheckIterator& list, Standard_OS list.Print(S, model, Standard_False); } -// .... Check General sur un Modele .... +// .... General Check on a Model .... -// Check : Une Entite d un Modele, designee par son rang +// Check: An Entity of a Model, designated by its rank //================================================================================================= @@ -172,13 +172,13 @@ Handle(Interface_Check) Interface_CheckTool::Check(const Standard_Integer num) { Handle(Interface_InterfaceModel) model = theshare.Model(); Handle(Standard_Transient) ent = model->Value(num); - Handle(Interface_Check) ach = new Interface_Check(ent); // non filtre par "Warning" : tel quel + Handle(Interface_Check) ach = new Interface_Check(ent); // not filtered by "Warning": as is errh = 1; FillCheck(ent, theshare, ach); return ach; } -// CheckSuccess : test passe-passe pas, sur CheckList(Fail) des Entites +// CheckSuccess: test passes-doesn't pass, on CheckList(Fail) of Entities //================================================================================================= @@ -187,7 +187,7 @@ void Interface_CheckTool::CheckSuccess(const Standard_Boolean reset) if (reset) thestat = 0; if (thestat > 3) - throw Interface_CheckFailure // deja teste avec erreur + throw Interface_CheckFailure // already tested with error ("Interface Model : Global Check"); Handle(Interface_InterfaceModel) model = theshare.Model(); if (model->GlobalCheck()->NbFails() > 0) @@ -199,9 +199,9 @@ void Interface_CheckTool::CheckSuccess(const Standard_Boolean reset) if (modchk->HasFailed()) throw Interface_CheckFailure("Interface Model : Verify Check"); if (thestat == 3) - return; // tout teste et ca passe + return; // everything tested and it passes - errh = 0; // Pas de try/catch, car justement on raise + errh = 0; // No try/catch, because we precisely raise Standard_Integer nb = model->NbEntities(); for (Standard_Integer i = 1; i <= nb; i++) { @@ -211,12 +211,12 @@ void Interface_CheckTool::CheckSuccess(const Standard_Boolean reset) if (thestat & 1) { if (!model->IsErrorEntity(i)) - continue; // deja verify, reste analyse + continue; // already verify, remains analyse } if (thestat & 2) { if (model->IsErrorEntity(i)) - continue; // deja analyse, reste verify + continue; // already analyse, remains verify } Handle(Interface_Check) ach = new Interface_Check(ent); @@ -226,8 +226,8 @@ void Interface_CheckTool::CheckSuccess(const Standard_Boolean reset) } } -// CompleteCheckList : Tous Tests : GlobalCheck, Analyse-Verify en Fail ou en -// Warning; plus les Unknown Entities (par Check vide) +// CompleteCheckList: All Tests: GlobalCheck, Analyse-Verify in Fail or in +// Warning; plus the Unknown Entities (by empty Check) //================================================================================================= @@ -263,7 +263,7 @@ Interface_CheckIterator Interface_CheckTool::CompleteCheckList() if (model->IsReportEntity(i)) { ach = model->ReportEntity(i)->Check(); // INCLUT Unknown - if (ach->HasFailed()) // FAIL : pas de Check semantique + if (ach->HasFailed()) // FAIL : no semantic Check { res.Add(ach, i); ach = new Interface_Check; @@ -296,7 +296,7 @@ Interface_CheckIterator Interface_CheckTool::CompleteCheckList() return res; } -// CheckList : Check Fail sur Entites, en Analyse (Read time) ou Verify +// CheckList: Check Fail on Entities, in Analysis (Read time) or Verify //================================================================================================= @@ -365,7 +365,7 @@ Interface_CheckIterator Interface_CheckTool::CheckList() return res; } -// AnalyseCheckList : Fail au chargement des Entites (Read time) +// AnalyseCheckList: Fail during loading of Entities (Read time) //================================================================================================= @@ -409,7 +409,7 @@ Interface_CheckIterator Interface_CheckTool::AnalyseCheckList() return res; } -// VerifyCheckList : Fail/Warning sur Analyse (Entites chargees OK. Valides ?) +// VerifyCheckList: Fail/Warning on Analysis (Entities loaded OK. Valid?) //================================================================================================= @@ -459,7 +459,7 @@ Interface_CheckIterator Interface_CheckTool::VerifyCheckList() return res; } -// Warnings sur Entites (Read time ou apres) +// Warnings on Entities (Read time or after) //================================================================================================= diff --git a/src/DataExchange/TKXSBase/Interface/Interface_CopyMap.cxx b/src/DataExchange/TKXSBase/Interface/Interface_CopyMap.cxx index 4d317333be..01ac5e5f80 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_CopyMap.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_CopyMap.cxx @@ -19,7 +19,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_CopyMap, Interface_CopyControl) -// CopyMap : rien de plus qu une Map passive +// CopyMap : nothing more than a passive Map Interface_CopyMap::Interface_CopyMap(const Handle(Interface_InterfaceModel)& amodel) : theres(0, amodel->NbEntities()) { diff --git a/src/DataExchange/TKXSBase/Interface/Interface_CopyTool.cxx b/src/DataExchange/TKXSBase/Interface/Interface_CopyTool.cxx index 4dc0e19d0a..95dbb41212 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_CopyTool.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_CopyTool.cxx @@ -24,17 +24,17 @@ #include <Standard_Transient.hxx> #include <TCollection_HAsciiString.hxx> -// Se souvenir qu une version plus riche de CopyTool existe : c est -// TransferDispatch (package Transfer). Cette classe offre beaucoup plus de -// possibilite (parametrage des actions, gestion du Mapping ...) -// Mais le principe (transfert en 2 passes) reste le meme, a savoir : -// Passe 1 normale : les entites a transferer sont designees, elles entrainent -// leurs sous-references vraies -// Passe 2 : une fois tous les transferts faits, les relations "Imply" sont -// mises, pour les entites designees ET QUI ONT ETE AUSSI TRANSFEREES, la -// relation est reconduite (pas de nouveau Share) +// Remember that a richer version of CopyTool exists: it is +// TransferDispatch (package Transfer). This class offers much more +// possibilities (parameterization of actions, Mapping management ...) +// But the principle (transfer in 2 passes) remains the same, namely: +// Pass 1 normal: the entities to transfer are designated, they involve +// their true sub-references +// Pass 2: once all transfers are done, the "Imply" relations are +// set, for the designated entities AND WHICH HAVE ALSO BEEN TRANSFERRED, the +// relation is continued (no new Share) // ##################################################################### -// .... CONSTRUCTEURS .... +// .... CONSTRUCTORS .... Interface_CopyTool::Interface_CopyTool(const Handle(Interface_InterfaceModel)& amodel, const Interface_GeneralLib& lib) : thelib(lib), @@ -92,7 +92,7 @@ Handle(Interface_CopyControl) Interface_CopyTool::Control() const } // ##################################################################### -// .... Actions Individuelles .... +// .... Individual Actions .... void Interface_CopyTool::Clear() { @@ -152,16 +152,16 @@ Standard_Boolean Interface_CopyTool::Copy(const Handle(Standard_Transient)& entf } return res; } - // On cree l Entite vide (NewVoid), la Copie reste a faire + // Create the empty Entity (NewVoid), the Copy remains to be done res = NewVoid(entfrom, entto); if (mapped) - themap->Bind(entfrom, entto); // Mapper avant de continuer ... + themap->Bind(entfrom, entto); // Map before continuing ... - // A present, on effectue la Copie (selon cas; si ShallowCopy ne suffit pas : - // c est <themdu> qui decide) + // Now, perform the Copy (depending on case; if ShallowCopy is not enough: + // it is <themdu> who decides) - // Une Entite en Erreur n est pas copiee (pas de sens et c est risque ...) - // Cependant, elle est "Copiee a Vide (NewVoid)" donc referencable + // An Entity in Error is not copied (no sense and it's risky ...) + // However, it is "Copied Empty (NewVoid)" so referenceable if (!errstat) themdu->CopyCase(theCN, entfrom, entto, *this); return res; @@ -176,25 +176,25 @@ void Interface_CopyTool::Implied(const Handle(Standard_Transient)& entfrom, module->RenewImpliedCase(CN, entfrom, entto, *this); } -// .... Alimentation de la Map .... +// .... Feeding the Map .... Handle(Standard_Transient) Interface_CopyTool::Transferred(const Handle(Standard_Transient)& ent) { Handle(Standard_Transient) res; if (ent.IsNull()) - return res; // Copie d un Null : tres simple ... + return res; // Copy of a Null : very simple ... Standard_Integer nument = themod->Number(ent); - // <nument> == 0 -> Peut etre une sous-partie non partagee ... - // On accepte mais on se protege contre un bouclage + // <nument> == 0 -> May be a non-shared sub-part ... + // We accept but we protect against a loop if (nument == 0 && thelev > 100) throw Interface_InterfaceError( "CopyTool : Transferred, Entity is not contained in Starting Model"); if (!themap->Search(ent, res)) - { // deja transfere ? sinon, le faire + { // already transferred ? if not, do it - // On opere la Copie (enfin, on tente) - // En cas d echec, rien n est enregistre + // We perform the Copy (finally, we try) + // In case of failure, nothing is recorded if (!Copy(ent, res, (nument != 0), themod->IsRedefinedContent(nument))) return res; @@ -206,8 +206,8 @@ Handle(Standard_Transient) Interface_CopyTool::Transferred(const Handle(Standard rep = themod->ReportEntity(nument); if (!rep.IsNull()) { - // ATTENTION ATTENTION, si ReportEntity : Copier aussi Content et refaire une - // ReportEntity avec les termes initiaux + // WARNING WARNING, if ReportEntity : Also copy Content and remake a + // ReportEntity with the initial terms if (rep->IsUnknown()) therep->Bind(ent, new Interface_ReportEntity(res)); else @@ -226,7 +226,7 @@ Handle(Standard_Transient) Interface_CopyTool::Transferred(const Handle(Standard therep->Bind(ent, repto); } } - // Gerer le niveau d imbrication (0 = racine du transfert) + // Manage the nesting level (0 = root of transfer) thelev--; } if (thelev == 0 && nument > 0) @@ -274,7 +274,7 @@ Standard_Integer Interface_CopyTool::LastCopiedAfter(const Standard_Integer } // ######################################################################### -// .... Actions Generales .... +// .... General Actions .... void Interface_CopyTool::TransferEntity(const Handle(Standard_Transient)& ent) { @@ -284,13 +284,13 @@ void Interface_CopyTool::TransferEntity(const Handle(Standard_Transient)& ent) void Interface_CopyTool::RenewImpliedRefs() { if (theimp) - return; // deja fait + return; // already done theimp = Standard_True; - // Transfert Passe 2 : recuperation des relations non "Share" (mais "Imply") - // c-a-d portant sur des entites qui ont pu ou non etre transferees - // (Et que la 1re passe n a pas copie mais laisse en Null) - // N.B. : on devrait interdire de commander des nouveaux transferts ... + // Transfer Pass 2 : recovery of non "Share" relations (but "Imply") + // i.e. concerning entities that may or may not have been transferred + // (And that the 1st pass did not copy but left as Null) + // N.B. : we should forbid commanding new transfers ... Standard_Integer nb = themod->NbEntities(); for (Standard_Integer i = 1; i <= nb; i++) @@ -298,8 +298,8 @@ void Interface_CopyTool::RenewImpliedRefs() Handle(Standard_Transient) ent = themod->Value(i); Handle(Standard_Transient) res; if (!themap->Search(ent, res)) - continue; // entite pas transferee - // Reconduction des references "Imply". Attention, ne pas copier si non chargee + continue; // entity not transferred + // Renewal of "Imply" references. Warning, do not copy if not loaded Handle(Standard_Transient) aRep; if (!therep->Search(ent, aRep)) { @@ -316,16 +316,16 @@ void Interface_CopyTool::RenewImpliedRefs() void Interface_CopyTool::FillModel(const Handle(Interface_InterfaceModel)& bmodel) { - // Travaux preparatoires concernant les modeles - // On commence : cela implique le Header + // Preparatory work concerning the models + // We start : this involves the Header bmodel->Clear(); bmodel->GetFromAnother(themod); - // Transfert Passe 1 : On prend les Entites prealablement copiees + // Transfer Pass 1 : We take the Entities previously copied Interface_EntityIterator list = CompleteResult(Standard_True); bmodel->GetFromTransfer(list); - // Transfert Passe 2 : recuperation des relations non "Share" (mais "Imply") + // Transfer Pass 2 : recovery of non "Share" relations (but "Imply") RenewImpliedRefs(); } diff --git a/src/DataExchange/TKXSBase/Interface/Interface_EntityCluster.cxx b/src/DataExchange/TKXSBase/Interface/Interface_EntityCluster.cxx index f3a6700c35..9739ad22e2 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_EntityCluster.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_EntityCluster.cxx @@ -21,12 +21,12 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_EntityCluster, Standard_Transient) -// Un Cluster, ce sont 4 entites qui se suivent (dans le principe, nombre fixe, -// meme si pas 4). Elles sont remplies depuis 0. Il y a donc autant d Entites -// que de Handles non Nuls, plus le fait qu ils sont remplis dans l ordre -// Ainsi (avec Next), on consomme 5 Handles pour 4 Entites, avec une pointe -// pour 1 et 2 Entites (on reste a 5 Handles) -// Suppression : On retasse le Cluster pour que les Nulls soient tjrs a la fin +// A Cluster is 4 entities that follow each other (in principle, fixed number, +// even if not 4). They are filled from 0. There are therefore as many Entities +// as there are non-Null Handles, plus the fact that they are filled in order +// Thus (with Next), we consume 5 Handles for 4 Entities, with a spike +// for 1 and 2 Entities (we stay at 5 Handles) +// Deletion: We compact the Cluster so that the Nulls are always at the end // .... CONSTRUCTEURS .... Interface_EntityCluster::Interface_EntityCluster() {} @@ -62,7 +62,7 @@ void Interface_EntityCluster::Append(const Handle(Standard_Transient)& ent) else if (theents[3].IsNull()) theents[3] = ent; else - { // Si celui-ci est plein ... + { // If this one is full ... if (thenext.IsNull()) thenext = new Interface_EntityCluster(ent); else @@ -80,7 +80,7 @@ Standard_Boolean Interface_EntityCluster::Remove(const Handle(Standard_Transient if (ent.IsNull()) throw Standard_NullObject("Interface_EntityCluster Remove"); Standard_Integer i; - // <ent> est-il ici ? si oui, on a son rang + // Is <ent> here? if yes, we have its rank if (ent == theents[0]) i = 1; else if (ent == theents[1]) @@ -90,10 +90,10 @@ Standard_Boolean Interface_EntityCluster::Remove(const Handle(Standard_Transient else if (ent == theents[3]) i = 4; - // Sinon, passer au suivant, qui peut du coup devenir vide -> - // On enleve le cluster vide de la liste (en principe cest le dernier) + // Otherwise, go to the next one, which can then become empty -> + // We remove the empty cluster from the list (in principle it's the last one) else - { // Pas trouve dans celui-ci ... + { // Not found in this one ... if (thenext.IsNull()) return Standard_False; Standard_Integer res = thenext->Remove(ent); @@ -120,11 +120,11 @@ Standard_Boolean Interface_EntityCluster::Remove(const Standard_Integer num) } for (Standard_Integer j = num; j < n; j--) theents[j - 1] = theents[j]; - theents[3].Nullify(); // On Nullify par la fin - return (n == 1); // Ancien NbLocal == 1 -> devient nul + theents[3].Nullify(); // We Nullify at the end + return (n == 1); // Old NbLocal == 1 -> becomes null } -// .... ACCES AUX DONNEES .... +// .... DATA ACCESS .... Standard_Integer Interface_EntityCluster::NbEntities() const { @@ -152,7 +152,7 @@ const Handle(Standard_Transient)& Interface_EntityCluster::Value(const Standard_ } return aCurEntClust->theents[aLocalNum - 1]; } - return theents[num - 1]; // numerotation a partir de 0 + return theents[num - 1]; // numbering from 0 } void Interface_EntityCluster::SetValue(const Standard_Integer num, @@ -177,7 +177,7 @@ void Interface_EntityCluster::SetValue(const Standard_Integer num, aCurEntClust->theents[aLocalNum - 1] = ent; } else - theents[num - 1] = ent; // numerotation a partir de 0 + theents[num - 1] = ent; // numbering from 0 } void Interface_EntityCluster::FillIterator(Interface_EntityIterator& iter) const diff --git a/src/DataExchange/TKXSBase/Interface/Interface_EntityIterator.cxx b/src/DataExchange/TKXSBase/Interface/Interface_EntityIterator.cxx index 1ff0749547..dc466b49cb 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_EntityIterator.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_EntityIterator.cxx @@ -17,15 +17,15 @@ #include <Standard_NoSuchObject.hxx> #include <Standard_Transient.hxx> -// Iterateur pour ecriture for, ou while avec Next en fin : -// for (creer iterateur; iter.More(); iter.Next()) { val = iter.Value(); ... } -// .... Definitions initiales : en particulier celles requises pour -// les outils de graphe (construction avec le graphe, avec un vertex) +// Iterator for for writing, or while with Next at the end : +// for (create iterator; iter.More(); iter.Next()) { val = iter.Value(); ... } +// .... Initial definitions : in particular those required for +// graph tools (construction with graph, with a vertex) Interface_EntityIterator::Interface_EntityIterator() { // thecurr = new Interface_IntVal; // thecurr->CValue() = 0; - // thelist = new TColStd_HSequenceOfTransient(); // constructeur vide + // thelist = new TColStd_HSequenceOfTransient(); // empty constructor // thelist sera construit au premier Add (quelquefois, il nyena pas) } @@ -71,10 +71,10 @@ void Interface_EntityIterator::Reset() thelist = new TColStd_HSequenceOfTransient(); } -// .... Fonctionnalites de tri prealable a l'iteration .... +// .... Pre-iteration sorting functionalities .... -// Facon "bete" : supprimer les termes qui ne conviennent pas : lent ! -// Mieux vaut refaire une autre sequence a cote +// "Dumb" way : remove terms that don't fit : slow ! +// Better to make another sequence alongside void Interface_EntityIterator::SelectType(const Handle(Standard_Type)& atype, const Standard_Boolean keep) @@ -134,14 +134,14 @@ void Interface_EntityIterator::Start() const { if (!thecurr.IsNull()) thecurr->CValue() = 1; -} // peut etre redefini ... +} // can be redefined ... Standard_Boolean Interface_EntityIterator::More() const { if (thecurr.IsNull()) return Standard_False; if (thecurr->Value() == 0) - Start(); // preparation de l iteration + Start(); // iteration preparation if (thelist.IsNull()) return Standard_False; return (thecurr->Value() <= thelist->Length()); @@ -154,7 +154,7 @@ void Interface_EntityIterator::Next() const const Handle(Standard_Transient)& Interface_EntityIterator::Value() const { - // NbEntity pas const (on ne sait pas comment il est implemente apres tout) + // NbEntity not const (we don't know how it is implemented after all) if (thelist.IsNull()) throw Standard_NoSuchObject("Interface_EntityIterator"); if (thecurr->Value() < 1 || thecurr->Value() > thelist->Length()) @@ -167,14 +167,14 @@ Handle(TColStd_HSequenceOfTransient) Interface_EntityIterator::Content() const if (!thecurr.IsNull() && thecurr->Value() == 0) Start(); if (thelist.IsNull()) - return new TColStd_HSequenceOfTransient(); // vide + return new TColStd_HSequenceOfTransient(); // empty return thelist; } void Interface_EntityIterator::Destroy() { thecurr.Nullify(); -} // redevient vide ! +} // becomes empty again ! Interface_EntityIterator::~Interface_EntityIterator() { diff --git a/src/DataExchange/TKXSBase/Interface/Interface_EntityList.cxx b/src/DataExchange/TKXSBase/Interface/Interface_EntityList.cxx index c464ad5b1d..b68e16146b 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_EntityList.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_EntityList.cxx @@ -19,11 +19,11 @@ #include <Standard_OutOfRange.hxx> #include <Standard_Transient.hxx> -// Une EntityList, c est au fond un "Handle" bien entoure : -// S il est nul, la liste est vide -// Si c est une Entite, la liste comprend cette entite et rien d autre -// Si c est un EntityCluster, il definit (avec ses Next eventuels) le contenu -// de la liste +// An EntityList is basically a well-wrapped "Handle": +// If it is null, the list is empty +// If it is an Entity, the list includes this entity and nothing else +// If it is an EntityCluster, it defines (with its possible Next) the content +// of the list Interface_EntityList::Interface_EntityList() {} void Interface_EntityList::Clear() @@ -31,7 +31,7 @@ void Interface_EntityList::Clear() theval.Nullify(); } -// .... EDITIONS (ajout-suppression) .... +// .... EDITIONS (add-remove) .... void Interface_EntityList::Append(const Handle(Standard_Transient)& ent) { @@ -53,10 +53,10 @@ void Interface_EntityList::Append(const Handle(Standard_Transient)& ent) } } -// Difference avec Append : on optimise, en evitant la recursivite -// En effet, quand un EntityCluster est plein, Append transmet au Next -// Ici, EntityList garde le controle, le temps de traitement reste le meme -// Moyennant quoi, l ordre n est pas garanti +// Difference with Append : we optimize, avoiding recursion +// Indeed, when an EntityCluster is full, Append transmits to Next +// Here, EntityList keeps control, the processing time remains the same +// With which, the order is not guaranteed void Interface_EntityList::Add(const Handle(Standard_Transient)& ent) { @@ -83,9 +83,9 @@ void Interface_EntityList::Add(const Handle(Standard_Transient)& ent) } } -// Remove : Par Identification d Item a supprimer, ou par Rang -// Identification : Item supprime ou qu il soit -// N.B.: La liste peut devenir vide ... cf retour Remove de Cluster +// Remove : By Identification of Item to remove, or by Rank +// Identification : Item removed wherever it is +// N.B.: The list can become empty ... cf return Remove from Cluster void Interface_EntityList::Remove(const Handle(Standard_Transient)& ent) { @@ -100,13 +100,13 @@ void Interface_EntityList::Remove(const Handle(Standard_Transient)& ent) } Handle(Interface_EntityCluster) ec = Handle(Interface_EntityCluster)::DownCast(theval); if (ec.IsNull()) - return; // Une seule Entite et pas la bonne + return; // A single Entity and not the right one Standard_Boolean res = ec->Remove(ent); if (res) theval.Nullify(); } -// Remove par rang : tester OutOfRange +// Remove by rank : test OutOfRange void Interface_EntityList::Remove(const Standard_Integer num) { @@ -125,7 +125,7 @@ void Interface_EntityList::Remove(const Standard_Integer num) theval.Nullify(); } -// .... ACCES Unitaire AUX DONNEES .... +// .... UNIT ACCESS TO DATA .... Standard_Boolean Interface_EntityList::IsEmpty() const { @@ -138,7 +138,7 @@ Standard_Integer Interface_EntityList::NbEntities() const return 0; Handle(Interface_EntityCluster) ec = Handle(Interface_EntityCluster)::DownCast(theval); if (ec.IsNull()) - return 1; // Une seuke Entite + return 1; // A single Entity return ec->NbEntities(); } diff --git a/src/DataExchange/TKXSBase/Interface/Interface_FileParameter.cxx b/src/DataExchange/TKXSBase/Interface/Interface_FileParameter.cxx index 961c6960b4..202b4c6a87 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_FileParameter.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_FileParameter.cxx @@ -37,7 +37,7 @@ void Interface_FileParameter::Init(const TCollection_AsciiString& val, void Interface_FileParameter::Init(const Standard_CString val, const Interface_ParamType typ) { - theval = (Standard_PCharacter)val; // Principe : Allocation geree par contenant (ParamSet) + theval = (Standard_PCharacter)val; // Principle: Allocation managed by container (ParamSet) thetype = typ; thenum = 0; } @@ -75,7 +75,7 @@ Standard_Integer Interface_FileParameter::EntityNumber() const void Interface_FileParameter::Clear() { theval = NULL; -} // delete theval; pas si gere par ParamSet +} // delete theval; not if managed by ParamSet //================================================================================================= diff --git a/src/DataExchange/TKXSBase/Interface/Interface_FileReaderData.cxx b/src/DataExchange/TKXSBase/Interface/Interface_FileReaderData.cxx index 4346c4092e..77d8f2b4d3 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_FileReaderData.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_FileReaderData.cxx @@ -28,13 +28,13 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_FileReaderData, Standard_Transient) -// Stoque les Donnees issues d un Fichier (Conservees sous forme Litterale) -// Chaque norme peut s en servir comme base (listes de parametres litteraux, -// entites associees) et y ajoute ses donnees propres. -// Travaille sous le controle de FileReaderTool -// Optimisation : Champs pas possibles, car Param est const. Dommage -// Donc, on suppose qu on lit un fichier a la fois (hypothese raisonnable) -// On note en champ un numero de fichier, par rapport auquel on optimise +// Stores Data from a File (Preserved in Literal form) +// Each standard can use it as a base (literal parameter lists, +// associated entities) and add its own data to it. +// Works under the control of FileReaderTool +// Optimization : Fields not possible, because Param is const. Too bad +// So, we assume that we read one file at a time (reasonable assumption) +// We note in field a file number, relative to which we optimize static Standard_Integer thefic = 0; static Standard_Integer thenm0 = -1; static Standard_Integer thenp0 = -1; @@ -65,7 +65,7 @@ Standard_Integer Interface_FileReaderData::NbEntities() const return nb; } -// .... Gestion des Parametres attaches aux Records .... +// .... Management of Parameters attached to Records .... void Interface_FileReaderData::InitParams(const Standard_Integer num) { @@ -228,7 +228,7 @@ Standard_Boolean Interface_FileReaderData::ResetErrorLoad() return res; } -// .... Gestion des Entites Associees aux Donnees du Fichier .... +// .... Management of Entities Associated with File Data .... const Handle(Standard_Transient)& Interface_FileReaderData::BoundEntity( const Standard_Integer num) const diff --git a/src/DataExchange/TKXSBase/Interface/Interface_FileReaderTool.cxx b/src/DataExchange/TKXSBase/Interface/Interface_FileReaderTool.cxx index 3bf33ae7e8..fd79dc5c7a 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_FileReaderTool.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_FileReaderTool.cxx @@ -43,11 +43,11 @@ // To use TCollectionHAsciiString #include <TCollection_HAsciiString.hxx> -// Failure pour recuperer erreur en lecture fichier, -// TypeMismatch pour message d erreur circonstancie (cas particulier important) +// Failure to recover error when reading file, +// TypeMismatch for detailed error message (important special case) -// Gere le chargement d un Fichier, prealablement transforme en FileReaderData -// (de la bonne norme), dans un Modele +// Manages the loading of a File, previously transformed into FileReaderData +// (of the right standard), into a Model //================================================================================================= @@ -141,13 +141,13 @@ Standard_Boolean Interface_FileReaderTool::ErrorHandle() const return theerrhand; } -// .... Actions Connexes au CHARGEMENT DU MODELE .... +// .... Actions Related to MODEL LOADING .... -// SetEntities fait appel a des methodes a fournir : -// s appuyant sur un Recognizer adapte a l interface : -// - Recognize fait reco->Evaluate(... : selon record no num) -// et recupere le resultat -// ainsi que la definition de l entite inconnue de l interface +// SetEntities calls methods to be provided : +// based on a Recognizer adapted to the interface : +// - Recognize makes reco->Evaluate(... : according to record no num) +// and retrieves the result +// as well as the definition of the unknown entity of the interface //================================================================================================= @@ -194,7 +194,7 @@ Standard_Boolean Interface_FileReaderTool::RecognizeByLib(const Standard_Integer Handle(Interface_ReaderModule) rmod; Handle(Interface_Protocol) proto; Standard_Integer CN = 0; - // Chercher dans ReaderLib : Reconnaissance de cas -> CN , proto + // Search in ReaderLib : Case recognition -> CN , proto for (rlib.Start(); rlib.More(); rlib.Next()) { rmod = rlib.Module(); @@ -209,7 +209,7 @@ Standard_Boolean Interface_FileReaderTool::RecognizeByLib(const Standard_Integer } if (CN <= 0 || proto.IsNull()) return Standard_False; - // Se recaler dans GeneralLib : Creation de l entite vide + // Recalibrate in GeneralLib : Creation of empty entity Handle(Standard_Type) typrot = proto->DynamicType(); for (glib.Start(); glib.More(); glib.Next()) { @@ -245,7 +245,7 @@ Handle(Interface_InterfaceModel) Interface_FileReaderTool::NewModel() const //================================================================================================= void Interface_FileReaderTool::EndRead(const Handle(Interface_InterfaceModel)&) { -} // par defaut, ne fait rien; redefinissable selon besoin +} // by default, does nothing; redefinable as needed // .... (Sa Majeste le) CHARGEMENT DU MODELE .... @@ -253,9 +253,9 @@ void Interface_FileReaderTool::EndRead(const Handle(Interface_InterfaceModel)&) void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& amodel) // -// Methode generale de lecture d un fichier : il est lu via un FileReaderData -// qui doit y donner acces de la facon la plus performante possible -// chaque interface definit son FileHeader avec ses methodes, appelees ici +// General method for reading a file : it is read via a FileReaderData +// which must provide access in the most efficient way possible +// each interface defines its FileHeader with its methods, called here { // MGE 16/06/98 // Building of Messages @@ -266,13 +266,13 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& SetModel(amodel); - // .. Demarrage : Lecture du Header .. + // .. Startup : Header Reading .. if (theerrhand) { try { OCC_CATCH_SIGNALS - BeginRead(amodel); // selon la norme + BeginRead(amodel); // according to the standard } catch (Standard_Failure const&) { @@ -287,7 +287,7 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& else BeginRead(amodel); // selon la norme - // .. Lecture des Entites .. + // .. Reading Entities .. amodel->Reservate(thereader->NbEntities()); @@ -296,7 +296,7 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& while (num > 0) { - Standard_Integer ierr = 0; // erreur sur analyse d une entite + Standard_Integer ierr = 0; // error on analysis of an entity Handle(Standard_Transient) anent; try { @@ -305,15 +305,15 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& { num0 = num; - // Lecture sous protection contre crash - // (fait aussi AddEntity mais pas SetReportEntity) + // Reading under crash protection + // (also does AddEntity but not SetReportEntity) anent = LoadedEntity(num); - // Lecture non protegee : utile pour travailler avec dbx + // Unprotected reading : useful for working with dbx //// else //// anent = LoadedEntity(num); - // .. Fin Lecture .. + // .. End Reading .. if (anent.IsNull()) { // Sending of message : Number of ignored Null Entities @@ -325,17 +325,17 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& } continue; } - // LoadedEntity fait AddEntity MAIS PAS SetReport (en bloc a la fin) + // LoadedEntity does AddEntity BUT NOT SetReport (in block at the end) - } // ---- fin boucle sur entites - num0 = 0; // plus rien + } // ---- end loop on entities + num0 = 0; // nothing more } // ---- fin du try, le catch suit - // En cas d erreur NON PREVUE par l analyse, recuperation par defaut - // Attention : la recuperation peut elle-meme planter ... (cf ierr) + // In case of UNFORESEEN error by the analysis, default recovery + // Warning : the recovery can itself crash ... (cf ierr) catch (Standard_Failure const& anException) { - // Au passage suivant, on attaquera le record suivant + // On the next pass, we will attack the next record // clang-format off num0 = thereader->FindNextRecord(num); //:g9 abv 28 May 98: tr8_as2_ug.stp - infinite cycle: (0); // clang-format on @@ -387,7 +387,7 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& { // char mess[100]; svv #2 ierr = 1; - // ce qui serait bien ici serait de recuperer le texte de l erreur pour ach ... + // what would be good here would be to recover the error text for ach ... if (thetrace > 0) { // Sending of message : recovered entity @@ -399,7 +399,7 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& } } - // Finalement, on charge une Entite Inconnue + // Finally, we load an Unknown Entity thenbreps++; Handle(Interface_ReportEntity) rep = new Interface_ReportEntity(ach, anent); Handle(Standard_Transient) undef = UnknownEntity(); @@ -411,7 +411,7 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& thenbreps++; thereports->SetValue(num, rep); // if(isValid) - amodel->AddEntity(anent); // pas fait par LoadedEntity ... + amodel->AddEntity(anent); // not done by LoadedEntity ... } else { @@ -425,14 +425,14 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& TF->Send(Msg22, Message_Info); } } - // On garde <rep> telle quelle : pas d analyse fichier supplementaire, - // Mais la phase preliminaire eventuelle est conservee - // (en particulier, on garde trace du Type lu du fichier, etc...) + // We keep <rep> as is : no additional file analysis, + // But the eventual preliminary phase is preserved + // (in particular, we keep trace of the Type read from the file, etc...) } } // ----- fin complete du try/catch } // ----- fin du while - // .. Ajout des Reports, silya + // .. Adding Reports, if any if (!thereports.IsNull()) { if (thetrace > 0) @@ -458,13 +458,13 @@ void Interface_FileReaderTool::LoadModel(const Handle(Interface_InterfaceModel)& } } - // Conclusion : peut ne rien faire : selon necessite + // Conclusion : may do nothing : according to necessity if (theerrhand) { try { OCC_CATCH_SIGNALS - EndRead(amodel); // selon la norme + EndRead(amodel); // according to the standard } catch (Standard_Failure const&) { @@ -499,7 +499,7 @@ Handle(Standard_Transient) Interface_FileReaderTool::LoadedEntity(const Standard } } - // Trace Entite Inconnue + // Trace Unknown Entity if (thetrace >= 2 && theproto->IsUnknownEntity(anent)) { Handle(Message_Messenger) TF = Messenger(); @@ -511,18 +511,18 @@ Handle(Standard_Transient) Interface_FileReaderTool::LoadedEntity(const Standard TF->Send(Msg22, Message_Info); } } - // .. Chargement proprement dit : Specifique de la Norme .. + // .. Actual Loading : Standard Specific .. AnalyseRecord(num, anent, ach); - // .. Ajout dans le modele de l entite telle quelle .. - // ATTENTION, ReportEntity traitee en bloc apres les Load + // .. Adding to the model the entity as is .. + // WARNING, ReportEntity processed in block after Load themodel->AddEntity(anent); - // Erreur ou Correction : On cree une ReportEntity qui memorise le Check, - // l Entite, et en cas d Erreur une UndefinedEntity pour les Parametres + // Error or Correction : We create a ReportEntity that memorizes the Check, + // the Entity, and in case of Error an UndefinedEntity for the Parameters - // On exploite ici le flag IsLoadError : s il a ete defini (a vrai ou faux) - // il a priorite sur les fails du check. Sinon, ce sont les fails qui parlent + // We exploit here the IsLoadError flag: if it has been defined (true or false) + // it has priority over check fails. Otherwise, it's the fails that speak Standard_Integer nbf = ach->NbFails(); Standard_Integer nbw = ach->NbWarnings(); @@ -547,7 +547,7 @@ Handle(Standard_Transient) Interface_FileReaderTool::LoadedEntity(const Standard } } - // Rechargement ? si oui, dans une UnknownEntity fournie par le protocole + // Reloading ? if yes, in an UnknownEntity provided by the protocol if (thereader->IsErrorLoad()) nbf = (thereader->ResetErrorLoad() ? 1 : 0); if (nbf > 0) @@ -557,7 +557,7 @@ Handle(Standard_Transient) Interface_FileReaderTool::LoadedEntity(const Standard rep->SetContent(undef); } - // Conclusion (Unknown : traite en externe because traitement Raise) + // Conclusion (Unknown : treated externally because Raise treatment) //// if (irep > 0) themodel->SetReportEntity (nbe,rep); en bloc a la fin return anent; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_FloatWriter.cxx b/src/DataExchange/TKXSBase/Interface/Interface_FloatWriter.cxx index 5cb9ed7bcb..3513c37b79 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_FloatWriter.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_FloatWriter.cxx @@ -20,7 +20,7 @@ Interface_FloatWriter::Interface_FloatWriter(const Standard_Integer chars) SetDefaults(chars); } -// .... Controle d Envoi des Flottants .... +// .... Control of Float Transmission .... void Interface_FloatWriter::SetFormat(const Standard_CString form, const Standard_Boolean reset) { @@ -107,7 +107,7 @@ Standard_Integer Interface_FloatWriter::Convert(const Standard_Real val, const Standard_CString mainform, const Standard_CString rangeform) { - // Valeur flottante, expurgee de "0000" qui trainent et de "E+00" + // Float value, purged of trailing "0000" and "E+00" const Standard_Integer anMasSize = 5; // change 6 to 5: index 5 is not used below char lxp[anMasSize], *pText; int i0 = 0, j0 = 0; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_GeneralModule.cxx b/src/DataExchange/TKXSBase/Interface/Interface_GeneralModule.cxx index 39b7c605f6..a2188472bd 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_GeneralModule.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_GeneralModule.cxx @@ -79,20 +79,20 @@ void Interface_GeneralModule::RenewImpliedCase(const Standard_Integer /*casenum* const Handle(Standard_Transient)& /*entto*/, const Interface_CopyTool& /*TC*/) const { -} // Par defaut, ne fait rien +} // By default, does nothing void Interface_GeneralModule::WhenDeleteCase(const Standard_Integer /*casenum*/, const Handle(Standard_Transient)& /*ent*/, const Standard_Boolean /*dispatched*/) const { -} // par defaut, ne fait rien +} // by default, does nothing Standard_Integer Interface_GeneralModule::CategoryNumber(const Standard_Integer, const Handle(Standard_Transient)&, const Interface_ShareTool&) const { return 0; -} // par defaut, non specifie +} // by default, not specified Handle(TCollection_HAsciiString) Interface_GeneralModule::Name(const Standard_Integer, const Handle(Standard_Transient)&, @@ -100,4 +100,4 @@ Handle(TCollection_HAsciiString) Interface_GeneralModule::Name(const Standard_In { Handle(TCollection_HAsciiString) str; return str; -} // par defaut, non specifie +} // by default, not specified diff --git a/src/DataExchange/TKXSBase/Interface/Interface_Graph.cxx b/src/DataExchange/TKXSBase/Interface/Interface_Graph.cxx index c11f7ab4c4..a686f2e7c1 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_Graph.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_Graph.cxx @@ -35,7 +35,7 @@ // .... CONSTRUCTEURS .... -// .... Construction a partir de la connaissance des Entites .... +// .... Construction from Entity knowledge .... Interface_Graph::Interface_Graph(const Handle(Interface_InterfaceModel)& amodel, const Interface_GeneralLib& /*lib*/, @@ -81,7 +81,7 @@ Interface_Graph::Interface_Graph(const Handle(Interface_InterfaceModel)& amodel, Evaluate(); } -// .... Construction depuis un autre Graph .... +// .... Construction from another Graph .... Interface_Graph::Interface_Graph(const Interface_Graph& agraph, const Standard_Boolean /*copied*/) : themodel(agraph.Model()), @@ -211,11 +211,11 @@ void Interface_Graph::Evaluate() } } -// .... Construction depuis un autre Graph .... +// .... Construction from another Graph .... // ########################################################################### -// .... ACCES UNITAIRES AUX DONNEES DE BASE .... +// .... UNITARY ACCESS TO BASE DATA .... void Interface_Graph::Reset() { @@ -318,7 +318,7 @@ Interface_BitMap& Interface_Graph::CBitMap() // ########################################################################### -// .... Chargements Elementaires avec Propagation de "Share" .... // +// .... Elementary Loadings with "Share" Propagation .... // const Handle(Interface_InterfaceModel)& Interface_Graph::Model() const { @@ -328,7 +328,7 @@ const Handle(Interface_InterfaceModel)& Interface_Graph::Model() const void Interface_Graph::GetFromModel() { if (themodel.IsNull() || thestats.IsNull()) - return; // no model ... (-> on n ira pas loin) + return; // no model ... (-> we won't go far) theflags.Init(Standard_True, Graph_Present); thestats->Init(0); } @@ -343,11 +343,11 @@ void Interface_Graph::GetFromEntity(const Handle(Standard_Transient)& ent, if (!num) return; if (theflags.CTrue(num, Graph_Present)) - return; // deja pris : on passe + return; // already taken : we skip thestats->SetValue(num, newstat); if (!shared) return; - // Attention a la redefinition ! + // Watch out for redefinition ! Interface_EntityIterator aIter = GetShareds(ent); for (; aIter.More(); aIter.Next()) @@ -370,25 +370,25 @@ void Interface_Graph::GetFromEntity(const Handle(Standard_Transient)& ent, if (pasla) { - /// theflags.SetTrue (num, Graph_Present); // nouveau : noter avec newstat + /// theflags.SetTrue (num, Graph_Present); // new : note with newstat thestats->SetValue(num, newstat); } else { Standard_Integer overstat = stat; if (stat != newstat) - { // deja pris, meme statut : passer + { // already taken, same status : skip if (cumul) - overstat += overlapstat; // nouveau statut : avec cumul ... + overstat += overlapstat; // new status : with cumulation ... else - overstat = overlapstat; // ... ou sans (statut force) - if (stat != overstat) // si repasse deja faite, passer + overstat = overlapstat; // ... or without (forced status) + if (stat != overstat) // if repass already done, skip thestats->SetValue(num, overstat); } } if (!shared) return; - // Attention a la redefinition ! + // Watch out for redefinition ! Interface_EntityIterator aIter = GetShareds(ent); for (; aIter.More(); aIter.Next()) @@ -457,7 +457,7 @@ void Interface_Graph::GetFromGraph(const Interface_Graph& agraph, const Standard // ##################################################################### -// .... Listage des Entites Partagees .... +// .... Listing of Shared Entities .... Standard_Boolean Interface_Graph::HasShareErrors(const Handle(Standard_Transient)& ent) const { diff --git a/src/DataExchange/TKXSBase/Interface/Interface_GraphContent.cxx b/src/DataExchange/TKXSBase/Interface/Interface_GraphContent.cxx index 7fd6597b09..803669b60f 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_GraphContent.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_GraphContent.cxx @@ -79,4 +79,4 @@ void Interface_GraphContent::Begin() Interface_EntityIterator::Start(); } -void Interface_GraphContent::Evaluate() {} // par defaut, Evaluate ne fait rien +void Interface_GraphContent::Evaluate() {} // by default, Evaluate does nothing diff --git a/src/DataExchange/TKXSBase/Interface/Interface_IntList.cxx b/src/DataExchange/TKXSBase/Interface/Interface_IntList.cxx index b8b1e2ff2f..a9e17bafdb 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_IntList.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_IntList.cxx @@ -15,20 +15,20 @@ #include <Interface_IntList.hxx> -// Organisation des donnees : -// theents vaut : 0 pas de reference -// > 0 : une reference, dont voici la valeur; pas de liste -// < 0 : une liste de references; on stocke <rank>, elle debute a <rank>+1 -// la liste est dans therefs et est ainsi constitue : -// liste de valeurs negatives, se terminant pas une valeur positive : -// de <rank>+1 a <rank>+nb , <rank>+1 a <rank>+nb-1 sont negatifs et -// <rank>+nb est negatif -// un zero signifie : place libre -// Pre-reservation : <rank> note le nombre courant, en positif strict -// Il faut alors l incrementer a chaque ajout -// Usage contextuel, il faut demander SetNumber(num < 0) pour exploiter cette -// info et Add(ref < 0) pour la gerer. -// Si elle n est pas presente, on bascule en mode courant +// Data organization : +// theents value : 0 no reference +// > 0 : one reference, here is the value; no list +// < 0 : a list of references; we store <rank>, it starts at <rank>+1 +// the list is in therefs and is thus constituted : +// list of negative values, ending with a positive value : +// from <rank>+1 to <rank>+nb , <rank>+1 to <rank>+nb-1 are negative and +// <rank>+nb is negative +// a zero means : free space +// Pre-reservation : <rank> notes the current number, in strict positive +// It must then be incremented at each addition +// Contextual usage, you must call SetNumber(num < 0) to exploit this +// info and Add(ref < 0) to manage it. +// If it is not present, we switch to current mode Interface_IntList::Interface_IntList() { thenbe = thenbr = thenum = thecount = therank = 0; @@ -98,8 +98,8 @@ void Interface_IntList::SetNbEntities(const Standard_Integer nbe) void Interface_IntList::SetNumber(const Standard_Integer number) { - // Usage en pre-reservation : a demander specifiquement ! -> optimisation - // <preres> verifie que la pre-reservation est valide + // Pre-reservation usage : to be requested specifically ! -> optimization + // <preres> verifies that the pre-reservation is valid if (number < 0) { if (thenum == -number || number < -thenbe) @@ -127,7 +127,7 @@ void Interface_IntList::SetNumber(const Standard_Integer number) if (preres) return; } - // Usage courant. La suite en usage courant ou si pas de pre-reservation + // Current usage. The following in current usage or if no pre-reservation else if (number > 0) { if (thenum == number || number > thenbe) @@ -222,14 +222,14 @@ void Interface_IntList::SetRedefined(const Standard_Boolean mode) void Interface_IntList::Reservate(const Standard_Integer count) { - // Reservate (-count) = Reservate (count) + allocation sur entite courante + 1 + // Reservate (-count) = Reservate (count) + allocation on current entity + 1 if (count < 0) { Reservate(-count - 1); if (thenum == 0) return; thenbr++; - therefs->SetValue(thenbr, 0); // contiendra le nombre ... + therefs->SetValue(thenbr, 0); // will contain the number ... therank = thenbr; theents->SetValue(thenum, -thenbr); thenbr -= count; @@ -237,7 +237,7 @@ void Interface_IntList::Reservate(const Standard_Integer count) } Standard_Integer up, oldup = 0; if (thenbr == 0) - { // c-a-d pas encore allouee ... + { // i.e. not yet allocated ... up = thenbe / 2 + 1; if (up < 2) up = 2; @@ -245,7 +245,7 @@ void Interface_IntList::Reservate(const Standard_Integer count) up = count * 3 / 2; therefs = new TColStd_HArray1OfInteger(0, up); therefs->Init(0); - thenbr = 2; // on commence apres (commodite d adressage) + thenbr = 2; // we start after (convenience of addressing) } oldup = therefs->Upper(); if (thenbr + count < oldup) @@ -297,20 +297,20 @@ void Interface_IntList::Add(const Standard_Integer ref) thecount++; } else if (thenbr == therank + thecount) - { // place libre en fin + { // free space at end therefs->SetValue(thenbr, -therefs->Value(thenbr)); therefs->SetValue(thenbr + 1, ref); thenbr++; thecount++; } else if (therefs->Value(therank + thecount + 1) == 0) - { // place libre apres + { // free space after therefs->SetValue(therank + thecount, -therefs->Value(therank + thecount)); therefs->SetValue(therank + thecount + 1, ref); thecount++; } else - { // recopier plus loin ! + { // copy further ! Reservate(thecount + 2); Standard_Integer rank = therank; therank = thenbr; @@ -367,7 +367,7 @@ Standard_Boolean Interface_IntList::Remove(const Standard_Integer) void Interface_IntList::Clear() { if (thenbr == 0) - return; // deja clear + return; // already clear Standard_Integer i, low, up; low = theents->Lower(); up = theents->Upper(); diff --git a/src/DataExchange/TKXSBase/Interface/Interface_InterfaceModel.cxx b/src/DataExchange/TKXSBase/Interface/Interface_InterfaceModel.cxx index b99655511e..fdb80558c8 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_InterfaceModel.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_InterfaceModel.cxx @@ -34,12 +34,12 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_InterfaceModel, Standard_Transient) -// Un Modele d`Interface est un ensemble ferme d`Entites d`interface : chacune -// est dans un seul modele a la fois; elle y a un numero (Number) qui permet de -// verifier qu`une entite est bien dans un seul modele, de definir des Map tres -// performantes, de fournir un identifieur numerique -// Il est a meme d`etre utilise dans des traitements de Graphe -// STATICS : les TEMPLATES +// An Interface Model is a closed set of interface Entities: each one +// is in a single model at a time; it has a number (Number) which allows to +// verify that an entity is indeed in a single model, to define very +// efficient Maps, to provide a numerical identifier +// It is able to be used in Graph processing +// STATICS : the TEMPLATES static NCollection_DataMap<TCollection_AsciiString, Handle(Standard_Transient)> atemp; static const Handle(Standard_Type)& typerep() @@ -65,9 +65,9 @@ Interface_InterfaceModel::Interface_InterfaceModel() //================================================================================================= -void Interface_InterfaceModel::Destroy() // on fait un mimumum +void Interface_InterfaceModel::Destroy() // we do a minimum { - // Moins que Clear que, lui, est adapte a chaque norme + // Less than Clear which, itself, is adapted to each standard ClearEntities(); thecheckstx->Clear(); thechecksem->Clear(); @@ -148,7 +148,7 @@ void Interface_InterfaceModel::ClearEntities() theentities.Clear(); } -// .... ACCES AUX ENTITES .... +// .... ENTITY ACCESS .... //================================================================================================= @@ -204,7 +204,7 @@ Standard_Integer Interface_InterfaceModel::DENumber } */ -// .. Acces Speciaux (Report, etc...) .. +// .. Special Access (Report, etc...) .. //================================================================================================= @@ -434,7 +434,7 @@ void Interface_InterfaceModel::FillSemanticChecks(const Interface_CheckIterator& { const Handle(Interface_Check)& ach = checks.Value(); Standard_Integer num = checks.Number(); - // global check : ok si MEME MODELE + // global check : ok if SAME MODEL if (num == 0) thechecksem->GetMessages(ach); else @@ -480,7 +480,7 @@ const Handle(Interface_Check)& Interface_InterfaceModel::Check( return rep->Check(); } -// .... Chargement des donnees du Modele .... // +// .... Loading of Model data .... // //================================================================================================= @@ -499,7 +499,7 @@ void Interface_InterfaceModel::AddEntity(const Handle(Standard_Transient)& anent // Standard_Integer newnum; svv #2 if (!anentity->IsKind(typerep())) theentities.Add(anentity); - // Report : Ajouter Concerned, mais noter presence Report et sa valeur + // Report : Add Concerned, but note presence Report and its value else { Handle(Interface_ReportEntity) rep = Handle(Interface_ReportEntity)::DownCast(anentity); @@ -511,8 +511,8 @@ void Interface_InterfaceModel::AddEntity(const Handle(Standard_Transient)& anent } } -// AddWithRefs itere sur les Entities referencees pour charger une Entite -// au complet, avec tout ce dont elle a besoin +// AddWithRefs iterates on referenced Entities to load an Entity +// completely, with everything it needs //================================================================================================= @@ -569,13 +569,13 @@ void Interface_InterfaceModel::AddWithRefs(const Handle(Standard_Transient)& ane if (lib.Select(anent, module, CN)) { module->FillSharedCase(CN, anent, iter); - // FillShared tout court : supposerait que le modele soit deja pret - // or justement, on est en train de le construire ... + // FillShared simply : would suppose that the model is already ready + // or precisely, we are in the process of building it ... module->ListImpliedCase(CN, anent, iter); } Standard_Integer lev1 = level - 1; if (lev1 == 0) - return; // level = 0 -> tous niveaux; sinon encore n-1 + return; // level = 0 -> all levels; otherwise still n-1 for (iter.Start(); iter.More(); iter.Next()) AddWithRefs(iter.Value(), lib, lev1, listall); } @@ -588,9 +588,9 @@ void Interface_InterfaceModel::ReplaceEntity(const Standard_Integer n theentities.Substitute(nument, anent); } -// ReverseOrders permet de mieux controler la numeration des Entites : -// Souvent, les fichiers mettent les racines en fin, tandis que AddWithRefs -// les met en tete. +// ReverseOrders allows better control of Entity numbering : +// Often, files put the roots at the end, while AddWithRefs +// puts them at the head. //================================================================================================= @@ -603,15 +603,15 @@ void Interface_InterfaceModel::ReverseOrders(const Standard_Integer after) Standard_Integer i; // svv #1 for (i = 1; i <= nb; i++) ents.SetValue(i, theentities.FindKey(i)); - // On va vider la Map, puis la recharger : dans l ordre jusqua after - // en ordre inverse apres + // We will empty the Map, then reload it : in order until after + // in reverse order after theentities.Clear(); Reservate(nb); for (i = 1; i <= after; i++) theentities.Add(ents(i)); // svv #2 for (i = nb; i > after; i--) theentities.Add(ents(i)); - // Faudra aussi s occuper des Reports + // Will also have to take care of the Reports for (i = nb; i > after; i--) { Standard_Integer i2 = nb + after - i; @@ -643,7 +643,7 @@ void Interface_InterfaceModel::ChangeOrder( if (nb < 2 || newnum >= nb || cnt <= 0) return; TColStd_Array1OfTransient ents(1, nb); - // On va preparer le changement + // We will prepare the change Standard_Integer minum = (oldnum > newnum ? newnum : oldnum); Standard_Integer mxnum = (oldnum < newnum ? newnum : oldnum); Standard_Integer kount = (oldnum > newnum ? cnt : -cnt); @@ -682,8 +682,8 @@ void Interface_InterfaceModel::ChangeOrder( } } -// GetFromTransfer permet de recuperer un resultat prepare par ailleurs -// Le Modele demarre a zero. Les entites doivent etre libres (cf AddEntity) +// GetFromTransfer allows to recover a result prepared elsewhere +// The Model starts at zero. Entities must be free (cf AddEntity) //================================================================================================= @@ -883,7 +883,7 @@ Standard_Integer Interface_InterfaceModel::NextNumberForLabel(const Standard_CSt } } - // En "non exact", on admet de recevoir le numero entre 1 et n + // In "non exact", we admit to receive the number between 1 and n if (exact) return 0; i = 0; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_LineBuffer.cxx b/src/DataExchange/TKXSBase/Interface/Interface_LineBuffer.cxx index 67009216f1..5651550358 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_LineBuffer.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_LineBuffer.cxx @@ -112,10 +112,10 @@ void Interface_LineBuffer::Prepare() myLine.SetValue(i, ' '); } } - // GERER KEEP : est-il jouable ? sinon, annuler. sioui, noter la jointure + // MANAGE KEEP: is it playable? otherwise, cancel. if yes, note the junction if (myKeep > 0) { - myKeep += (myInit + 1); // myInit, et +1 car Keep INCLUS + myKeep += (myInit + 1); // myInit, and +1 because Keep INCLUDED } if (myKeep > 0) { @@ -133,7 +133,7 @@ void Interface_LineBuffer::Prepare() void Interface_LineBuffer::Keep() { - // Si Keep, sauver de myKeep + 1 a myLen (+1 pour 0 final) + // If Keep, save from myKeep + 1 to myLen (+1 for final 0) if (myKeep > 0) { myLine.SetValue(1, myKept); diff --git a/src/DataExchange/TKXSBase/Interface/Interface_MSG.cxx b/src/DataExchange/TKXSBase/Interface/Interface_MSG.cxx index e9993eaf9f..9daf71de46 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_MSG.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_MSG.cxx @@ -273,7 +273,7 @@ void Interface_MSG::PrintTrace(Standard_OStream& S) } } -// ########### ARRONDIS DE FLOTTANTS ############ +// ########### FLOATING POINT ROUNDING ############ Standard_Real Interface_MSG::Intervalled(const Standard_Real val, const Standard_Integer order, @@ -352,7 +352,7 @@ Standard_Real Interface_MSG::Intervalled(const Standard_Real val, rst = (upper ? 10. : 7.); } else - { // n a de sens que jusqu a 10 ... + { // only makes sense up to 10 ... if (rst <= 1.2) rst = (upper ? 1.2 : 1.); else if (rst <= 1.5) @@ -388,9 +388,9 @@ void Interface_MSG::TDate(const Standard_CString text, const Standard_Integer ss, const Standard_CString format) { - // valeurs nulles : en tete (avec au moins une non nulle, la derniere) - // -> completees avec les valeurs actuelle (system date) - // tout nul on laisse + // null values : at the beginning (with at least one non-null, the last one) + // -> completed with current values (system date) + // all null we leave // svv #2 Standard_Integer y1 , m1 , d1 , h1 , n1 , s1; Standard_Integer y2 = yy, m2 = mm, d2 = dd, h2 = hh, n2 = mn, s2 = ss; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_ParamSet.cxx b/src/DataExchange/TKXSBase/Interface/Interface_ParamSet.cxx index dcdbb2a077..3be7e3c2ca 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_ParamSet.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_ParamSet.cxx @@ -26,21 +26,21 @@ Interface_ParamSet::Interface_ParamSet(const Standard_Integer nres, const Standa themxpar = nres; thenbpar = 0; thelnval = 0; - thelnres = 100; // *20; // 10 caracteres par Param (\0 inclus) : raisonnable + thelnres = 100; // *20; // 10 characters per Param (\0 included): reasonable theval = new char[thelnres]; // szv#4:S4163:12Mar99 `thelnres+1` chars was wrong } -// Append(CString) : Gestion des caracteres selon <lnval> -// Si lnval < 0, ParamSet passif, memoire geree de l exterieur, ParamSet -// se contente de s y referer -// Sinon, recopie dans une page locale +// Append(CString): Character management according to <lnval> +// If lnval < 0, ParamSet passive, memory managed externally, ParamSet +// just refers to it +// Otherwise, copy to a local page Standard_Integer Interface_ParamSet::Append(const Standard_CString val, const Standard_Integer lnval, const Interface_ParamType typ, const Standard_Integer nument) { - // Ici, gestion locale de String + // Here, local String management thenbpar++; if (thenbpar > themxpar) { @@ -49,7 +49,7 @@ Standard_Integer Interface_ParamSet::Append(const Standard_CString val, } else if (lnval < 0) { - // .. Gestion externe des caracteres .. + // .. External character management .. Interface_FileParameter& FP = thelist->ChangeValue(thenbpar); FP.Init(val, typ); if (nument != 0) @@ -57,19 +57,19 @@ Standard_Integer Interface_ParamSet::Append(const Standard_CString val, } else { - // .. Gestion locale des caracteres .. + // .. Local character management .. Standard_Integer i; if (thelnval + lnval + 1 > thelnres) { - // Reservation de caracteres insuffisante : d abord augmenter + // Insufficient character reservation: first increase Standard_Integer newres = (Standard_Integer)(thelnres * 2 + lnval); char* newval = new char[newres]; for (i = 0; i < thelnval; i++) newval[i] = theval[i]; // szv#4:S4163:12Mar99 `<= thelnres` was wrong - // et cepatou : il faut realigner les Params deja enregistres sur - // l ancienne reservation de caracteres ... + // and that's not all: must realign Params already recorded on + // the old character reservation ... // Standard_Integer delta = (Standard_Integer) (newval - theval); - // difference a appliquer + // difference to apply char* poldVal = &theval[0]; char* pnewVal = &newval[0]; for (i = 1; i < thenbpar; i++) @@ -81,16 +81,16 @@ Standard_Integer Interface_ParamSet::Append(const Standard_CString val, // if (oval < theval || oval >= (theval+thelnres)) // continue; //hors reserve //szv#4:S4163:12Mar99 `oval >` was wrong Standard_Integer onum = OFP.EntityNumber(); - OFP.Init(pnewVal + delta, otyp); // et voila; on remet dans la boite + OFP.Init(pnewVal + delta, otyp); // and there we go; we put back in the box if (onum != 0) OFP.SetEntityNumber(onum); } - // Enteriner la nouvelle reservation + // Confirm the new reservation delete[] theval; theval = newval; thelnres = newres; } - // Enregistrer ce parametre + // Register this parameter for (i = 0; i < lnval; i++) theval[thelnval + i] = val[i]; theval[thelnval + lnval] = '\0'; @@ -106,7 +106,7 @@ Standard_Integer Interface_ParamSet::Append(const Standard_CString val, Standard_Integer Interface_ParamSet::Append(const Interface_FileParameter& FP) { - // Ici, FP tout pret : pas de gestion memoire sur String (dommage) + // Here, FP ready: no memory management on String (too bad) thenbpar++; if (thenbpar > themxpar) @@ -158,7 +158,7 @@ Handle(Interface_ParamList) Interface_ParamSet::Params(const Standard_Integer nu n0 = 0; nbp = thenbpar; if (thenbpar <= themxpar) - return thelist; // et zou + return thelist; // and there you go } Handle(Interface_ParamList) list = new Interface_ParamList; if (nb == 0) @@ -173,7 +173,7 @@ void Interface_ParamSet::Destroy() { // if (!thenext.IsNull()) thenext->Destroy(); thenext.Nullify(); - // Destruction "manuelle" (gestion memoire directe) + // "Manual" destruction (direct memory management) if (theval) delete[] theval; theval = NULL; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_Protocol.cxx b/src/DataExchange/TKXSBase/Interface/Interface_Protocol.cxx index 232680ffed..bdbae21168 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_Protocol.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_Protocol.cxx @@ -20,7 +20,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_Protocol, Standard_Transient) -// Gestion du Protocol actif : tres simple, une variable statique +// Management of active Protocol: very simple, a static variable static Handle(Interface_Protocol)& theactive() { static Handle(Interface_Protocol) theact; @@ -48,7 +48,7 @@ void Interface_Protocol::ClearActive() theactive().Nullify(); } -// === Typage (formules fournies par defaut) +// === Typing (formulas provided by default) //================================================================================================= diff --git a/src/DataExchange/TKXSBase/Interface/Interface_Recognizer.gxx b/src/DataExchange/TKXSBase/Interface/Interface_Recognizer.gxx index 0a2a48d25c..0656920990 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_Recognizer.gxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_Recognizer.gxx @@ -14,21 +14,21 @@ //#include <Interface_Recognizer.ixx> #include <Standard_NoSuchObject.hxx> -// ATTENTION : TransRecognizer a exactement le meme code ... -// Mais produit un Transient au lieu d un Persistent +// WARNING: TransRecognizer has exactly the same code ... +// But produces a Transient instead of a Persistent -// Principe : a un objet de depart (cle), un Recognizer tente d'associer un -// resultat. La classe Recognizer offre le mecanisme general gerant cela -// Chaque classe particuliere (une fois definie l'instanciation) doit fournir -// une methode specifique Eval, qui opere la correspondance -// Eval considere l'objet par tous moyens appropries, et en cas de succes, -// appelle SetOK(result) puis sort (return) -// en cas d'echec, suite au retour d'Eval, Recognizer sait que SetOK n'a pas -// ete appele +// Principle: from a starting object (key), a Recognizer attempts to associate a +// result. The Recognizer class provides the general mechanism managing this +// Each particular class (once the instantiation is defined) must provide +// a specific Eval method, which performs the correspondence +// Eval considers the object by all appropriate means, and in case of success, +// calls SetOK(result) then exits (return) +// in case of failure, following the return from Eval, Recognizer knows that SetOK was not +// called Interface_Recognizer::Interface_Recognizer () { hasnext = Standard_False; } - //thekey.Nullify(); inutile, fait par le constructeur ... + //thekey.Nullify(); useless, done by the constructor ... Standard_Boolean Interface_Recognizer::Evaluate (const TheKey& akey, Handle(TheResul)& res) diff --git a/src/DataExchange/TKXSBase/Interface/Interface_STAT.cxx b/src/DataExchange/TKXSBase/Interface/Interface_STAT.cxx index 1c84e6f512..823fe04d66 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_STAT.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_STAT.cxx @@ -51,7 +51,7 @@ void Interface_STAT::AddPhase(const Standard_Real weight, const Standard_CString { if (thephw.IsNull()) { - // 1re fois : vider les steps deja notees + // 1st time : empty the already noted steps thetotal = 0.; thephnam = new TColStd_HSequenceOfAsciiString(); thephw = new TColStd_HSequenceOfReal(); @@ -71,7 +71,7 @@ void Interface_STAT::AddStep(const Standard_Real weight) { if (thephdeb.IsNull()) { - // 1re fois : pour default phase, au moins creer receptacle des steps + // 1st time : for default phase, at least create receptacle for steps thephdeb = new TColStd_HSequenceOfInteger(); thephfin = new TColStd_HSequenceOfInteger(); thestw = new TColStd_HSequenceOfReal(); @@ -79,11 +79,11 @@ void Interface_STAT::AddStep(const Standard_Real weight) thephfin->Append(1); thestw->Append(0.); } - // A present, ajouter cette etape + // Now, add this step Standard_Integer n0 = thephdeb->Value(thephdeb->Length()); - // Ceci donne dans thestw le numero du cumul des etapes + // This gives in thestw the number of the cumulative steps thestw->ChangeValue(n0) += weight; - thestw->Append(weight); // on ajoute cette etape + thestw->Append(weight); // we add this step thephfin->ChangeValue(thephfin->Length())++; } @@ -104,7 +104,7 @@ void Interface_STAT::Phase(const Standard_Integer num, { if (thephdeb.IsNull()) { - // Pas de phase, pas d etape ... donc une seule ... + // No phase, no step ... so only one ... n0step = -1; nbstep = 1; weight = 1.; @@ -112,7 +112,7 @@ void Interface_STAT::Phase(const Standard_Integer num, } if (thephw.IsNull()) { - // Pas de phase mais des etapes + // No phase but steps weight = 1.; name = voidname; } @@ -127,7 +127,7 @@ void Interface_STAT::Phase(const Standard_Integer num, nbstep = thephfin->Value(num); } - // Voyons pour cette phase + // Let's see for this phase } Standard_Real Interface_STAT::Step(const Standard_Integer num) const @@ -141,35 +141,35 @@ Standard_Real Interface_STAT::Step(const Standard_Integer num) const // ############### COMPTAGE ################ -// Le comptage se fait sur la base suivante : -// TOTAL : total des poids des phases par rapport auquel calculer -// PHASES : poids des phases passees et poids de la phase en cours -// Ces poids sont a ramener au TOTAL -// PHASE COURANTE : nb d items et nb de cycles declares -// Nb d items deja passes (cycle complet) -// CYCLE COURANT : nb d items de ce cycle, total des poids des etapes -// Poids des etapes deja passees, de l etape en cours, n0 etape en cours -// ETAPE COURANTE : nb d items deja passes +// The counting is done on the following basis : +// TOTAL : total of phase weights against which to calculate +// PHASES : weight of past phases and weight of current phase +// These weights are to be brought back to TOTAL +// CURRENT PHASE : nb of items and nb of declared cycles +// Nb of items already passed (complete cycle) +// CURRENT CYCLE : nb of items of this cycle, total of step weights +// Weight of steps already passed, of the current step, n0 current step +// CURRENT STEP : nb of items already passed static struct zestat { Standard_CString itle, name; - Standard_Real otal, // total des poids des phases - oldph, // poids des phases deja passes - phw, // poids de la phase en cours - otph, // poids des etapes de la phase en cours (cycle en cours) - oldst, // poids des etapes deja passees (cycle en cours) - stw; // poids etape en cours - Standard_Integer nbph, // total nb de phases - numph, // n0 phase en cours - n0, n1, // n0 et nb etapes dans phase en cours + Standard_Real otal, // total of phase weights + oldph, // weight of phases already passed + phw, // weight of the current phase + otph, // weight of steps in the current phase (current cycle) + oldst, // weight of steps already passed (current cycle) + stw; // weight of current step + Standard_Integer nbph, // total nb of phases + numph, // n0 current phase + n0, n1, // n0 and nb steps in current phase nbitp, // nb items total phase nbcyc, // nb cycles total phase - olditp, // nb items deja passes (cycles passes) / phase - numcyc, // n0 cycle en cours / phase - nbitc, // nb items cycle en cours - numst, // n0 etape en cours / cycle - numitem; // nb items deja passes / etape courante + olditp, // nb items already passed (cycles passed) / phase + numcyc, // n0 current cycle / phase + nbitc, // nb items current cycle + numst, // n0 current step / cycle + numitem; // nb items already passed / current step } TheStat; void Interface_STAT::Start(const Standard_Integer items, const Standard_Integer cycles) const @@ -189,7 +189,7 @@ void Interface_STAT::StartCount(const Standard_Integer items, const Standard_CSt void Interface_STAT::NextPhase(const Standard_Integer items, const Standard_Integer cycles) { - // On cumule la phase precedente au total, on efface les donnees "locales" + // We accumulate the previous phase to the total, we clear the "local" data TheStat.numcyc = TheStat.numst = TheStat.olditp = 0; TheStat.oldst = TheStat.stw = 0.; if (TheStat.numph >= TheStat.nbph) @@ -199,12 +199,12 @@ void Interface_STAT::NextPhase(const Standard_Integer items, const Standard_Inte } TheStat.numph++; - TheStat.oldph += TheStat.phw; // cumule sur cette phase + TheStat.oldph += TheStat.phw; // accumulate on this phase TheStat.nbitp = items; TheStat.nbcyc = cycles; statact.Phase(TheStat.numph, TheStat.n0, TheStat.n1, TheStat.phw, TheStat.name); TheStat.otph = (TheStat.n1 > 1 ? statact.Step(TheStat.n0) : 1.); - // si un seul cycle, on le demarre; sinon, attendre NextCycle + // if a single cycle, we start it; otherwise, wait NextCycle TheStat.nbitc = 0; if (cycles == 1) NextCycle(items); @@ -218,7 +218,7 @@ void Interface_STAT::SetPhase(const Standard_Integer items, const Standard_Integ void Interface_STAT::NextCycle(const Standard_Integer items) { - // cumul de ce cycle sur les cycles deja passes, raz etapes + // accumulation of this cycle on cycles already passed, reset steps TheStat.numcyc++; TheStat.olditp += TheStat.nbitc; // if (stat.olditem > stat.nbitp) return; @@ -262,18 +262,18 @@ Standard_Integer Interface_STAT::Percent(const Standard_Boolean phase) { if (TheStat.numitem > TheStat.nbitc) TheStat.numitem = TheStat.nbitc; - // on compte les items deja passes - Standard_Real enphase = TheStat.olditp * TheStat.otph + // cycles complets passes - TheStat.nbitc * TheStat.oldst + // cycle courant, etapes completes passees - TheStat.numitem * TheStat.stw; // etape courante - // proportion pour cette phase + // we count the items already passed + Standard_Real enphase = TheStat.olditp * TheStat.otph + // complete cycles passed + TheStat.nbitc * TheStat.oldst + // current cycle, complete steps passed + TheStat.numitem * TheStat.stw; // current step + // proportion for this phase Standard_Real prophase = enphase / (TheStat.nbitp * TheStat.otph); Standard_Integer res = Standard_Integer(prophase * 100.); if (phase) return res; - // voila pour cette phase - // comptage dans les phases + // that's it for this phase + // counting in the phases Standard_Real encours = (TheStat.oldph + TheStat.phw * prophase) / TheStat.otal; res = Standard_Integer(encours * 100.); return res; diff --git a/src/DataExchange/TKXSBase/Interface/Interface_ShareFlags.cxx b/src/DataExchange/TKXSBase/Interface/Interface_ShareFlags.cxx index 454ae7cbd4..f3f6fe9744 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_ShareFlags.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_ShareFlags.cxx @@ -67,7 +67,7 @@ Interface_ShareFlags::Interface_ShareFlags(const Interface_Graph& agraph) theroots = new TColStd_HSequenceOfTransient(); for (Standard_Integer i = 1; i <= nb; i++) { - // Resultat obtenu depuis le Graph + // Result obtained from the Graph Handle(Standard_Transient) ent = themodel->Value(i); Handle(TColStd_HSequenceOfTransient) list = agraph.GetSharings(ent); @@ -90,13 +90,13 @@ void Interface_ShareFlags::Evaluate(const Interface_GeneralLib& lib, for (i = 1; i <= nb; i++) { - // ATTENTION : Si Entite non chargee donc illisible, basculer sur son - // "Contenu" equivalent + // WARNING: If Entity not loaded hence unreadable, switch to its + // equivalent "Content" Handle(Standard_Transient) ent = themodel->Value(i); if (themodel->IsRedefinedContent(i)) ent = themodel->ReportEntity(i)->Content(); - // Resultat obtenu via GeneralLib + // Result obtained via GeneralLib Interface_EntityIterator iter; Handle(Interface_GeneralModule) module; Standard_Integer CN; @@ -111,7 +111,7 @@ void Interface_ShareFlags::Evaluate(const Interface_GeneralLib& lib, module->FillShared(themodel, CN, ent, iter); } - // Entites partagees par <ent> : reste a noter chacune comme "Shared" + // Entities shared by <ent>: need to mark each one as "Shared" for (iter.Start(); iter.More(); iter.Next()) { Standard_Integer num = themodel->Number(iter.Value()); diff --git a/src/DataExchange/TKXSBase/Interface/Interface_ShareTool.cxx b/src/DataExchange/TKXSBase/Interface/Interface_ShareTool.cxx index 4addc999d4..44d4e6f04b 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_ShareTool.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_ShareTool.cxx @@ -56,7 +56,7 @@ Interface_ShareTool::Interface_ShareTool(const Handle(Interface_HGraph)& ahgraph theHGraph = ahgraph; } -// Ajout des "Implied" sur toutes les Entites du Graphe +// Addition of "Implied" on all Entities of the Graph /*void Interface_ShareTool::AddImplied (const Handle(Interface_GTool)& gtool) { Interface_Graph& thegraph = theHGraph->CGraph(); @@ -171,7 +171,7 @@ Interface_EntityIterator Interface_ShareTool::All(const Handle(Standard_Transien fl->Init(0); if (ent == model) { - // On passe les racines en revue (l ordre de base est conserve) + // We review the roots (the base order is preserved) Interface_EntityIterator roots = RootEntities(); for (roots.Start(); roots.More(); roots.Next()) { @@ -185,7 +185,7 @@ Interface_EntityIterator Interface_ShareTool::All(const Handle(Standard_Transien fl->SetValue(nm, n0); } } - // Attention, y a t il des oublis ? + // Warning, are there any omissions? for (i = 1; i <= nb; i++) if (fl->Value(i) == 0) { @@ -197,20 +197,20 @@ Interface_EntityIterator Interface_ShareTool::All(const Handle(Standard_Transien { Handle(TColStd_HSequenceOfTransient) sq = new TColStd_HSequenceOfTransient(); sq->Append(ent); - // processus de type file + // file type process for (i = 1; i <= sq->Length(); i++) { // Length croit Handle(Standard_Transient) en = sq->Value(i); Standard_Integer num = model->Number(en); if (fl->Value(num) != 0) - continue; // deja vu + continue; // already seen n0++; fl->SetValue(num, n0); Interface_EntityIterator sh = Shareds(en); sq->Append(sh.Content()); } } - // Reste a constituer la liste, retourner si necessaire + // Remains to constitute the list, return if necessary Handle(TColStd_HArray1OfInteger) ord = new TColStd_HArray1OfInteger(0, nb); ord->Init(0); for (i = 1; i <= nb; i++) diff --git a/src/DataExchange/TKXSBase/Interface/Interface_Static.cxx b/src/DataExchange/TKXSBase/Interface/Interface_Static.cxx index d8d85a442f..5ce3d7020d 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_Static.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_Static.cxx @@ -23,7 +23,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_Static, Interface_TypedValue) static char defmess[31]; -// Fonctions Satisfies offertes en standard ... +// Satisfies functions offered as standard ... // svv #2 // static Standard_Boolean StaticPath(const Handle(TCollection_HAsciiString)& val) @@ -133,7 +133,7 @@ Standard_Boolean Interface_Static::UpdatedStatus() const } // ####################################################################### -// ######### DICTIONNAIRE DES STATICS (static sur Static) ########## +// ######### STATICS DICTIONARY (static on Static) ########## Standard_Boolean Interface_Static::Init(const Standard_CString family, const Standard_CString name, @@ -193,14 +193,14 @@ Standard_Boolean Interface_Static::Init(const Standard_CString family, Handle(Interface_Static) unstat = Interface_Static::Static(name); if (unstat.IsNull()) return Standard_False; - // Editions : init donne un petit texte d edition, en 2 termes "cmd var" : + // Editions : init gives a small edition text, in 2 terms "cmd var" : // imin <ival> imax <ival> rmin <rval> rmax <rval> unit <def> // enum <from> ematch <from> eval <cval> Standard_Integer i, iblc = 0; for (i = 0; init[i] != '\0'; i++) if (init[i] == ' ') iblc = i + 1; - // Reconnaissance du sous-cas et aiguillage + // Recognition of the sub-case and routing if (init[0] == 'i' && init[2] == 'i') unstat->SetIntegerLimit(Standard_False, atoi(&init[iblc])); else if (init[0] == 'i' && init[2] == 'a') @@ -335,7 +335,7 @@ Standard_Integer Interface_Static::IDef(const Standard_CString name, const Stand return 0; } -// ########## VALEUR COURANTE ########### +// ########## CURRENT VALUE ########### Standard_Boolean Interface_Static::IsSet(const Standard_CString name, const Standard_Boolean proper) { @@ -459,7 +459,7 @@ Handle(TColStd_HSequenceOfHAsciiString) Interface_Static::Items(const Standard_I ok = Standard_True; } else - { // tous ... sauf famille a $ + { // all ... except family with $ if (item->Family()[0] == '$') continue; } diff --git a/src/DataExchange/TKXSBase/Interface/Interface_StaticStandards.cxx b/src/DataExchange/TKXSBase/Interface/Interface_StaticStandards.cxx index a5bd809163..f1df50058d 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_StaticStandards.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_StaticStandards.cxx @@ -47,11 +47,11 @@ void Interface_Static::Standards() Interface_Static::Init("XSTEP", "read.maxprecision.val", 'r', "1."); // encode regularity - // negatif ou nul : ne rien faire. positif : on y va + // negative or null : do nothing. positive : let's go Interface_Static::Init("XSTEP", "read.encoderegularity.angle", 'r', "0.01"); // compute surface curves - // 0 : par defaut. 2 : ne garder que le 2D. 3 : ne garder que le 3D + // 0 : by default. 2 : keep only 2D. 3 : keep only 3D // gka S4054 Interface_Static::Init("XSTEP", "read.surfacecurve.mode", 'e', ""); Interface_Static::Init("XSTEP", "read.surfacecurve.mode", '&', "ematch -3"); @@ -84,8 +84,8 @@ void Interface_Static::Standards() // Interface_Static::Init("XSTEP" ,"write.surfacecurve.mode", '&',"eval NoAnalytic"); Interface_Static::SetIVal("write.surfacecurve.mode", 1); - // lastpreci : pour recuperer la derniere valeur codee (cf XSControl) - // (0 pour dire : pas codee) + // lastpreci : to recover the last encoded value (cf XSControl) + // (0 to say : not encoded) //: S4136 Interface_Static::Init("std" ,"lastpreci", 'r',"0."); // load messages if needed diff --git a/src/DataExchange/TKXSBase/Interface/Interface_TypedValue.cxx b/src/DataExchange/TKXSBase/Interface/Interface_TypedValue.cxx index c5fbd9ee10..6477866766 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_TypedValue.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_TypedValue.cxx @@ -42,9 +42,9 @@ Interface_ParamType Interface_TypedValue::Type() const MoniTool_ValueType Interface_TypedValue::ParamTypeToValueType(const Interface_ParamType type) { return (MoniTool_ValueType)type; -} // meme valeurs +} // same values Interface_ParamType Interface_TypedValue::ValueTypeToParamType(const MoniTool_ValueType type) { return (Interface_ParamType)type; -} // meme valeurs +} // same values diff --git a/src/DataExchange/TKXSBase/Interface/Interface_UndefinedContent.cxx b/src/DataExchange/TKXSBase/Interface/Interface_UndefinedContent.cxx index e371f75ca8..98bb585b02 100644 --- a/src/DataExchange/TKXSBase/Interface/Interface_UndefinedContent.cxx +++ b/src/DataExchange/TKXSBase/Interface/Interface_UndefinedContent.cxx @@ -27,8 +27,8 @@ IMPLEMENT_STANDARD_RTTIEXT(Interface_UndefinedContent, Standard_Transient) #define Content_LocalShift 5 #define Content_NumberShift 8 -// Cette classe donne les services de base pour definir des entites -// Unknown (ceci, a defaut d'un double heritage) : description litterale +// This class provides basic services for defining entities +// Unknown (this, for lack of double inheritance) : literal description Interface_UndefinedContent::Interface_UndefinedContent() // Unknown { @@ -36,18 +36,18 @@ Interface_UndefinedContent::Interface_UndefinedContent() // Unknown thenbstr = 0; } -// .... Les Parametres .... +// .... The Parameters .... -// Les parametres sont organises comme suit (pas de FileParameter) : -// - une liste de descripteurs (tenant sur un entier chacun) en tableau, avec -// la localisation (Entity/literal), le type (ParamType), le rang dans la -// la liste ad hoc (Entity ou literal) -// (5 bits droits pour type; 3 bits pour localisation; restant pouradresse) -// - pour les litteraux, une liste de String (tableau) -// - pour les Entity, une liste d Entites (EntityList) -// L aspect "place memoire" fait preferer des Tableaux a des Sequences, bien -// que ces dernieres soient plus simples a gerer -// En effet, il faut reserver et etendre si necessaire ... +// The parameters are organized as follows (no FileParameter) : +// - a list of descriptors (each fitting in an integer) in array, with +// the location (Entity/literal), the type (ParamType), the rank in the +// the ad hoc list (Entity or literal) +// (5 right bits for type; 3 bits for location; remaining for address) +// - for literals, a list of String (array) +// - for Entity, a list of Entities (EntityList) +// The "memory space" aspect makes Arrays preferable to Sequences, even though +// the latter are simpler to manage +// Indeed, we must reserve and extend if necessary ... Standard_Integer Interface_UndefinedContent::NbParams() const { @@ -104,18 +104,18 @@ Handle(TCollection_HAsciiString) Interface_UndefinedContent::ParamValue( return thevalues->Value(desc >> Content_NumberShift); } -// .... Remplissage des parametres .... +// .... Parameter filling .... void Interface_UndefinedContent::Reservate(const Standard_Integer nb, const Standard_Integer nblit) { - // Reservation : Si agrandissement, recopier ancien dans nouveau ... + // Reservation: If enlargement, copy old to new ... if (nb > thenbparams) - { // Reservation en total + { // Total reservation if (theparams.IsNull()) theparams = new TColStd_HArray1OfInteger(1, nb); else if (nb > theparams->Length()) { - Standard_Integer nbnew = 2 * thenbparams; // on reserve un peu large + Standard_Integer nbnew = 2 * thenbparams; // reserve a bit more if (nbnew < nb) nbnew = nb; Handle(TColStd_HArray1OfInteger) newparams = new TColStd_HArray1OfInteger(1, nbnew); @@ -126,12 +126,12 @@ void Interface_UndefinedContent::Reservate(const Standard_Integer nb, const Stan } if (nblit > thenbstr) - { // Reservation en Litteraux + { // Literal reservation if (thevalues.IsNull()) thevalues = new Interface_HArray1OfHAsciiString(1, nblit); else if (nblit > thevalues->Length()) { - Standard_Integer nbnew = 2 * thenbstr; // on reserve un peu large + Standard_Integer nbnew = 2 * thenbstr; // reserve a bit more if (nbnew < nblit) nbnew = nblit; Handle(Interface_HArray1OfHAsciiString) newvalues = @@ -141,7 +141,7 @@ void Interface_UndefinedContent::Reservate(const Standard_Integer nb, const Stan thevalues = newvalues; } } - // Entites : Parametres - Litteraux. En fait, EntityList est dynamique + // Entities: Parameters - Literals. In fact, EntityList is dynamic } void Interface_UndefinedContent::AddLiteral(const Interface_ParamType ptype, @@ -162,13 +162,13 @@ void Interface_UndefinedContent::AddEntity(const Interface_ParamType pty Reservate(thenbparams + 1, 0); Standard_Integer desc = Standard_Integer(ptype); theentities.Append(ent); - desc += Content_LocalRef << Content_LocalShift; // "C est une Entite" - thenbparams++; // Rang : thenbparams - thenbstr + desc += Content_LocalRef << Content_LocalShift; // "It is an Entity" + thenbparams++; // Rank: thenbparams - thenbstr desc += ((thenbparams - thenbstr) << Content_NumberShift); theparams->SetValue(thenbparams, desc); } -// .... Edition des parametres .... +// .... Parameter editing .... void Interface_UndefinedContent::RemoveParam(const Standard_Integer num) { @@ -176,25 +176,25 @@ void Interface_UndefinedContent::RemoveParam(const Standard_Integer num) Standard_Integer rang = desc >> Content_NumberShift; Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField); Standard_Boolean c1ent = (local == Content_LocalRef); - // Supprimer une Entite + // Remove an Entity if (c1ent) theentities.Remove(rang); - // Supprimer un Literal + // Remove a Literal else - { // thevalues->Remove(rang) mais c est un tableau + { // thevalues->Remove(rang) but it is an array for (Standard_Integer i = rang + 1; i <= thenbstr; i++) thevalues->SetValue(i - 1, thevalues->Value(i)); Handle(TCollection_HAsciiString) nulstr; thevalues->SetValue(thenbstr, nulstr); thenbstr--; } - // Supprimer ce parametre de la liste (qui est un tableau) + // Remove this parameter from the list (which is an array) Standard_Integer np; // svv Jan11 2000 : porting on DEC for (np = num + 1; np <= thenbparams; np++) theparams->SetValue(np - 1, theparams->Value(np)); theparams->SetValue(thenbparams, 0); thenbparams--; - // Renumeroter, Entite ou Literal, selon + // Renumber, Entity or Literal, depending for (np = 1; np <= thenbparams; np++) { desc = theparams->Value(np); @@ -208,15 +208,15 @@ void Interface_UndefinedContent::SetLiteral(const Standard_Integer const Interface_ParamType ptype, const Handle(TCollection_HAsciiString)& val) { - // On change un parametre. Si deja literal, simple substitution - // Si Entite, supprimer l entite et renumeroter les Parametres "Entite" + // Change a parameter. If already literal, simple substitution + // If Entity, remove the entity and renumber the "Entity" Parameters Standard_Integer desc = theparams->Value(num); Standard_Integer rang = desc >> Content_NumberShift; Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField); Standard_Boolean c1ent = (local == Content_LocalRef); if (c1ent) { - // Entite : la supprimer et renumeroter les Parametres de type "Entity" + // Entity: remove it and renumber the "Entity" type Parameters theentities.Remove(rang); for (Standard_Integer i = 1; i <= thenbparams; i++) { @@ -225,12 +225,12 @@ void Interface_UndefinedContent::SetLiteral(const Standard_Integer && (desc >> Content_NumberShift) > rang) theparams->SetValue(i, desc - (1 << Content_NumberShift)); } - // Et Preparer arrivee d un Literal supplementaire + // And prepare arrival of an additional Literal Reservate(thenbparams, thenbstr + 1); thenbstr++; rang = thenbstr; } - // Mettre en place la nouvelle valeur et reconstruire le descripteur du Param + // Put the new value in place and rebuild the Param descriptor thevalues->SetValue(rang, val); desc = Standard_Integer(ptype) + (rang << Content_NumberShift); theparams->SetValue(num, desc); @@ -240,16 +240,16 @@ void Interface_UndefinedContent::SetEntity(const Standard_Integer num const Interface_ParamType ptype, const Handle(Standard_Transient)& ent) { - // On change un Parametre. Si deja Entity, simple substitution - // Si Literal, supprimer sa valeur et renumeroter les parametres Litteraux + // Change a Parameter. If already Entity, simple substitution + // If Literal, remove its value and renumber the Literal parameters Standard_Integer desc = theparams->Value(num); Standard_Integer rang = desc >> Content_NumberShift; Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField); Standard_Boolean c1ent = (local == Content_LocalRef); if (!c1ent) { - // Literal : le supprimer et renumeroter les Parametres de type "Entity" - // (Remove Literal mais dans un tableau) + // Literal: remove it and renumber the "Entity" type Parameters + // (Remove Literal but in an array) Standard_Integer i; // svv Jan11 2000 : porting on DEC for (i = rang + 1; i <= thenbstr; i++) thevalues->SetValue(i - 1, thevalues->Value(i)); @@ -263,10 +263,10 @@ void Interface_UndefinedContent::SetEntity(const Standard_Integer num && (desc >> Content_NumberShift) > rang) theparams->SetValue(i, desc - (1 << Content_NumberShift)); } - // Et Preparer arrivee d une Entite supplementaire + // And prepare arrival of an additional Entity thenbstr--; rang = thenbparams - thenbstr; - // Mettre en place la nouvelle valeur et reconstruire le descripteur du Param + // Put the new value in place and rebuild the Param descriptor theentities.Append(ent); } else @@ -280,8 +280,8 @@ void Interface_UndefinedContent::SetEntity(const Standard_Integer num void Interface_UndefinedContent::SetEntity(const Standard_Integer num, const Handle(Standard_Transient)& ent) { - // On change l Entite definie par un Parametre, toutes autres choses egales, - // A CONDITION que ce soit deja un Parametre de type "Entity" + // Change the Entity defined by a Parameter, all other things being equal, + // PROVIDED that it is already an "Entity" type Parameter Standard_Integer desc = theparams->Value(num); Standard_Integer rang = desc >> Content_NumberShift; Standard_Integer local = ((desc >> Content_LocalShift) & Content_LocalField); @@ -296,7 +296,7 @@ Interface_EntityList Interface_UndefinedContent::EntityList() const return theentities; } -// toutes les recopies de UndefinedEntity se ressemblent ... Partie commune +// all copies of UndefinedEntity are similar ... Common part void Interface_UndefinedContent::GetFromAnother(const Handle(Interface_UndefinedContent)& other, Interface_CopyTool& TC) { diff --git a/src/DataExchange/TKXSBase/LibCtl/LibCtl_GlobalNode.gxx b/src/DataExchange/TKXSBase/LibCtl/LibCtl_GlobalNode.gxx index a989a1dad2..eebf95ccc4 100644 --- a/src/DataExchange/TKXSBase/LibCtl/LibCtl_GlobalNode.gxx +++ b/src/DataExchange/TKXSBase/LibCtl/LibCtl_GlobalNode.gxx @@ -14,15 +14,15 @@ //#include <LibCtl_GlobalNode.ixx> -// Classe generique imbriquee dans Library : utilisee pour construire les -// listes globales de Modules attaches a une classe instanciee de Library -// (cf Library pour plus de details) +// Generic class nested in Library: used to build the +// global lists of Modules attached to an instantiated class of Library +// (see Library for more details) LibCtl_GlobalNode::LibCtl_GlobalNode () { } -// ATTENTION, Add agit en substitution : pour un Protocol donne, c est le -// dernier appel qui l emporte +// WARNING, Add acts as substitution: for a given Protocol, it is the +// last call wins void LibCtl_GlobalNode::Add (const Handle(TheModule)& amodule, const Handle(TheProtocol)& aprotocol) { diff --git a/src/DataExchange/TKXSBase/LibCtl/LibCtl_Library.gxx b/src/DataExchange/TKXSBase/LibCtl/LibCtl_Library.gxx index d7fcef9f2b..ae4146d7db 100644 --- a/src/DataExchange/TKXSBase/LibCtl/LibCtl_Library.gxx +++ b/src/DataExchange/TKXSBase/LibCtl/LibCtl_Library.gxx @@ -16,19 +16,19 @@ #include <Standard_NoSuchObject.hxx> -// Liste Globale des Modules, dans laquelle on va se servir +// Global List of Modules, from which we will be served static Handle(LibCtl_GlobalNode) theglobal; -// Donnees pour optimisation (dernier Protocole demande) +// Data for optimization (last Protocol requested) static Handle(TheProtocol) theprotocol; static Handle(LibCtl_Node) thelast; -// Alimentation de la liste globale -// ATTENTION : SetGlobal fait de la substitution, c-a-d que c est le dernier -// qui a raison pour un Protocol donne +// Feeding the global list +// WARNING: SetGlobal performs substitution, i.e. it's the last one +// that is right for a given Protocol void LibCtl_Library::SetGlobal (const Handle(TheModule)& amodule, const Handle(TheProtocol)& aprotocol) { @@ -36,19 +36,19 @@ static Handle(LibCtl_Node) thelast; theglobal->Add(amodule,aprotocol); } -// Constructeur d apres Protocole +// Constructor from Protocol LibCtl_Library::LibCtl_Library (const Handle(TheProtocol)& aprotocol) { Standard_Boolean last = Standard_False; - if (aprotocol.IsNull()) return; // PAS de protocole = Lib VIDE + if (aprotocol.IsNull()) return; // NO protocol = EMPTY Lib if (!theprotocol.IsNull()) last = (theprotocol == aprotocol); if (last) thelist = thelast; -// Si Pas d optimisation disponible : construire la liste +// If no optimization available: build the list else { AddProtocol(aprotocol); -// Ceci definit l optimisation (pour la fois suivante) +// This defines the optimization (for the next time) thelast = thelist; theprotocol = aprotocol; } @@ -58,16 +58,16 @@ static Handle(LibCtl_Node) thelast; LibCtl_Library::LibCtl_Library () { } -// Ajout d un Protocol : attention, desoptimise (sinon risque de confusion !) +// Adding a Protocol: beware, deoptimizes (otherwise risk of confusion!) void LibCtl_Library::AddProtocol (const Handle(Standard_Transient)& aprotocol) { -// DownCast car Protocol->Resources, meme redefini et utilise dans d autres -// librairies, doit toujours renvoyer le type le plus haut +// DownCast because Protocol->Resources, even redefined and used in other +// libraries, must always return the highest type Handle(TheProtocol) aproto = Handle(TheProtocol)::DownCast(aprotocol); if (aproto.IsNull()) return; -// D abord, ajouter celui-ci a la liste : chercher le Node +// First, add this one to the list: search for the Node Handle(LibCtl_GlobalNode) curr; for (curr = theglobal; !curr.IsNull(); ) { // curr->Next : plus loin const Handle(TheProtocol)& protocol = curr->Protocol(); @@ -79,14 +79,14 @@ static Handle(LibCtl_Node) thelast; break; // UN SEUL MODULE PAR PROTOCOLE } } - curr = curr->Next(); // cette formule est refusee dans "for" + curr = curr->Next(); // this formula is refused in "for" } -// Ensuite, Traiter les ressources +// Then, process the resources Standard_Integer nb = aproto->NbResources(); for (Standard_Integer i = 1; i <= nb; i ++) { AddProtocol (aproto->Resource(i)); } -// Ne pas oublier de desoptimiser +// Don't forget to deoptimize theprotocol.Nullify(); thelast.Nullify(); } @@ -97,25 +97,25 @@ static Handle(LibCtl_Node) thelast; void LibCtl_Library::SetComplete () { thelist = new LibCtl_Node; -// On prend chacun des Protocoles de la Liste Globale et on l ajoute +// We take each of the Protocols from the Global List and add it Handle(LibCtl_GlobalNode) curr; for (curr = theglobal; !curr.IsNull(); ) { // curr->Next : plus loin const Handle(TheProtocol)& protocol = curr->Protocol(); -// Comme on prend tout tout tout, on ne se preoccupe pas des Ressources ! +// Since we take everything, we don't worry about Resources! if (!protocol.IsNull()) thelist->AddNode(curr); - curr = curr->Next(); // cette formule est refusee dans "for" + curr = curr->Next(); // this formula is refused in "for" } } -// Selection : Tres fort, on retourne le Module correspondant a un Type -// (ainsi que le CaseNumber retourne par le protocole correspondant) +// Selection: Very powerful, we return the Module corresponding to a Type +// (as well as the CaseNumber returned by the corresponding protocol) Standard_Boolean LibCtl_Library::Select (const TheObject& obj, Handle(TheModule)& module, Standard_Integer& CN) const { - module.Nullify(); CN = 0; // Reponse "pas trouve" + module.Nullify(); CN = 0; // Response "not found" if (thelist.IsNull()) return Standard_False; Handle(LibCtl_Node) curr = thelist; for (curr = thelist; !curr.IsNull(); ) { // curr->Next : plus loin @@ -127,9 +127,9 @@ static Handle(LibCtl_Node) thelast; return Standard_True; } } - curr = curr->Next(); // cette formule est refusee dans "for" + curr = curr->Next(); // this formula is refused in "for" } - return Standard_False; // ici, pas trouce + return Standard_False; // here, not found } diff --git a/src/DataExchange/TKXSBase/LibCtl/LibCtl_Node.gxx b/src/DataExchange/TKXSBase/LibCtl/LibCtl_Node.gxx index 831defa677..36c98b6b44 100644 --- a/src/DataExchange/TKXSBase/LibCtl/LibCtl_Node.gxx +++ b/src/DataExchange/TKXSBase/LibCtl/LibCtl_Node.gxx @@ -15,9 +15,9 @@ //#include <LibCtl_Node.ixx> -// Classe generique imbriquee dans Library : utilisee pour construire la -// listes de Modules d une librairie (cf Library pour plus de details) -// (En fait : Liste de Global Nodes -> Module + Protocol) +// Generic class nested in Library: used to build the +// lists of Modules of a library (see Library for more details) +// (In fact: List of Global Nodes -> Module + Protocol) LibCtl_Node::LibCtl_Node () { } diff --git a/src/DataExchange/TKXSBase/MoniTool/MoniTool_CaseData.cxx b/src/DataExchange/TKXSBase/MoniTool/MoniTool_CaseData.cxx index 52995b2604..7d0ead7621 100644 --- a/src/DataExchange/TKXSBase/MoniTool/MoniTool_CaseData.cxx +++ b/src/DataExchange/TKXSBase/MoniTool/MoniTool_CaseData.cxx @@ -35,7 +35,7 @@ static NCollection_DataMap<TCollection_AsciiString, Handle(Standard_Transient)> static Standard_Boolean stachr = Standard_False; // static OSD_Timer chrono; -// because merdouille link dynamique & perf, ne creer le static qu au 1er usage +// because mess of dynamic link & perf, only create the static on 1st usage static OSD_Timer& chrono() { static OSD_Timer chr; @@ -124,7 +124,7 @@ void MoniTool_CaseData::AddData(const Handle(Standard_Transient)& val, TCollection_AsciiString aname(name); Standard_Integer subs = thesubst; - // SetChange (calculer la position d apres Name) + // SetChange (calculate position from Name) if (thesubst < 0) { if (name[0] != '\0') @@ -393,7 +393,7 @@ Standard_Integer MoniTool_CaseData::NameNum(const Standard_CString name) const return 0; } -// #### RETOUR DES VALEURS #### +// #### RETURN OF VALUES #### TopoDS_Shape MoniTool_CaseData::Shape(const Standard_Integer nd) const { @@ -463,7 +463,7 @@ Standard_Boolean MoniTool_CaseData::Integer(const Standard_Integer nd, Standard_ return Standard_True; } -// #### MESSAGES ET DEFINITIONS #### +// #### MESSAGES AND DEFINITIONS #### Message_Msg MoniTool_CaseData::Msg() const { diff --git a/src/DataExchange/TKXSBase/MoniTool/MoniTool_TypedValue.cxx b/src/DataExchange/TKXSBase/MoniTool/MoniTool_TypedValue.cxx index bc3f8159c5..c4ac5fc896 100644 --- a/src/DataExchange/TKXSBase/MoniTool/MoniTool_TypedValue.cxx +++ b/src/DataExchange/TKXSBase/MoniTool/MoniTool_TypedValue.cxx @@ -145,7 +145,7 @@ MoniTool_TypedValue::MoniTool_TypedValue(const Handle(MoniTool_TypedValue)& othe theeadds.Bind(itad.Key(), itad.Value()); } - // on duplique la string + // we duplicate the string if (!thehval.IsNull()) thehval = new TCollection_HAsciiString(other->CStringValue()); } @@ -323,14 +323,14 @@ void MoniTool_TypedValue::PrintValue(Standard_OStream& S) const Standard_Boolean MoniTool_TypedValue::AddDef(const Standard_CString init) { - // Editions : init donne un petit texte d edition, en 2 termes "cmd var" : + // Editions : init gives a small edition text, in 2 terms "cmd var" : Standard_Integer i, iblc = 0; for (i = 0; init[i] != '\0'; i++) if (init[i] == ' ') iblc = i + 1; if (iblc == 0) return Standard_False; - // Reconnaissance du sous-cas et aiguillage + // Recognition of sub-case and routing if (init[0] == 'i' && init[2] == 'i') // imin ival SetIntegerLimit(Standard_False, atoi(&init[iblc])); else if (init[0] == 'i' && init[2] == 'a') // imax ival @@ -458,7 +458,7 @@ Standard_CString MoniTool_TypedValue::UnitDef() const return theunidef.ToCString(); } -// ****** les enums ****** +// ****** the enums ****** void MoniTool_TypedValue::StartEnum(const Standard_Integer start, const Standard_Boolean match) { @@ -583,7 +583,7 @@ void MoniTool_TypedValue::AddEnumValue(const Standard_CString val, const Standar { theenums->SetValue(num, TCollection_AsciiString(val)); } - // On met AUSSI dans le dictionnaire + // We ALSO put in the dictionary // else { theeadds.Bind(val, num); // } @@ -678,7 +678,7 @@ Standard_CString MoniTool_TypedValue::SatisfiesName() const return thesatisn.ToCString(); } -// ########### VALEUR DU STATIC ############ +// ########### STATIC VALUE ############ Standard_Boolean MoniTool_TypedValue::IsSetValue() const { @@ -714,7 +714,7 @@ Handle(TCollection_HAsciiString) MoniTool_TypedValue::Interpret( return theinterp(this, hval, native); if (thetype == MoniTool_ValueEnum) { - // On admet les deux formes : Enum de preference, sinon Integer + // We accept both forms : Enum preferably, otherwise Integer Standard_Integer startcase, endcase; Standard_Boolean match; EnumDef(startcase, endcase, match); @@ -767,7 +767,7 @@ Standard_Boolean MoniTool_TypedValue::Satisfies(const Handle(TCollection_HAsciiS return Standard_True; } case MoniTool_ValueEnum: { - // On admet les deux formes : Enum de preference, sinon Integer + // We accept both forms : Enum preferably, otherwise Integer Standard_Integer startcase, endcase; // unused ival; Standard_Boolean match; EnumDef(startcase, endcase, match); @@ -775,7 +775,7 @@ Standard_Boolean MoniTool_TypedValue::Satisfies(const Handle(TCollection_HAsciiS return Standard_True; if (EnumCase(val->ToCString()) >= startcase) return Standard_True; - // Ici, on admet un entier dans la fourchette + // Here, we accept an integer in the range //// if (val->IsIntegerValue()) ival = atoi (val->ToCString()); // PTV 16.09.2000 The if is comment, cause this check is never been done (You can see the diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_FinderProcess.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_FinderProcess.cxx index 0e583d7918..a84a462155 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_FinderProcess.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_FinderProcess.cxx @@ -69,7 +69,7 @@ void Transfer_FinderProcess::PrintStats(const Standard_Integer mode, Standard_OS { S << "\n*******************************************************************\n"; if (mode == 1) - { // Statistiques de base + { // Basic statistics S << "******** Basic Statistics ********" << std::endl; Standard_Integer nbr = 0, nbe = 0, nbw = 0; diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_MultipleBinder.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_MultipleBinder.cxx index 5f3977131e..c474dfb4f9 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_MultipleBinder.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_MultipleBinder.cxx @@ -19,10 +19,10 @@ IMPLEMENT_STANDARD_RTTIEXT(Transfer_MultipleBinder, Transfer_Binder) -// Resultat Multiple -// Possibilite de definir un Resultat Multiple : plusieurs objets resultant -// d un Transfert, sans pouvoir les distinguer -// N.B. : Pour l heure, tous Transients (pourra evoluer) +// Multiple Result +// Possibility to define a Multiple Result : several objects resulting +// from a Transfer, without being able to distinguish them +// N.B. : For now, all Transients (may evolve) Transfer_MultipleBinder::Transfer_MultipleBinder() {} Standard_Boolean Transfer_MultipleBinder::IsMultiple() const @@ -42,7 +42,7 @@ Standard_CString Transfer_MultipleBinder::ResultTypeName() const return "(list)"; } -// .... Gestion du Resultat Multiple .... +// .... Multiple Result Management .... void Transfer_MultipleBinder::AddResult(const Handle(Standard_Transient)& res) { diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForFinder_0.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForFinder_0.cxx index a5c6ec769f..89b0ea0047 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForFinder_0.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForFinder_0.cxx @@ -482,7 +482,7 @@ void Transfer_ProcessForFinder::Mend(const Handle(Transfer_Finder)& start, { Handle(Transfer_Binder) binder = FindAndMask(start); if (binder.IsNull()) - return; // rien a faire ... + return; // nothing to do ... Handle(Interface_Check) ach = binder->CCheck(); ach->Mend(pref); } @@ -510,7 +510,7 @@ void Transfer_ProcessForFinder::BindTransient(const Handle(Transfer_Finder)& Handle(Transfer_Binder) former = Find(start); Handle(Transfer_SimpleBinderOfTransient) binder = Handle(Transfer_SimpleBinderOfTransient)::DownCast(former); - // Binding sur place ? + // Binding in place? if (!binder.IsNull()) { if (binder->Status() == Transfer_StatusVoid) diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForTransient_0.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForTransient_0.cxx index 56ab9d2827..552f890fbe 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForTransient_0.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_ProcessForTransient_0.cxx @@ -871,7 +871,7 @@ Handle(Transfer_Binder) Transfer_ProcessForTransient::Transferring( { if (!former.IsNull()) former->SetStatusExec(Transfer_StatusDone); //+ - return Handle(Transfer_Binder)(); // Binder Null ... que faire d autre ? + return Handle(Transfer_Binder)(); // Null Binder ... what else to do? } if (therootl >= thelevel) diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_ResultFromModel.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_ResultFromModel.cxx index 2502266769..3d6f9b1342 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_ResultFromModel.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_ResultFromModel.cxx @@ -64,8 +64,8 @@ Standard_Boolean Transfer_ResultFromModel::Fill(const Handle(Transfer_TransientP themain->SetStart(ent); themain->SetBinder(binder); themain->Fill(TP); - // Substitution de resultat pour la Shape (-> HShape) : pas ici, on est - // dans le pk Transfer qui est general et ne sait pas ce qu est une Shape ... + // Result substitution for the Shape (-> HShape): not here, we are + // in the Transfer package which is general and doesn't know what a Shape is ... if (!TP->Model().IsNull()) themodel = TP->Model(); if (themodel.IsNull()) diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_SimpleBinderOfTransient.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_SimpleBinderOfTransient.cxx index 12080f68b0..e5278dada4 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_SimpleBinderOfTransient.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_SimpleBinderOfTransient.cxx @@ -18,7 +18,7 @@ IMPLEMENT_STANDARD_RTTIEXT(Transfer_SimpleBinderOfTransient, Transfer_Binder) -// "Handle(Standard_Transient)" : la classe de base pour le Resultat +// "Handle(Standard_Transient)": the base class for the Result Transfer_SimpleBinderOfTransient::Transfer_SimpleBinderOfTransient() {} // Standard_Boolean Transfer_SimpleBinderOfTransient::IsMultiple() const diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferDispatch.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferDispatch.cxx index 3918df8afb..9416c85c93 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferDispatch.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferDispatch.cxx @@ -59,7 +59,7 @@ Standard_Boolean Transfer_TransferDispatch::Copy(const Handle(Standard_Transient return Interface_CopyTool::Copy(entfrom, entto, mapped, errstat); if (!result->IsKind(STANDARD_TYPE(Transfer_SimpleBinderOfTransient))) - return Standard_False; // Produit qq chose, mais quoi ? + return Standard_False; // Produces something, but what ? entto = GetCasted(Transfer_SimpleBinderOfTransient, result)->Result(); return Standard_True; } diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferInput.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferInput.cxx index 8609faa7cc..83a8393848 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferInput.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferInput.cxx @@ -28,7 +28,7 @@ Transfer_TransferInput::Transfer_TransferInput() {} -// Resultats : Pour le Modele ... +// Results : For the Model ... Interface_EntityIterator Transfer_TransferInput::Entities(Transfer_TransferIterator& list) const { @@ -41,7 +41,7 @@ Interface_EntityIterator Transfer_TransferInput::Entities(Transfer_TransferItera if (binder->IsKind(STANDARD_TYPE(Transfer_VoidBinder))) continue; - // Vrai resultat : doit etre transient (simple ou liste) + // True result : must be transient (simple or list) DeclareAndCast(Transfer_SimpleBinderOfTransient, transb, binder); DeclareAndCast(Transfer_MultipleBinder, multi, binder); if (!transb.IsNull()) diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferIterator.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferIterator.cxx index fef88f4db6..a4f26c02eb 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferIterator.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferIterator.cxx @@ -17,7 +17,7 @@ #include <Transfer_SimpleBinderOfTransient.hxx> #include <Transfer_TransferIterator.hxx> -static Handle(Standard_Transient) nultrans; // pour retour const&(Null) +static Handle(Standard_Transient) nultrans; // for const&(Null) return Transfer_TransferIterator::Transfer_TransferIterator() { @@ -150,7 +150,7 @@ const Handle(Transfer_Binder)& Transfer_TransferIterator::Value() const return theitems->Value(thecurr); } -// .... Acces aux Donnees du Binder Courant .... +// .... Access to Current Binder Data .... Standard_Boolean Transfer_TransferIterator::HasResult() const { @@ -172,7 +172,7 @@ Handle(Standard_Type) Transfer_TransferIterator::ResultType() const Handle(Transfer_Binder) atr = Value(); if (!atr->IsMultiple()) btype = atr->ResultType(); - // ResultType de Binder prend en compte le Type Dynamique pour les Handle + // Binder's ResultType takes into account the Dynamic Type for Handles return btype; } diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferOutput.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferOutput.cxx index 1b02138527..a10b0a238c 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_TransferOutput.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_TransferOutput.cxx @@ -84,9 +84,9 @@ void Transfer_TransferOutput::Transfer(const Handle(Standard_Transient)& obj, */ } -// Resultats : -// Pour transferer tout simplement toutes les racines d'un modele d'interface -// Chacune est notee "Root" dans le Process final +// Results : +// To transfer quite simply all roots of an interface model +// Each one is noted "Root" in the final Process void Transfer_TransferOutput::TransferRoots(const Message_ProgressRange& theProgress) { diff --git a/src/DataExchange/TKXSBase/Transfer/Transfer_TransientProcess.cxx b/src/DataExchange/TKXSBase/Transfer/Transfer_TransientProcess.cxx index e09a60b72f..aa4ac9f5b7 100644 --- a/src/DataExchange/TKXSBase/Transfer/Transfer_TransientProcess.cxx +++ b/src/DataExchange/TKXSBase/Transfer/Transfer_TransientProcess.cxx @@ -187,7 +187,7 @@ void Transfer_TransientProcess::PrintStats(const Standard_Integer /*mode*/, Standard_OStream& S) const { S << "\n*******************************************************************\n"; - // if (mode == 1) { // Statistiques de base + // if (mode == 1) { // Basic statistics S << "******** Basic Statistics ********" << std::endl; Handle(Interface_InterfaceModel) model = Model(); diff --git a/src/DataExchange/TKXSBase/TransferBRep/TransferBRep.cxx b/src/DataExchange/TKXSBase/TransferBRep/TransferBRep.cxx index 4ec2c2a3be..37f02cbb5b 100644 --- a/src/DataExchange/TKXSBase/TransferBRep/TransferBRep.cxx +++ b/src/DataExchange/TKXSBase/TransferBRep/TransferBRep.cxx @@ -159,7 +159,7 @@ TopAbs_Orientation TransferBRep::ShapeState(const Handle(Transfer_FinderProcess) if (sm.IsNull()) return TopAbs_EXTERNAL; const TopoDS_Shape& mapped = sm->Value(); - // l egalite est assumee, on ne teste que l orientation + // equality is assumed, we only test the orientation if (mapped.Orientation() != shape.Orientation()) return TopAbs_REVERSED; return TopAbs_FORWARD; diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_ConnectedShapes.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_ConnectedShapes.cxx index 1d796456d2..3b146fe84e 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_ConnectedShapes.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_ConnectedShapes.cxx @@ -95,7 +95,7 @@ Handle(TColStd_HSequenceOfTransient) XSControl_ConnectedShapes::AdjacentEntities if (vtx.Contains(avtx)) { li->Append(TP->Mapped(i)); - break; // break de ce for interieur, entite suivante + break; // break from this inner for, next entity } } } diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_Controller.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_Controller.cxx index 856138860b..2b6b908e0e 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_Controller.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_Controller.cxx @@ -144,7 +144,7 @@ Handle(Transfer_ActorOfFinderProcess) XSControl_Controller::ActorWrite() const } // ########################### -// Help du Transfer : controle de valeur + help +// Transfer Help : value control + help //================================================================================================= @@ -220,8 +220,8 @@ Standard_CString XSControl_Controller::ModeWriteHelp(const Standard_Integer mode } // ########################### -// Transfer : on fait ce qu il faut par defaut (avec ActorWrite) -// peut etre redefini ... +// Transfer : we do what is needed by default (with ActorWrite) +// can be redefined ... //================================================================================================= @@ -325,9 +325,9 @@ IFSelect_ReturnStatus XSControl_Controller::TransferWriteShape( } // ########################### -// Cutomisation ! On enregistre des Items pour une WorkSession -// (annule et remplace) -// Ensuite, on les remet en place a la demande +// Customization ! We register Items for a WorkSession +// (cancels and replaces) +// Then, we put them back in place on demand //================================================================================================= diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_FuncShape.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_FuncShape.cxx index 7fd3b0afd2..b647e79d51 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_FuncShape.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_FuncShape.cxx @@ -70,8 +70,8 @@ static IFSelect_ReturnStatus XSControl_tpdraw(const Handle(IFSelect_SessionPilot { sout << "Donner [mode facultatif : item ou root] , NUMERO , nom DRAW facultatif" << std::endl; sout << " mode si present : item ou root, sinon n0 d entite modele" << std::endl; - sout << " NUMERO entier : d entite, d item transfert ou de root transfert\n" - << " ou * pour dire tous" << std::endl; + sout << " INTEGER NUMBER : of entity, of transfer item or of transfer root\n" + << " or * to say all" << std::endl; return IFSelect_RetError; } Standard_Integer mode = 0, num = 0; @@ -113,30 +113,30 @@ static IFSelect_ReturnStatus XSControl_tpdraw(const Handle(IFSelect_SessionPilot { if (mode == 0) { - sout << "Pas de modele, preciser n0 d item de transfert" << std::endl; + sout << "No model, specify n0 of transfer item" << std::endl; return IFSelect_RetError; } } if (mode == 0) { - sout << "Entite de modele"; + sout << "Model entity"; max = model->NbEntities(); } if (mode == 1) { - sout << "Item de transfert"; + sout << "Transfer item"; max = TP->NbMapped(); } if (mode == 2) { - sout << "Racine de transfert"; + sout << "Transfer root"; max = TP->NbRoots(); } if (tout) { n1 = 1; n2 = max; - sout << ", listage de 1 a " << max << std::endl; + sout << ", listing from 1 to " << max << std::endl; } else if (num <= 0 || num > max) { @@ -146,7 +146,7 @@ static IFSelect_ReturnStatus XSControl_tpdraw(const Handle(IFSelect_SessionPilot else { n1 = n2 = num; - nbvar = -1; // nbvar : 1ere shape simple = pas de n0 + nbvar = -1; // nbvar : 1st simple shape = no n0 sout << ", n0 " << num << std::endl; } @@ -190,7 +190,7 @@ static IFSelect_ReturnStatus XSControl_tpdraw(const Handle(IFSelect_SessionPilot if (!binder->HasResult()) { if (!tout) - sout << "Entite n0 " << num << " : pas de resultat" << std::endl; + sout << "Entity n0 " << num << " : no result" << std::endl; continue; } sh = TransferBRep::ShapeResult(binder); @@ -274,7 +274,7 @@ static IFSelect_ReturnStatus XSControl_tpdraw(const Handle(IFSelect_SessionPilot Handle(Standard_Transient) resu = trb->Result(); if (resu.IsNull()) { - sout << "Entite n0 " << num << " : pas de resultat" << std::endl; + sout << "Entity n0 " << num << " : no result" << std::endl; continue; } DeclareAndCast(Geom_Geometry, geom, resu); @@ -410,7 +410,7 @@ static IFSelect_ReturnStatus XSControl_traccess(const Handle(IFSelect_SessionPil if (num == 0 || cascomp) { - TopoDS_Compound C; // pour cas compound + TopoDS_Compound C; // for compound case BRep_Builder B; B.MakeCompound(C); @@ -452,7 +452,7 @@ static IFSelect_ReturnStatus XSControl_traccess(const Handle(IFSelect_SessionPil TopoDS_Shape sh = TR->ShapeResult(mdl->Value(num)); if (sh.IsNull()) { - sout << " Pas de resultat pour " << arg1 << std::endl; + sout << " No result for " << arg1 << std::endl; return IFSelect_RetError; } if (argc > 2) @@ -753,8 +753,8 @@ static IFSelect_ReturnStatus XSControl_trconnexentities(const Handle(IFSelect_Se static IFSelect_ReturnStatus XSControl_trimport(const Handle(IFSelect_SessionPilot)& pilot) { - // FileName ou . (pour courant) VarName GiveList (obligatoire) - // GiveList : * pour xst-transferrable-roots + // FileName or . (for current) VarName GiveList (mandatory) + // GiveList : * for xst-transferrable-roots Handle(XSControl_WorkSession) WS = XSControl::Session(pilot); Standard_Integer argc = pilot->NbWords(); @@ -899,7 +899,7 @@ static IFSelect_ReturnStatus XSControl_twrite(const Handle(IFSelect_SessionPilot Handle(XSControl_TransferWriter) TW = XSControl::Session(pilot)->TransferWriter(); if (argc < 2) { - sout << " donner nom de shape draw" << std::endl; + sout << " give draw shape name" << std::endl; return IFSelect_RetError; } sout << "Attention, on alimente le modele courant ..." << std::endl; @@ -911,7 +911,7 @@ static IFSelect_ReturnStatus XSControl_twrite(const Handle(IFSelect_SessionPilot TopoDS_Shape Shape = XSControl::Vars(pilot)->GetShape(ai); if (Shape.IsNull()) { - sout << "pas un nom de shape draw:" << arg1 << std::endl; + sout << "not a draw shape name:" << arg1 << std::endl; continue; } sout << "Pour Shape : " << ai; @@ -1011,7 +1011,7 @@ Standard_Integer XSControl_FuncShape::MoreShapes(const Handle(XSControl_WorkSess // name = "*" -> tous les transferts RACINES du TP // name = "**" -> tous les transferts du TP : VRAIMENT TOUS // name = "." -> reperage graphique (not yet impl) - // name = nom(n1-n2) avec n1,n2 entiers : les variables de nom nomn1 a nomn2 + // name = nom(n1-n2) with n1,n2 integers : the variables of name nomn1 to nomn2 Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (list.IsNull()) list = new TopTools_HSequenceOfShape(); @@ -1044,7 +1044,7 @@ Standard_Integer XSControl_FuncShape::MoreShapes(const Handle(XSControl_WorkSess n2 = atoi(&name[moins + 1]); n1 = atoi(&name[paro + 1]); if (n1 < 0) - n1 += n2; // sinon on a n1-n2 + n1 += n2; // otherwise we have n1-n2 } // liste if (n1 <= n2 && n1 > 0) @@ -1110,7 +1110,7 @@ Standard_Boolean XSControl_FuncShape::FileAndVar(const Handle(XSControl_WorkSess Standard_Integer nomdeb, nomfin; nomdeb = resfile.SearchFromEnd("/"); if (nomdeb <= 0) - nomdeb = resfile.SearchFromEnd("\\"); // pour NT + nomdeb = resfile.SearchFromEnd("\\"); // for NT if (nomdeb < 0) nomdeb = 0; nomfin = resfile.SearchFromEnd("."); diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_Functions.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_Functions.cxx index 8a2eee7242..51aad89837 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_Functions.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_Functions.cxx @@ -149,10 +149,10 @@ static IFSelect_ReturnStatus XSControl_tpstat(const Handle(IFSelect_SessionPilot Standard_Integer mod2 = 0; // g : general c : check (compte) C (liste) f : fails(compte) F (liste) // resultats racines : n : n0s entites s : status b : binders - // t : compte par type r : compte par resultat l : liste(type-resultat) - // *n *s *b *t *r *l : idem sur tout - // ?n etc.. : idem sur resultats anormaux - // ? tout court pour help + // t : count by type r : count by result l : list(type-result) + // *n *s *b *t *r *l : same on everything + // ?n etc.. : same on abnormal results + // ? short for help if (argc > 1) { @@ -345,10 +345,10 @@ static IFSelect_ReturnStatus XSControl_trecord(const Handle(IFSelect_SessionPilo const Handle(Transfer_TransientProcess)& TP = XSControl::Session(pilot)->TransferReader()->TransientProcess(); // **** trecord : TransferReader **** - Standard_Boolean tous = (argc == 1); - Standard_Integer num = -1; - const Handle(Interface_InterfaceModel)& mdl = XSControl::Session(pilot)->Model(); - const Handle(XSControl_TransferReader)& TR = XSControl::Session(pilot)->TransferReader(); + Standard_Boolean all = (argc == 1); + Standard_Integer num = -1; + const Handle(Interface_InterfaceModel)& mdl = XSControl::Session(pilot)->Model(); + const Handle(XSControl_TransferReader)& TR = XSControl::Session(pilot)->TransferReader(); Handle(Standard_Transient) ent; Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (mdl.IsNull() || TR.IsNull() || TP.IsNull()) @@ -356,10 +356,10 @@ static IFSelect_ReturnStatus XSControl_trecord(const Handle(IFSelect_SessionPilo sout << " init not done" << std::endl; return IFSelect_RetError; } - if (!tous) + if (!all) num = atoi(arg1); - // Enregistrer les racines - if (tous) + // Record the roots + if (all) { Standard_Integer nb = TP->NbRoots(); sout << " Recording " << nb << " Roots" << std::endl; @@ -587,7 +587,7 @@ static IFSelect_ReturnStatus XSControl_twstat(const Handle(IFSelect_SessionPilot const Handle(Transfer_FinderProcess)& FP = XSControl::Session(pilot)->TransferWriter()->FinderProcess(); // **** twstat **** - // Pour Write + // For Write Message_Messenger::StreamBuffer sout = Message::SendInfo(); if (!FP.IsNull()) { diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_Reader.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_Reader.cxx index bccb1f5e7b..3c015e0abc 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_Reader.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_Reader.cxx @@ -80,7 +80,7 @@ void XSControl_Reader::SetWS(const Handle(XSControl_WorkSession)& WS, therootsta = Standard_False; theroots.Clear(); thesession = WS; - // Il doit y avoir un Controller ... Sinon onverra plus tard (apres SetNorm) + // There must be a Controller ... Otherwise we'll see later (after SetNorm) if (thesession->NormAdaptor().IsNull()) return; Handle(Interface_InterfaceModel) model = thesession->Model(); diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_SignTransferStatus.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_SignTransferStatus.cxx index d8a31fe395..8e0050e670 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_SignTransferStatus.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_SignTransferStatus.cxx @@ -29,7 +29,7 @@ static TCollection_AsciiString& themes() return tm; } -// si resultat avec type: a exploiter tout de suite ! +// if result with type: to be exploited immediately! XSControl_SignTransferStatus::XSControl_SignTransferStatus() : IFSelect_Signature("Transfer Status") diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_TransferReader.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_TransferReader.cxx index 572662d525..2bbd91c9b8 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_TransferReader.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_TransferReader.cxx @@ -158,7 +158,7 @@ Standard_Boolean XSControl_TransferReader::RecordResult(const Handle(Standard_Tr Handle(Transfer_ResultFromModel) res = new Transfer_ResultFromModel; res->Fill(myTP, ent); - // Cas du resultat Shape : pour resultat principal, faire HShape ... + // Case of Shape result : for main result, make HShape ... Handle(Transfer_Binder) binder = res->MainResult()->Binder(); DeclareAndCast(TransferBRep_ShapeBinder, shb, binder); if (!shb.IsNull()) @@ -265,7 +265,7 @@ Standard_Boolean XSControl_TransferReader::IsMarked(const Handle(Standard_Transi return Standard_True; } -// ######### ACCES UN PEU PLUS FIN ######### +// ######### SLIGHTLY MORE REFINED ACCESS ######### //================================================================================================= @@ -354,7 +354,7 @@ TopoDS_Shape XSControl_TransferReader::ShapeResult(const Handle(Standard_Transie XSControl_Utils xu; TopoDS_Shape sh = xu.BinderShape(mres->Binder()); - // Ouh la vilaine verrue + // Ooh the ugly wart Standard_Real tolang = Interface_Static::RVal("read.encoderegularity.angle"); if (tolang <= 0 || sh.IsNull()) return sh; @@ -386,9 +386,9 @@ Standard_Boolean XSControl_TransferReader::ClearResult(const Handle(Standard_Tra return Standard_True; } -// <<<< >>>> ATTENTION, pas terrible : mieux vaudrait -// faire une map inverse et la consulter -// ou muscler ResultFromModel ... +// <<<< >>>> CAUTION, not great : it would be better +// to make an inverse map and consult it +// or beef up ResultFromModel ... //================================================================================================= @@ -397,7 +397,7 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromResult( const Standard_Integer mode) const { Handle(Standard_Transient) nulh; - // cas de la shape + // case of the shape XSControl_Utils xu; TopoDS_Shape sh = xu.BinderShape(res); if (!sh.IsNull()) @@ -409,7 +409,7 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromResult( if (mode == 0 || mode == 1) { - // on regarde dans le TransientProcess (Roots ou tous Mappeds) + // we look in the TransientProcess (Roots or all Mappeds) if (!myTP.IsNull()) { nb = (mode == 0 ? myTP->NbRoots() : myTP->NbMapped()); @@ -437,7 +437,7 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromResult( return nulh; // Null } - // Recherche dans myResults (racines) + // Search in myResults (roots) // 2 : Main only 3 : Main + one sub; 4 : all if (mode >= 2) { @@ -460,11 +460,11 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromResult( } } - // autres cas non encore implementes + // other cases not yet implemented return nulh; } -// <<<< >>>> ATTENTION, encore moins bien que le precedent +// <<<< >>>> CAUTION, even worse than the previous one //================================================================================================= @@ -480,7 +480,7 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromShapeResult( XSControl_Utils xu; if (mode == 0 || mode == 1 || mode == -1) { - // on regarde dans le TransientProcess + // we look in the TransientProcess if (!myTP.IsNull()) { nb = (mode == 0 ? myTP->NbRoots() : myTP->NbMapped()); @@ -495,7 +495,7 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromShapeResult( { if (sh == res) return ent; - // priorites moindre : Same (tjrs) ou Partner (mode < 0) + // lesser priorities : Same (always) or Partner (mode < 0) if (sh.IsSame(res)) samesh = ent; if (mode == -1 && sh.IsPartner(res)) @@ -503,15 +503,15 @@ Handle(Standard_Transient) XSControl_TransferReader::EntityFromShapeResult( } } } - // Ici, pas trouve de vraie egalite. Priorites moindres : Same puis Partner + // Here, no true equality found. Lesser priorities: Same then Partner if (!samesh.IsNull()) return samesh; if (!partner.IsNull()) - return partner; // calcule si mode = -1 + return partner; // calculated if mode = -1 return nulh; } - // Recherche dans myResults (racines) + // Search in myResults (roots) // 2 : Main only 3 : Main + one sub; 4 : all if (mode >= 2) { @@ -550,19 +550,19 @@ Handle(TColStd_HSequenceOfTransient) XSControl_TransferReader::EntitiesFromShape return lt; TopTools_MapOfShape shapes; - // On convertit res en une map, pour test de presence rapide + // We convert res to a map, for rapid presence test Standard_Integer i, j, nb = res->Length(); if (nb == 0) return lt; for (i = 1; i <= nb; i++) shapes.Add(res->Value(i)); - // A present, recherche et enregistrement + // Now, search and registration XSControl_Utils xu; if (mode == 0 || mode == 1) { - // on regarde dans le TransientProcess + // we look in the TransientProcess if (!myTP.IsNull()) { nb = (mode == 0 ? myTP->NbRoots() : myTP->NbMapped()); @@ -581,7 +581,7 @@ Handle(TColStd_HSequenceOfTransient) XSControl_TransferReader::EntitiesFromShape } } - // Recherche dans myResults (racines) + // Search in myResults (roots) // 2 : Main only 3 : Main + one sub; 4 : all if (mode >= 2) { @@ -619,7 +619,7 @@ Interface_CheckIterator XSControl_TransferReader::CheckList(const Handle(Standar Interface_CheckIterator chl; if (myModel.IsNull() || ent.IsNull()) return chl; - // Check-List COMPLETE ... tout le Modele + // Check-List COMPLETE ... the entire Model if (ent == myModel) { Standard_Integer i, nb = myModel->NbEntities(); @@ -633,7 +633,7 @@ Interface_CheckIterator XSControl_TransferReader::CheckList(const Handle(Standar } } } - // Check-List sur une LISTE ... + // Check-List on a LIST ... else if (ent->IsKind(STANDARD_TYPE(TColStd_HSequenceOfTransient))) { DeclareAndCast(TColStd_HSequenceOfTransient, list, ent); @@ -649,7 +649,7 @@ Interface_CheckIterator XSControl_TransferReader::CheckList(const Handle(Standar } } - // sinon, Check-List sur une entite : Last ou FinalResult + // otherwise, Check-List on an entity: Last or FinalResult else if (level < 0) { if (myTP.IsNull()) @@ -751,9 +751,9 @@ Standard_Boolean XSControl_TransferReader::BeginTransfer() myTP = new Transfer_TransientProcess(myModel->NbEntities()); Handle(Transfer_ActorOfTransientProcess) actor; - myTP->SetActor(actor); // -> RAZ + myTP->SetActor(actor); // -> Reset actor = Actor(); - myTP->SetActor(actor); // Set proprement dit + myTP->SetActor(actor); // Set properly myTP->SetErrorHandle(Standard_True); NCollection_DataMap<TCollection_AsciiString, Handle(Standard_Transient)>& aTPContext = myTP->Context(); @@ -794,7 +794,7 @@ Standard_Integer XSControl_TransferReader::TransferOne(const Handle(Standard_Tra else myTP->SetGraph(myGraph); - // pour le log-file + // for the log-file if (level > 1) { Standard_Integer num = myModel->Number(ent); @@ -812,7 +812,7 @@ Standard_Integer XSControl_TransferReader::TransferOne(const Handle(Standard_Tra sout << "\n*******************************************************************\n"; } - // seule difference entre TransferRoots et TransferOne + // only difference between TransferRoots and TransferOne Standard_Integer res = 0; const Handle(Standard_Transient)& obj = ent; TP.Transfer(obj, theProgress); @@ -820,7 +820,7 @@ Standard_Integer XSControl_TransferReader::TransferOne(const Handle(Standard_Tra return res; myTP->SetRoot(obj); - // Resultat ... + // Result ... Handle(Transfer_Binder) binder = myTP->Find(obj); if (binder.IsNull()) return res; @@ -860,7 +860,7 @@ Standard_Integer XSControl_TransferReader::TransferList( Standard_Integer i, nb = list->Length(); - // Pour le log-file + // For the log-file if (level > 0) { Message_Messenger::StreamBuffer sout = myTP->Messenger()->SendInfo(); @@ -877,7 +877,7 @@ Standard_Integer XSControl_TransferReader::TransferList( sout << "\n*******************************************************************\n"; } - // seule difference entre TransferRoots et TransferOne + // only difference between TransferRoots and TransferOne Standard_Integer res = 0; nb = list->Length(); Handle(Standard_Transient) obj; @@ -888,7 +888,7 @@ Standard_Integer XSControl_TransferReader::TransferList( TP.Transfer(obj, aPS.Next()); myTP->SetRoot(obj); - // Resultat ... + // Result ... Handle(Transfer_Binder) binder = myTP->Find(obj); if (binder.IsNull()) continue; @@ -902,7 +902,7 @@ Standard_Integer XSControl_TransferReader::TransferList( return res; } -// <<<< >>>> passage Graph : judicieux ? +// <<<< >>>> Graph passing: judicious? //================================================================================================= @@ -921,7 +921,7 @@ Standard_Integer XSControl_TransferReader::TransferRoots(const Interface_Graph& else myTP->SetGraph(myGraph); - // Pour le log-file + // For the log-file if (level > 0) { Interface_EntityIterator roots = G.RootEntities(); @@ -943,7 +943,7 @@ Standard_Integer XSControl_TransferReader::TransferRoots(const Interface_Graph& if (theProgress.UserBreak()) return -1; - // Les entites transferees sont notees "asmain" + // The transferred entities are noted as "asmain" Standard_Integer i, n = myTP->NbMapped(); for (i = 1; i <= n; i++) { @@ -956,7 +956,7 @@ Standard_Integer XSControl_TransferReader::TransferRoots(const Interface_Graph& RecordResult(ent); } - // Resultat ... on note soigneuseument les Shapes + // Result ... we carefully note the Shapes myShapeResult = TransferBRep::Shapes(myTP, Standard_True); // ???? Et ici, il faut alimenter Imagine ... return myShapeResult->Length(); @@ -985,7 +985,7 @@ void XSControl_TransferReader::PrintStats(Standard_OStream& sout, const Standard_Integer what, const Standard_Integer mode) const { - // A ameliorer ... ! + // To be improved ... ! sout << "\n*******************************************************************\n"; sout << "****** Statistics on Transfer (Read) ******" << std::endl; sout << "\n*******************************************************************\n"; @@ -999,7 +999,7 @@ void XSControl_TransferReader::PrintStats(Standard_OStream& sout, sout << "****** Data recorded on Last Transfer ******" << std::endl; PrintStatsProcess(myTP, what, mode); } - // reste what = 10 : on liste les racines des final results + // remaining what = 10: we list the roots of final results sout << "****** Final Results ******" << std::endl; if (myModel.IsNull()) { @@ -1110,9 +1110,9 @@ const Handle(TopTools_HSequenceOfShape)& XSControl_TransferReader::ShapeResultLi // **** UTILITAIRE DE STATISTIQUES GENERALES -// BinderStatus retourne une valeur : -// 0 Binder Null. 1 void 2 Warning seul 3 Fail seul -// 11 Resultat OK. 12 Resultat+Warning. 13 Resultat+Fail +// BinderStatus returns a value: +// 0 Binder Null. 1 void 2 Warning only 3 Fail only +// 11 Result OK. 12 Result+Warning. 13 Result+Fail //================================================================================================= @@ -1240,7 +1240,7 @@ void XSControl_TransferReader::PrintStatsOnList(const Handle(Transfer_TransientP sout << "****** Fail messages ******\n"; sout << "*******************************************************************\n"; - // Cas what = 1,2,3 : contenu du TP (binders) + // Case what = 1,2,3: content of TP (binders) Standard_Boolean nolist = list.IsNull(); Handle(Interface_InterfaceModel) model = TP->Model(); @@ -1259,11 +1259,11 @@ void XSControl_TransferReader::PrintStatsOnList(const Handle(Transfer_TransientP Standard_Integer i = 0, nb = itrp.Number(); if (!nolist) itrp.Filter(list); - Standard_Integer nl = itrp.Number(); // apres filtrage + Standard_Integer nl = itrp.Number(); // after filtering Handle(IFSelect_SignatureList) counter; if (mode > 2) counter = new IFSelect_SignatureList(mode == 6); - Standard_Boolean notrec = (!nolist && mode > 2); // noter les "no record" + Standard_Boolean notrec = (!nolist && mode > 2); // note the "no record" IFSelect_PrintCount pcm = IFSelect_CountByItem; if (mode == 6) pcm = IFSelect_ListByItem; @@ -1299,8 +1299,8 @@ void XSControl_TransferReader::PrintStatsOnList(const Handle(Transfer_TransientP if (mode != 3) { stat = BinderStatus(binder, mess); - // 0 Binder Null. 1 void 2 Warning seul 3 Fail seul - // 11 Resultat OK. 12 Resultat+Warning. 13 Resultat+Fail + // 0 Binder Null. 1 void 2 Warning only 3 Fail only + // 11 Result OK. 12 Result+Warning. 13 Result+Fail if (stat == 2) nbw++; if (stat == 3) @@ -1364,7 +1364,7 @@ void XSControl_TransferReader::PrintStatsOnList(const Handle(Transfer_TransientP } } - // Fin de l iteration + // End of iteration } if (!counter.IsNull()) counter->PrintList(sout, model, pcm); @@ -1393,7 +1393,7 @@ void XSControl_TransferReader::PrintStatsOnList(const Handle(Transfer_TransientP return; } - // Cas what = 4,5 : check-list + // Case what = 4,5: check-list if (what == 4 || what == 5) { diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_Utils.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_Utils.cxx index ab603249ad..5e63ef1764 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_Utils.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_Utils.cxx @@ -47,7 +47,7 @@ static const Standard_ExtString voidext = {0}; XSControl_Utils::XSControl_Utils() {} // ######################################################### -// ####### Fonctions de TRACE ####### +// ####### TRACE Functions ####### void XSControl_Utils::TraceLine(const Standard_CString line) const { @@ -102,7 +102,7 @@ void XSControl_Utils::TraceLines(const Handle(Standard_Transient)& lines) const } // ######################################################### -// ####### TRANSIENT : Quelques acces de base ####### +// ####### TRANSIENT : Some basic access ####### Standard_Boolean XSControl_Utils::IsKind(const Handle(Standard_Transient)& item, const Handle(Standard_Type)& what) const @@ -133,7 +133,7 @@ Standard_CString XSControl_Utils::TypeName(const Handle(Standard_Transient)& ite return tn; } -// ####### TRANSIENT : Fonctions de liste ####### +// ####### TRANSIENT : List functions ####### Handle(Standard_Transient) XSControl_Utils::TraValue(const Handle(Standard_Transient)& seqval, const Standard_Integer num) const @@ -200,7 +200,7 @@ void XSControl_Utils::DateValues(const Standard_CString text, } // ########################################################## -// ####### STRING : Ascii de base ####### +// ####### STRING : Basic Ascii ####### Standard_CString XSControl_Utils::ToCString(const Handle(TCollection_HAsciiString)& strval) const { @@ -225,7 +225,7 @@ TCollection_AsciiString XSControl_Utils::ToAString(const Standard_CString strcon return TCollection_AsciiString(strcon); } -// ####### STRING : Extended de base ####### +// ####### STRING : Basic Extended ####### Standard_ExtString XSControl_Utils::ToEString( const Handle(TCollection_HExtendedString)& strval) const @@ -388,7 +388,7 @@ void XSControl_Utils::AppendEStr(const Handle(TColStd_HSequenceOfHExtendedString } // ########################################################## -// ####### SHAPES : Acces de base ####### +// ####### SHAPES : Basic access ####### TopoDS_Shape XSControl_Utils::CompoundFromSeq(const Handle(TopTools_HSequenceOfShape)& seqval) const { @@ -420,7 +420,7 @@ TopAbs_ShapeEnum XSControl_Utils::ShapeType(const TopoDS_Shape& shape, typ = ShapeType(sh, compound); if (res == TopAbs_SHAPE) res = typ; - // Egalite : OK; Pseudo-Egalite : EDGE/WIRE ou FACE/SHELL + // Equality: OK; Pseudo-Equality: EDGE/WIRE or FACE/SHELL else if (res == TopAbs_EDGE && typ == TopAbs_WIRE) res = typ; else if (res == TopAbs_WIRE && typ == TopAbs_EDGE) @@ -446,7 +446,7 @@ TopoDS_Shape XSControl_Utils::SortedCompound(const TopoDS_Shape& shape, TopoDS_Shape sh, sh0; Standard_Integer nb = 0; - // Compound : on le prend, soit tel quel, soit son contenu + // Compound: we take it, either as is, or its content if (typ == TopAbs_COMPOUND || typ == TopAbs_COMPSOLID) { TopoDS_Compound C; diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_WorkSession.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_WorkSession.cxx index 9436f55ab2..28ca31c754 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_WorkSession.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_WorkSession.cxx @@ -54,9 +54,9 @@ void XSControl_WorkSession::ClearData(const Standard_Integer mode) if (mode >= 1 && mode <= 4) IFSelect_WorkSession::ClearData(mode); - // 5 : Transferts seuls - // 6 : Resultats forces seuls - // 7 : Management, y compris tous transferts (forces/calcules), views + // 5 : Transfers only + // 6 : Forced results only + // 7 : Management, including all transfers (forced/calculated), views if (mode == 5 || mode == 7) { @@ -75,8 +75,8 @@ Standard_Boolean XSControl_WorkSession::SelectNorm(const Standard_CString normna const Standard_Mutex::Sentry aMutexLock(WS_GLOBAL_MUTEX); // Old norm and results myTransferReader->Clear(-1); - // ???? En toute rigueur, menage a faire dans XWS : virer les items - // ( a la limite, pourquoi pas, refaire XWS en entier) + // ???? Strictly speaking, cleanup to do in XWS: remove the items + // ( at the limit, why not, redo XWS entirely) Handle(XSControl_Controller) newadapt = XSControl_Controller::Recorded(normname); if (newadapt.IsNull()) @@ -119,7 +119,7 @@ Standard_CString XSControl_WorkSession::SelectedNorm(const Standard_Boolean rsc) } // ########################################## -// ############ Contexte de Transfert ###### +// ############ Transfer Context ###### // ########################################## //================================================================================================= @@ -193,7 +193,7 @@ Standard_Boolean XSControl_WorkSession::PrintTransferStatus(const Standard_Integ FP->StartTrace(binder, finder, 0, 0); // pb sout/S if (!ent.IsNull()) { - S << " ** Resultat Transient, type " << ent->DynamicType()->Name(); + S << " ** Transient Result, type " << ent->DynamicType()->Name(); const Handle(Interface_InterfaceModel)& model = Model(); if (!model.IsNull()) { @@ -251,7 +251,7 @@ Standard_Boolean XSControl_WorkSession::PrintTransferStatus(const Standard_Integ TP->StartTrace(binder, ent, 0, 0); } - // *** CHECK (commun READ+WRITE) *** + // *** CHECK (common READ+WRITE) *** if (!binder.IsNull()) { const Handle(Interface_Check) ch = binder->Check(); @@ -283,7 +283,7 @@ void XSControl_WorkSession::InitTransferReader(const Standard_Integer mode) else SetTransferReader(myTransferReader); - // mode = 0 fait par SetTransferReader suite a Nullify + // mode = 0 done by SetTransferReader following Nullify if (mode == 1) { if (!myTransferReader.IsNull()) @@ -355,14 +355,14 @@ Standard_Boolean XSControl_WorkSession::SetMapReader(const Handle(Transfer_Trans TP->SetGraph(HGraph()); if (TP->Model() != Model()) return Standard_False; - // TR ne doit pas bouger, c est un "crochet" pour signatures, selections ... - // En revanche, mieux vaut le RAZ + // TR must not move, it's a "hook" for signatures, selections ... + // On the other hand, better to reset it // Handle(XSControl_TransferReader) TR = new XSControl_TransferReader; Handle(XSControl_TransferReader) TR = myTransferReader; TR->Clear(-1); - SetTransferReader(TR); // avec le meme mais le reinitialise - TR->SetTransientProcess(TP); // et prend le nouveau TP + SetTransferReader(TR); // with the same but reinitializes it + TR->SetTransientProcess(TP); // and takes the new TP return Standard_True; } @@ -466,7 +466,7 @@ IFSelect_ReturnStatus XSControl_WorkSession::TransferWriteShape( status = myTransferWriter->TransferWriteShape(model, shape, theProgress); if (theProgress.UserBreak()) return IFSelect_RetStop; - // qui s occupe de tout, try/catch inclus + // which takes care of everything, try/catch included // skl insert param compgraph for XDE writing 10.12.2003 if (compgraph) diff --git a/src/DataExchange/TKXSBase/XSControl/XSControl_Writer.cxx b/src/DataExchange/TKXSBase/XSControl/XSControl_Writer.cxx index 1c0ea46059..631715c297 100644 --- a/src/DataExchange/TKXSBase/XSControl/XSControl_Writer.cxx +++ b/src/DataExchange/TKXSBase/XSControl/XSControl_Writer.cxx @@ -48,7 +48,7 @@ void XSControl_Writer::SetWS(const Handle(XSControl_WorkSession)& WS, const Standard_Boolean scratch) { thesession = WS; - // Un controller doit etre defini ... + // A controller must be defined ... thesession->InitTransferReader(0); Handle(Interface_InterfaceModel) model = Model(scratch); }