Salome HOME
Merge branch 'master' of https://codev-tuleap.cea.fr/plugins/git/salome/medcoupling
[tools/medcoupling.git] / doc / user / doxygen / fakesources / MEDCouplingMemArray.C
1 // Copyright (C) 2013-2016  CEA/DEN, EDF R&D, OPEN CASCADE
2 //
3 // This library is free software; you can redistribute it and/or
4 // modify it under the terms of the GNU Lesser General Public
5 // License as published by the Free Software Foundation; either
6 // version 2.1 of the License, or (at your option) any later version.
7 //
8 // This library is distributed in the hope that it will be useful,
9 // but WITHOUT ANY WARRANTY; without even the implied warranty of
10 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
11 // Lesser General Public License for more details.
12 //
13 // You should have received a copy of the GNU Lesser General Public
14 // License along with this library; if not, write to the Free Software
15 // Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307 USA
16 //
17 // See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
18 //
19
20 // This file contains some code used only for
21 // * generation of documentation for inline methods of DataArray* classes
22 // * groupping methods into "Basic API", "Advanced" and "Others..." sections
23
24
25 namespace MEDCoupling
26 {
27 /*!
28  * Returns the attribute \a _name of \a this array.
29  * See \ref MEDCouplingArrayBasicsName "DataArrays infos" for more information.
30  *  \return std::string - array name
31  */
32 std::string DataArray::getName() const {}
33
34 /*!
35  * Returns number of components of \a this array.
36  * See \ref MEDCouplingArrayBasicsTuplesAndCompo "DataArrays infos" for more information.
37  *  \return int - number of components
38  */
39 int DataArray::getNumberOfComponents() const {}
40
41 /*!
42  * Returns number of tuples of \a this array.
43  * See \ref MEDCouplingArrayBasicsName "DataArrays infos" for more information.
44  *  \return int - number of tuples
45  */
46 int DataArray::getNumberOfTuples() const {}
47
48 /*!
49  * Returns number of elements of \a this array.
50  * See \ref MEDCouplingArrayBasicsName "DataArrays infos" for more information.
51  *  \return int - number of elements == <em> this->getNumberOfTuples() * 
52  *          this->getNumberOfComponents() </em>
53  */
54 int DataArray::getNbOfElems() const {}
55
56 /*!
57  * Throws an exception if number of elements in \a this array differs from a given one.
58  * See \ref MEDCouplingArrayBasicsName "DataArrays infos" for more information.
59  *  \param [in] nbOfElems - expected array size.
60  *  \param [in] msg - message to return within the thrown exception.
61  *  \throw if <em> this->getNbOfElems() != nbOfElems</em>.
62  */
63 void DataArray::checkNbOfElems(int nbOfElems, const char *msg) const {}
64
65 /*!
66  * Returns values of a specified tuple.
67  *  \param [in] tupleId - index of the tuple of interest.
68  *  \param [out] res - C array returning values of the \a tupleId-th tuple. The \a res
69  *         must be allocated by the caller and be of size not less than \a
70  *         this->getNumberOfComponents().
71  */
72 void DataArrayDouble::getTuple(int tupleId, double *res) const {}
73
74 /*!
75  * Returns a value of a specified element of \a this array.
76  *  \param [in] tupleId - index of the tuple of interest.
77  *  \param [in] compoId - index of the component of interest.
78  *  \return double - the value of \a compoId-th component of \a tupleId-th tuple.
79  */
80 double DataArrayDouble::getIJ(int tupleId, int compoId) const {}
81
82 /*!
83  * Returns a pointer to the first element of the raw data of \a this array.
84  *  \return double* - the pointer to the value of 0-th tuple and 0-th component.
85  */
86 double * DataArrayDouble::getPointer() {}
87
88 /*!
89  * Returns a const pointer to the first element of the raw data of \a this array.
90  *  \return const double* - the pointer to the value of 0-th tuple and 0-th component.
91  */
92 const double * DataArrayDouble::getConstPointer() const {}
93
94 /*!
95  * Assigns a given value to a specified element of \a this array.
96  *  \param [in] tupleId - index of the tuple to modify.
97  *  \param [in] compoId - index of the component to modify.
98  *  \param [in] newVal - the value to assign to the value at \a compoId-th component
99  *              of \a tupleId-th tuple. 
100  */
101 void DataArrayDouble::setIJ(int tupleId, int compoId, double newVal) {}
102
103 /*!
104  * Assigns a given value to a specified element of \a this array which is not marked
105  * as changed.
106  *  \param [in] tupleId - index of the tuple to modify.
107  *  \param [in] compoId - index of the component to modify.
108  *  \param [in] newVal - the value to assign to the value at \a compoId-th component
109  *              of \a tupleId-th tuple.
110  */
111 void DataArrayDouble::setIJSilent(int tupleId, int compoId, double newVal) {}
112
113 /*!
114  * Copies values from another array starting from a specified element of \a this.
115  *  \param [in] id - index of element to assign the value \a element0 to.
116  *  \param [in] element0 - value to assign to the \a id-th element of \a this.
117  *  \param [in] others - values to assign to elements following the \a id-th
118  *         element of \a this.
119  *  \param [in] sizeOfOthers - number of values to copy from \a others.
120  */
121 void DataArrayDouble::writeOnPlace(int id, double element0, const double *others, int sizeOfOthers) {}
122
123 /*!
124  * Does nothing because this class does not aggregate any TimeLabel instance.
125  */
126 void DataArrayDouble::updateTime() const {}
127
128 /*!
129  * Returns values of a specified tuple.
130  *  \param [in] tupleId - index of the tuple of interest.
131  *  \param [out] res - C array returning values of the \a tupleId-th tuple. The \a res
132  *         must be allocated by the caller and be of size not less than \a
133  *         this->getNumberOfComponents().
134  *  \if ENABLE_EXAMPLES
135  *  \ref py_mcdataarrayint_getTuple "Here is a Python example".
136  *  \endif
137  */
138 void DataArrayInt::getTuple(int tupleId, int *res) const {}
139
140 /*!
141  * Returns a value of a specified element of \a this array.
142  *  \param [in] tupleId - index of the tuple of interest.
143  *  \param [in] compoId - index of the component of interest.
144  *  \return int - the value of \a compoId-th component of \a tupleId-th tuple.
145  */
146 int DataArrayInt::getIJ(int tupleId, int compoId) const {}
147
148
149 /*!
150  * Assigns a given value to a specified element of \a this array.
151  *  \param [in] tupleId - index of the tuple to modify.
152  *  \param [in] compoId - index of the component to modify.
153  *  \param [in] newVal - the value to assign to the value at \a compoId-th component
154  *              of \a tupleId-th tuple.
155  * \warning As this method declares \a this array as modified, it is more optimal to use
156  *          setIJSilent() for modification of muliple values of array and to call
157  *          declareAsNew() after the modification is done.
158  */
159 void DataArrayInt::setIJ(int tupleId, int compoId, int newVal) {}
160
161
162 /*!
163  * Assigns a given value to a specified element of \a this array which is \b not marked
164  * as changed.
165  *  \param [in] tupleId - index of the tuple to modify.
166  *  \param [in] compoId - index of the component to modify.
167  *  \param [in] newVal - the value to assign to the value at \a compoId-th component
168  *              of \a tupleId-th tuple.
169  */
170 void DataArrayInt::setIJSilent(int tupleId, int compoId, int newVal) {}
171
172 /*!
173  * Returns a pointer to the first element of the raw data of \a this array.
174  *  \return int* - the pointer to the value of 0-th tuple and 0-th component.
175  */
176 int * DataArrayInt::getPointer() {}
177
178 /*!
179  * Returns a const pointer to the first element of the raw data of \a this array.
180  *  \return const int* - the pointer to the value of 0-th tuple and 0-th component.
181  */
182 const int * DataArrayInt::getConstPointer() const {}
183
184 /*!
185  * Copies values from another array starting from a given element of \a this.
186  *  \param [in] id - index of element to assign the value \a element0 to.
187  *  \param [in] element0 - value to assign to the \a id-th element of \a this.
188  *  \param [in] others - values to assign to elements following the \a id-th
189  *         element of \a this.
190  *  \param [in] sizeOfOthers - number of values to copy from \a others.
191  */
192 void DataArrayInt::writeOnPlace(int id, int element0, const int *others, int sizeOfOthers) {}
193
194 }
195
196 namespace MEDCoupling
197 {
198 //================================================================================
199 /////////////////////// DataArray GROUPPING //////////////////////////////////////
200 //================================================================================
201
202 /*! \name Basic API   */
203 ///@{
204 DataArray::setName(const char *name);
205 DataArray::copyStringInfoFrom(const DataArray& other);
206 DataArray::areInfoEquals(const DataArray& other) const;
207 DataArray::getName() const;
208 DataArray::setInfoOnComponents(const std::vector<std::string>& info);
209 DataArray::getVarOnComponent(int i) const;
210 DataArray::getUnitOnComponent(int i) const;
211 DataArray::setInfoOnComponent(int i, const char *info);
212 DataArray::getNumberOfComponents() const;
213 DataArray::getNumberOfTuples() const;
214 DataArray::getNbOfElems() const;
215 DataArray::checkNbOfElems(int nbOfElems, const char *msg) const;
216 DataArray::GetVarNameFromInfo(const std::string& info);
217 DataArray::GetUnitFromInfo(const std::string& info);
218 ///@} 
219
220 /*! \name Others... */
221 ///@{
222 DataArray::getHeapMemorySizeWithoutChildren() const;
223 DataArray::copyPartOfStringInfoFrom(const DataArray& other, const std::vector<int>& compoIds);
224 DataArray::copyPartOfStringInfoFrom2(const std::vector<int>& compoIds, const DataArray& other);
225 DataArray::areInfoEqualsIfNotWhy(const DataArray& other, std::string& reason) const;
226 DataArray::reprWithoutNameStream(std::ostream& stream) const;
227 DataArray::cppRepr(const char *varName) const;
228 DataArray::getInfoOnComponents() const;
229 DataArray::getInfoOnComponents();
230 DataArray::getVarsOnComponent() const;
231 DataArray::getUnitsOnComponent() const;
232 DataArray::getInfoOnComponent(int i) const;
233 DataArray::checkNbOfTuples(int nbOfTuples, const char *msg) const;
234 DataArray::checkNbOfComps(int nbOfCompo, const char *msg) const;
235 //DataArray::checkNbOfTuplesAndComp(const DataArray& other, const char *msg) const throw(INTERP_KERNEL::Exception);
236 //DataArray::checkNbOfTuplesAndComp(int nbOfTuples, int nbOfCompo, const char *msg) const throw(INTERP_KERNEL::Exception);
237 DataArray::GetNumberOfItemGivenBES(int begin, int end, int step, const char *msg);
238 DataArray::GetNumberOfItemGivenBESRelative(int begin, int end, int step, const char *msg);
239 DataArray::GetPosOfItemGivenBESRelativeNoThrow(int value, int begin, int end, int step);
240 DataArray::reprCppStream(const char *varName, std::ostream& stream) const;
241 DataArray::DataArray();
242 DataArray::CheckValueInRange(int ref, int value, const char *msg);
243 DataArray::CheckValueInRangeEx(int value, int start, int end, const char *msg);
244 DataArray::CheckClosingParInRange(int ref, int value, const char *msg);
245 std::string              DataArray::_name;
246 std::vector<std::string> DataArray::_info_on_compo;
247 ///@} 
248
249 //================================================================================
250 /////////////////////// DataArrayDouble GROUPPING ////////////////////////////////
251 //================================================================================
252
253 /*! \name Basic API   */
254 ///@{
255 DataArrayDouble::isAllocated() const;
256 //DataArrayDouble::setInfoAndChangeNbOfCompo(const std::vector<std::string>& info);
257 DataArrayDouble::doubleValue() const;
258 DataArrayDouble::empty() const;
259 DataArrayDouble::deepCpy() const;
260 DataArrayDouble::performCpy(bool deepCpy) const;
261 DataArrayDouble::cpyFrom(const DataArrayDouble& other);
262 DataArrayDouble::alloc(int nbOfTuple, int nbOfCompo);
263 DataArrayDouble::allocIfNecessary(int nbOfTuple, int nbOfCompo);
264 DataArrayDouble::fillWithZero();
265 DataArrayDouble::fillWithValue(double val);
266 DataArrayDouble::iota(double init=0.);
267 DataArrayDouble::isUniform(double val, double eps) const;
268 DataArrayDouble::sort(bool asc=true);
269 DataArrayDouble::reverse();
270 DataArrayDouble::checkMonotonic(bool increasing, double eps) const;
271 DataArrayDouble::isMonotonic(bool increasing, double eps) const;
272 DataArrayDouble::repr() const;
273 DataArrayDouble::isEqual(const DataArrayDouble& other, double prec) const;
274 DataArrayDouble::isEqualWithoutConsideringStr(const DataArrayDouble& other, double prec) const;
275 DataArrayDouble::reAlloc(int nbOfTuples);
276 DataArrayDouble::convertToIntArr() const;
277 DataArrayDouble::fromNoInterlace() const;
278 DataArrayDouble::toNoInterlace() const;
279 DataArrayDouble::renumberInPlace(const int* old2New);
280 DataArrayDouble::renumberInPlaceR(const int* new2Old);
281 DataArrayDouble::renumber(const int* old2New) const;
282 DataArrayDouble::renumberR(const int* new2Old) const;
283 DataArrayDouble::renumberAndReduce(const int* old2New, int newNbOfTuple) const;
284 DataArrayDouble::selectByTupleId(const int* new2OldBg, const int* new2OldEnd) const;
285 DataArrayDouble::selectByTupleIdSafe(const int* new2OldBg, const int* new2OldEnd) const;
286 DataArrayDouble::selectByTupleId2(int bg, int end2, int step) const;
287 DataArrayDouble::selectByTupleRanges(const std::vector<std::pair<int,int> >& ranges) const;
288 DataArrayDouble::subArray(int tupleIdBg, int tupleIdEnd=-1) const;
289 DataArrayDouble::rearrange(int newNbOfCompo);
290 DataArrayDouble::transpose();
291 DataArrayDouble::changeNbOfComponents(int newNbOfComp, double dftValue) const;
292 DataArrayDouble::keepSelectedComponents(const std::vector<int>& compoIds) const;
293 DataArrayDouble::meldWith(const DataArrayDouble* other);
294 DataArrayDouble::findCommonTuples(double prec, int limitTupleId, DataArrayInt *&comm, DataArrayInt *&commIndex) const;
295 DataArrayDouble::getDifferentValues(double prec, int limitTupleId=-1) const;
296 DataArrayDouble::setSelectedComponents(const DataArrayDouble* a, const std::vector<int>& compoIds);
297 DataArrayDouble::setPartOfValues1(const DataArrayDouble* a, int bgTuples, int endTuples, int stepTuples, int bgComp, int endComp, int stepComp, bool strictCompoCompare=true);
298 DataArrayDouble::setPartOfValuesSimple1(double a, int bgTuples, int endTuples, int stepTuples, int bgComp, int endComp, int stepComp);
299 DataArrayDouble::setPartOfValues2(const DataArrayDouble* a, const int* bgTuples, const int* endTuples, const int* bgComp, const int* endComp, bool strictCompoCompare=true);
300 DataArrayDouble::setPartOfValuesSimple2(double a, const int* bgTuples, const int* endTuples, const int* bgComp, const int* endComp);
301 DataArrayDouble::setPartOfValues3(const DataArrayDouble* a, const int* bgTuples, const int* endTuples, int bgComp, int endComp, int stepComp, bool strictCompoCompare=true);
302 DataArrayDouble::setPartOfValuesSimple3(double a, const int* bgTuples, const int* endTuples, int bgComp, int endComp, int stepComp);
303 DataArrayDouble::getTuple(int tupleId, double* res) const;
304 DataArrayDouble::getIJ(int tupleId, int compoId) const;
305 DataArrayDouble::back() const;
306 DataArrayDouble::getIJSafe(int tupleId, int compoId) const;
307 DataArrayDouble::setIJ(int tupleId, int compoId, double newVal);
308 DataArrayDouble::setIJSilent(int tupleId, int compoId, double newVal);
309 DataArrayDouble::writeOnPlace(int id, double element0, const double* others, int sizeOfOthers);
310 DataArrayDouble::checkNoNullValues() const;
311 DataArrayDouble::getMinMaxPerComponent(double* bounds) const;
312 DataArrayDouble::getMaxValue(int& tupleId) const;
313 DataArrayDouble::getMaxValueInArray() const;
314 DataArrayDouble::getMinValue(int& tupleId) const;
315 DataArrayDouble::getMinValueInArray() const;
316 DataArrayDouble::getMaxValue2(DataArrayInt*& tupleIds) const;
317 DataArrayDouble::getMinValue2(DataArrayInt*& tupleIds) const;
318 DataArrayDouble::getAverageValue() const;
319 DataArrayDouble::norm2() const;
320 DataArrayDouble::normMax() const;
321 DataArrayDouble::accumulate(double* res) const;
322 DataArrayDouble::accumulate(int compId) const;
323 DataArrayDouble::fromPolarToCart() const;
324 DataArrayDouble::fromCylToCart() const;
325 DataArrayDouble::fromSpherToCart() const;
326 DataArrayDouble::doublyContractedProduct() const;
327 DataArrayDouble::determinant() const;
328 DataArrayDouble::eigenValues() const;
329 DataArrayDouble::eigenVectors() const;
330 DataArrayDouble::inverse() const;
331 DataArrayDouble::trace() const;
332 DataArrayDouble::deviator() const;
333 DataArrayDouble::magnitude() const;
334 DataArrayDouble::maxPerTuple() const;
335 DataArrayDouble::sortPerTuple(bool asc);
336 DataArrayDouble::abs();
337 DataArrayDouble::applyLin(double a, double b, int compoId);
338 DataArrayDouble::applyLin(double a, double b);
339 DataArrayDouble::applyInv(double numerator);
340 DataArrayDouble::negate() const;
341 DataArrayDouble::applyFunc(int nbOfComp, const std::string& func, bool isSafe=true) const;
342 DataArrayDouble::applyFunc(const std::string& func, bool isSafe=true) const;
343 DataArrayDouble::applyFunc2(int nbOfComp, const std::string& func, bool isSafe=true) const;
344 DataArrayDouble::applyFunc3(int nbOfComp, const std::vector<std::string>& varsOrder, const std::string& func, bool isSafe=true) const;
345 DataArrayDouble::getIdsInRange(double vmin, double vmax) const;
346 DataArrayDouble::addEqual(const DataArrayDouble* other);
347 DataArrayDouble::substractEqual(const DataArrayDouble* other);
348 DataArrayDouble::multiplyEqual(const DataArrayDouble* other);
349 DataArrayDouble::divideEqual(const DataArrayDouble* other);
350 DataArrayDouble::updateTime() const;
351 DataArrayDouble::New();
352 DataArrayDouble::Aggregate(const DataArrayDouble* a1, const DataArrayDouble* a2);
353 DataArrayDouble::Aggregate(const std::vector<const DataArrayDouble *>& arr);
354 DataArrayDouble::Meld(const DataArrayDouble* a1, const DataArrayDouble* a2);
355 DataArrayDouble::Meld(const std::vector<const DataArrayDouble *>& arr);
356 DataArrayDouble::Dot(const DataArrayDouble* a1, const DataArrayDouble* a2);
357 DataArrayDouble::CrossProduct(const DataArrayDouble* a1, const DataArrayDouble* a2);
358 DataArrayDouble::Max(const DataArrayDouble* a1, const DataArrayDouble* a2);
359 DataArrayDouble::Min(const DataArrayDouble* a1, const DataArrayDouble* a2);
360 DataArrayDouble::Add(const DataArrayDouble* a1, const DataArrayDouble* a2);
361 DataArrayDouble::Substract(const DataArrayDouble* a1, const DataArrayDouble* a2);
362 DataArrayDouble::Multiply(const DataArrayDouble* a1, const DataArrayDouble* a2);
363 DataArrayDouble::Divide(const DataArrayDouble* a1, const DataArrayDouble* a2);
364 ///@}
365
366 /*! \name   Advanced API   */
367 ///@{
368 DataArrayDouble::checkAllocated() const;
369 DataArrayDouble::setPartOfValuesAdv(const DataArrayDouble* a, const DataArrayInt* tuplesSelec);
370 DataArrayDouble::setContigPartOfSelectedValues(int tupleIdStart, const DataArrayDouble* a, const DataArrayInt* tuplesSelec);
371 DataArrayDouble::setContigPartOfSelectedValues2(int tupleIdStart, const DataArrayDouble* a, int bg, int end2, int step);
372 DataArrayDouble::applyFunc(int nbOfComp, FunctionToEvaluate func) const;
373 ///@} 
374
375 /*! \name Others... */
376 ///@{
377 DataArrayDouble::getNumberOfTuples() const;
378 DataArrayDouble::getNbOfElems() const;
379 //DataArrayDouble::getHeapMemorySize() const;
380 DataArrayDouble::reserve(int nbOfElems);
381 DataArrayDouble::pushBackSilent(double val);
382 DataArrayDouble::popBackSilent();
383 DataArrayDouble::pack() const;
384 DataArrayDouble::getNbOfElemAllocated() const;
385 DataArrayDouble::reprZip() const;
386 DataArrayDouble::writeVTK(std::ostream& ofs, int indent, const char* nameInFile) const;
387 DataArrayDouble::reprStream(std::ostream& stream) const;
388 DataArrayDouble::reprZipStream(std::ostream& stream) const;
389 DataArrayDouble::reprWithoutNameStream(std::ostream& stream) const;
390 DataArrayDouble::reprZipWithoutNameStream(std::ostream& stream) const;
391 DataArrayDouble::reprCppStream(const char* varName, std::ostream& stream) const;
392 DataArrayDouble::isEqualIfNotWhy(const DataArrayDouble& other, double prec, std::string& reason) const;
393 DataArrayDouble::duplicateEachTupleNTimes(int nbTimes) const;
394 DataArrayDouble::setPartOfValues4(const DataArrayDouble* a, int bgTuples, int endTuples, int stepTuples, const int* bgComp, const int* endComp, bool strictCompoCompare=true);
395 DataArrayDouble::setPartOfValuesSimple4(double a, int bgTuples, int endTuples, int stepTuples, const int* bgComp, const int* endComp);
396 DataArrayDouble::getPointer();
397 DataArrayDouble::SetArrayIn(DataArrayDouble* newArray, DataArrayDouble* &arrayToSet);
398 DataArrayDouble::iterator();
399 DataArrayDouble::getConstPointer() const;
400 DataArrayDouble::begin() const;
401 DataArrayDouble::end() const;
402 DataArrayDouble::useArray(const double* array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo);
403 DataArrayDouble::useExternalArrayWithRWAccess(const double* array, int nbOfTuple, int nbOfCompo);
404 DataArrayDouble::insertAtTheEnd(InputIterator first, InputIterator last);
405 DataArrayDouble::computeBBoxPerTuple(double epsilon=0.0) const;
406 DataArrayDouble::computeTupleIdsNearTuples(const DataArrayDouble* other, double eps, DataArrayInt *& c, DataArrayInt *& cI) const;
407 DataArrayDouble::recenterForMaxPrecision(double eps);
408 DataArrayDouble::distanceToTuple(const double* tupleBg, const double* tupleEnd, int& tupleId) const;
409 DataArrayDouble::buildEuclidianDistanceDenseMatrix() const;
410 DataArrayDouble::buildEuclidianDistanceDenseMatrixWith(const DataArrayDouble* other) const;
411 DataArrayDouble::applyFuncFast32(const std::string& func);
412 DataArrayDouble::applyFuncFast64(const std::string& func);
413 DataArrayDouble::getTinySerializationIntInformation(std::vector<int>& tinyInfo) const;
414 DataArrayDouble::getTinySerializationStrInformation(std::vector<std::string>& tinyInfo) const;
415 DataArrayDouble::resizeForUnserialization(const std::vector<int>& tinyInfoI);
416 DataArrayDouble::finishUnserialization(const std::vector<int>& tinyInfoI, const std::vector<std::string>& tinyInfoS);
417
418 DataArrayDouble::findCommonTuplesAlg(const double* bbox, int nbNodes, int limitNodeId, double prec, DataArrayInt* c, DataArrayInt* cI) const;
419
420 DataArrayDouble::FindTupleIdsNearTuplesAlg(const BBTree<SPACEDIM,int>& myTree, const double* pos, int nbOfTuples, double eps, DataArrayInt* c, DataArrayInt* cI);
421 DataArrayDouble::DataArrayDouble();
422 MemArray<double> DataArrayDouble::_mem;
423 ///@} 
424
425 //================================================================================
426 /////////////////////// DataArrayInt GROUPPING ///////////////////////////////////
427 //================================================================================
428
429 /*! \name Advanced API  */
430 ///@{
431 DataArrayInt::checkAllocated() const;
432 DataArrayInt::getHashCode() const;
433 DataArrayInt::buildPermutationArr(const DataArrayInt& other) const;
434 DataArrayInt::transformWithIndArr(const int* indArrBg, const int* indArrEnd);
435 DataArrayInt::transformWithIndArrR(const int* indArrBg, const int* indArrEnd) const;
436 DataArrayInt::splitByValueRange(const int* arrBg, const int* arrEnd,DataArrayInt *& castArr, DataArrayInt *& rankInsideCast, DataArrayInt *& castsPresent) const;
437 DataArrayInt::setPartOfValuesAdv(const DataArrayInt* a, const DataArrayInt* tuplesSelec);
438 DataArrayInt::setContigPartOfSelectedValues(int tupleIdStart, const DataArrayInt*a, const DataArrayInt* tuplesSelec);
439 DataArrayInt::setContigPartOfSelectedValues2(int tupleIdStart, const DataArrayInt* a, int bg, int end2, int step);
440 DataArrayInt::SetArrayIn(DataArrayInt* newArray, DataArrayInt* &arrayToSet);
441 ///@} 
442
443 /*! \name Basic API   */
444 ///@{
445 DataArrayInt::isAllocated() const;
446 //DataArrayInt::setInfoAndChangeNbOfCompo(const std::vector<std::string>& info);
447 DataArrayInt::intValue() const;
448 DataArrayInt::empty() const;
449 DataArrayInt::deepCpy() const;
450 DataArrayInt::performCpy(bool deepCpy) const;
451 DataArrayInt::cpyFrom(const DataArrayInt& other);
452 DataArrayInt::alloc(int nbOfTuple, int nbOfCompo);
453 DataArrayInt::allocIfNecessary(int nbOfTuple, int nbOfCompo);
454 DataArrayInt::isEqual(const DataArrayInt& other) const;
455 DataArrayInt::isEqualWithoutConsideringStr(const DataArrayInt& other) const;
456 DataArrayInt::isEqualWithoutConsideringStrAndOrder(const DataArrayInt& other) const;
457 DataArrayInt::sort(bool asc=true);
458 DataArrayInt::reverse();
459 DataArrayInt::fillWithZero();
460 DataArrayInt::fillWithValue(int val);
461 DataArrayInt::iota(int init=0);
462 DataArrayInt::repr() const;
463 DataArrayInt::invertArrayO2N2N2O(int newNbOfElem) const;
464 DataArrayInt::invertArrayN2O2O2N(int oldNbOfElem) const;
465 DataArrayInt::reAlloc(int nbOfTuples);
466 DataArrayInt::convertToDblArr() const;
467 DataArrayInt::fromNoInterlace() const;
468 DataArrayInt::toNoInterlace() const;
469 DataArrayInt::renumberInPlace(const int* old2New);
470 DataArrayInt::renumberInPlaceR(const int* new2Old);
471 DataArrayInt::renumber(const int* old2New) const;
472 DataArrayInt::renumberR(const int* new2Old) const;
473 DataArrayInt::renumberAndReduce(const int* old2NewBg, int newNbOfTuple) const;
474 DataArrayInt::selectByTupleId(const int* new2OldBg, const int* new2OldEnd) const;
475 DataArrayInt::selectByTupleIdSafe(const int* new2OldBg, const int* new2OldEnd) const;
476 DataArrayInt::selectByTupleId2(int bg, int end, int step) const;
477 DataArrayInt::selectByTupleRanges(const std::vector<std::pair<int,int> >& ranges) const;
478 DataArrayInt::checkAndPreparePermutation() const;
479 DataArrayInt::changeSurjectiveFormat(int targetNb, DataArrayInt *&arr, DataArrayInt *&arrI) const;
480 DataArrayInt::buildPermArrPerLevel() const;
481 DataArrayInt::isIdentity2(int sizeExpected) const;
482 DataArrayInt::isUniform(int val) const;
483 DataArrayInt::subArray(int tupleIdBg, int tupleIdEnd=-1) const;
484 DataArrayInt::rearrange(int newNbOfCompo);
485 DataArrayInt::transpose();
486 DataArrayInt::changeNbOfComponents(int newNbOfComp, int dftValue) const;
487 DataArrayInt::keepSelectedComponents(const std::vector<int>& compoIds) const;
488 DataArrayInt::meldWith(const DataArrayInt* other);
489 DataArrayInt::setSelectedComponents(const DataArrayInt* a, const std::vector<int>& compoIds);
490 DataArrayInt::setPartOfValues1(const DataArrayInt* a, int bgTuples, int endTuples, int stepTuples, int bgComp, int endComp, int stepComp, bool strictCompoCompare=true);
491 DataArrayInt::setPartOfValuesSimple1(int a, int bgTuples, int endTuples, int stepTuples, int bgComp, int endComp, int stepComp);
492 DataArrayInt::setPartOfValues2(const DataArrayInt* a, const int* bgTuples, const int* endTuples, const int* bgComp, const int* endComp, bool strictCompoCompare=true);
493 DataArrayInt::setPartOfValuesSimple2(int a, const int* bgTuples, const int* endTuples, const int* bgComp, const int* endComp);
494 DataArrayInt::setPartOfValues3(const DataArrayInt* a, const int* bgTuples, const int* endTuples, int bgComp, int endComp, int stepComp, bool strictCompoCompare=true);
495 DataArrayInt::setPartOfValuesSimple3(int a, const int* bgTuples, const int* endTuples, int bgComp, int endComp, int stepComp);
496 DataArrayInt::getTuple(int tupleId, int* res) const;
497 DataArrayInt::getIJ(int tupleId, int compoId) const;
498 DataArrayInt::getIJSafe(int tupleId, int compoId) const;
499 DataArrayInt::back() const;
500 DataArrayInt::setIJ(int tupleId, int compoId, int newVal);
501 DataArrayInt::setIJSilent(int tupleId, int compoId, int newVal);
502 DataArrayInt::getPointer();
503 DataArrayInt::getConstPointer() const;
504 DataArrayInt::getIdsEqual(int val) const;
505 DataArrayInt::getIdsNotEqual(int val) const;
506 DataArrayInt::getIdsEqualList(const int* valsBg, const int* valsEnd) const;
507 DataArrayInt::getIdsNotEqualList(const int* valsBg, const int* valsEnd) const;
508 DataArrayInt::changeValue(int oldValue, int newValue);
509 DataArrayInt::presenceOfValue(int value) const;
510 DataArrayInt::presenceOfValue(const std::vector<int>& vals) const;
511 DataArrayInt::getMaxValue(int& tupleId) const;
512 DataArrayInt::getMaxValueInArray() const;
513 DataArrayInt::getMinValue(int& tupleId) const;
514 DataArrayInt::getMinValueInArray() const;
515 DataArrayInt::abs();
516 DataArrayInt::applyLin(int a, int b, int compoId);
517 DataArrayInt::applyLin(int a, int b);
518 DataArrayInt::applyInv(int numerator);
519 DataArrayInt::negate() const;
520 DataArrayInt::applyDivideBy(int val);
521 DataArrayInt::applyModulus(int val);
522 DataArrayInt::applyRModulus(int val);
523 DataArrayInt::buildComplement(int nbOfElement) const;
524 DataArrayInt::buildSubstraction(const DataArrayInt* other) const;
525 DataArrayInt::buildUnion(const DataArrayInt* other) const;
526 DataArrayInt::buildIntersection(const DataArrayInt* other) const;
527 DataArrayInt::deltaShiftIndex() const;
528 DataArrayInt::computeOffsets();
529 DataArrayInt::computeOffsets2();
530 DataArrayInt::buildExplicitArrByRanges(const DataArrayInt* offsets) const;
531 DataArrayInt::useArray(const int* array, bool ownership, DeallocType type, int nbOfTuple, int nbOfCompo);
532 DataArrayInt::writeOnPlace(int id, int element0, const int* others, int sizeOfOthers);
533 DataArrayInt::addEqual(const DataArrayInt* other);
534 DataArrayInt::substractEqual(const DataArrayInt* other);
535 DataArrayInt::multiplyEqual(const DataArrayInt* other);
536 DataArrayInt::divideEqual(const DataArrayInt* other);
537 DataArrayInt::modulusEqual(const DataArrayInt* other);
538 DataArrayInt::updateTime() const;
539 DataArrayInt::New();
540 DataArrayInt::BuildOld2NewArrayFromSurjectiveFormat2(int nbOfOldTuples, const int* arr, const int* arrIBg, const int* arrIEnd, int &newNbOfTuples);
541 DataArrayInt::Aggregate(const DataArrayInt* a1, const DataArrayInt* a2, int offsetA2);
542 DataArrayInt::Aggregate(const std::vector<const DataArrayInt *>& arr);
543 DataArrayInt::Meld(const DataArrayInt* a1, const DataArrayInt* a2);
544 DataArrayInt::Meld(const std::vector<const DataArrayInt *>& arr);
545 DataArrayInt::MakePartition(const std::vector<const DataArrayInt *>& groups, int newNb, std::vector< std::vector<int> >& fidsOfGroups);
546 DataArrayInt::BuildUnion(const std::vector<const DataArrayInt *>& arr);
547 DataArrayInt::BuildIntersection(const std::vector<const DataArrayInt *>& arr);
548 DataArrayInt::Add(const DataArrayInt* a1, const DataArrayInt* a2);
549 DataArrayInt::Substract(const DataArrayInt* a1, const DataArrayInt* a2);
550 DataArrayInt::Multiply(const DataArrayInt* a1, const DataArrayInt* a2);
551 DataArrayInt::Divide(const DataArrayInt* a1, const DataArrayInt* a2);
552 DataArrayInt::Modulus(const DataArrayInt* a1, const DataArrayInt* a2);
553 DataArrayInt::CheckAndPreparePermutation(const int* start, const int* end);
554 DataArrayInt::Range(int begin, int end, int step);
555 ///@} 
556
557 /*! \name Others... */
558 ///@{
559 DataArrayInt::getNumberOfTuples() const;
560 DataArrayInt::getNbOfElems() const;
561 //DataArrayInt::getHeapMemorySize() const;
562 DataArrayInt::reserve(int nbOfElems);
563 DataArrayInt::pushBackSilent(int val);
564 DataArrayInt::popBackSilent();
565 DataArrayInt::pack() const;
566 DataArrayInt::getNbOfElemAllocated() const;
567 DataArrayInt::isEqualIfNotWhy(const DataArrayInt& other, std::string& reason) const;
568 DataArrayInt::checkMonotonic(bool increasing) const;
569 DataArrayInt::isMonotonic(bool increasing) const;
570 DataArrayInt::checkStrictlyMonotonic(bool increasing) const;
571 DataArrayInt::isStrictlyMonotonic(bool increasing) const;
572 DataArrayInt::reprZip() const;
573 DataArrayInt::writeVTK(std::ostream& ofs, int indent, const char* type, const char* nameInFile) const;
574 DataArrayInt::reprStream(std::ostream& stream) const;
575 DataArrayInt::reprZipStream(std::ostream& stream) const;
576 DataArrayInt::reprWithoutNameStream(std::ostream& stream) const;
577 DataArrayInt::reprZipWithoutNameStream(std::ostream& stream) const;
578 DataArrayInt::reprCppStream(const char* varName, std::ostream& stream) const;
579 DataArrayInt::invertArrayO2N2N2OBis(int newNbOfElem) const;
580 DataArrayInt::setPartOfValues4(const DataArrayInt* a, int bgTuples, int endTuples, int stepTuples, const int* bgComp, const int* endComp, bool strictCompoCompare=true);
581 DataArrayInt::setPartOfValuesSimple4(int a, int bgTuples, int endTuples, int stepTuples, const int* bgComp, const int* endComp);
582 DataArrayInt::iterator();
583 DataArrayInt::begin() const;
584 DataArrayInt::end() const;
585 DataArrayInt::locateTuple(const std::vector<int>& tupl) const;
586 DataArrayInt::locateValue(int value) const;
587 DataArrayInt::locateValue(const std::vector<int>& vals) const;
588 DataArrayInt::findIdSequence(const std::vector<int>& vals) const;
589 DataArrayInt::presenceOfTuple(const std::vector<int>& tupl) const;
590 DataArrayInt::accumulate(int* res) const;
591 DataArrayInt::accumulate(int compId) const;
592 DataArrayInt::getIdsInRange(int vmin, int vmax) const;
593 DataArrayInt::buildSubstractionOptimized(const DataArrayInt* other) const;
594 DataArrayInt::buildUnique() const;
595 DataArrayInt::findRangeIdForEachTuple(const DataArrayInt* ranges) const;
596 DataArrayInt::findIdInRangeForEachTuple(const DataArrayInt* ranges) const;
597 DataArrayInt::duplicateEachTupleNTimes(int nbTimes) const;
598 DataArrayInt::getDifferentValues() const;
599 > DataArrayInt::partitionByDifferentValues(std::vector<int>& differentIds) const;
600 DataArrayInt::useExternalArrayWithRWAccess(const int* array, int nbOfTuple, int nbOfCompo);
601 tor>
602 DataArrayInt::insertAtTheEnd(InputIterator first, InputIterator last);
603 DataArrayInt::getTinySerializationIntInformation(std::vector<int>& tinyInfo) const;
604 DataArrayInt::getTinySerializationStrInformation(std::vector<std::string>& tinyInfo) const;
605 DataArrayInt::resizeForUnserialization(const std::vector<int>& tinyInfoI);
606 DataArrayInt::finishUnserialization(const std::vector<int>& tinyInfoI, const std::vector<std::string>& tinyInfoS);
607 DataArrayInt::DataArrayInt();
608 MemArray<int> DataArrayInt::_mem;
609 ///@}
610
611 }