-// Copyright (C) 2007-2013 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2023 CEA, EDF, OPEN CASCADE
//
// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
{
SALOMEDS::Locker lock;
CheckLocked();
- std::vector<double> CasCadeSeq;
- for (int i = 0; i < other.length(); i++) {
- CasCadeSeq.push_back(other[i]);
- }
- dynamic_cast<SALOMEDSImpl_AttributeSequenceOfReal*>(_impl)->Assign(CasCadeSeq);
+ std::vector<double> aSeq;
+ for(int i = 0, len = other.length(); i<len; i++) aSeq.push_back(other[i]);
+ dynamic_cast<SALOMEDSImpl_AttributeSequenceOfReal*>(_impl)->Assign(aSeq);
}
SALOMEDS::DoubleSeq* SALOMEDS_AttributeSequenceOfReal_i::CorbaSequence()
SALOMEDS::Locker lock;
SALOMEDS::DoubleSeq_var CorbaSeq = new SALOMEDS::DoubleSeq;
const std::vector<double>& CasCadeSeq = dynamic_cast<SALOMEDSImpl_AttributeSequenceOfReal*>(_impl)->Array();
- int len = CasCadeSeq.size();
+ size_t len = CasCadeSeq.size();
CorbaSeq->length(len);
- for (int i = 0; i < len; i++) {
+ for (size_t i = 0; i < len; i++) {
CorbaSeq[i] = CasCadeSeq[i];
}
return CorbaSeq._retn();