From: ageay Date: Wed, 10 Apr 2013 09:56:35 +0000 (+0000) Subject: default parameters in alloc for number of components X-Git-Tag: V6_main_FINAL~168 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=faa0fc32be2c14fee57157ba47d03ce833493297;p=tools%2Fmedcoupling.git default parameters in alloc for number of components --- diff --git a/src/MEDCoupling/MEDCouplingMemArray.hxx b/src/MEDCoupling/MEDCouplingMemArray.hxx index f4c74dc2b..1ad1b6b1d 100644 --- a/src/MEDCoupling/MEDCouplingMemArray.hxx +++ b/src/MEDCoupling/MEDCouplingMemArray.hxx @@ -180,7 +180,7 @@ namespace ParaMEDMEM MEDCOUPLING_EXPORT double popBackSilent() throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void pack() const throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT std::size_t getNbOfElemAllocated() const throw(INTERP_KERNEL::Exception) { return _mem.getNbOfElemAllocated(); } - MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void fillWithZero() throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void fillWithValue(double val) throw(INTERP_KERNEL::Exception); @@ -397,7 +397,7 @@ namespace ParaMEDMEM MEDCOUPLING_EXPORT int popBackSilent() throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void pack() const throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT std::size_t getNbOfElemAllocated() const throw(INTERP_KERNEL::Exception) { return _mem.getNbOfElemAllocated(); } - MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT bool isEqual(const DataArrayInt& other) const throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT bool isEqualIfNotWhy(const DataArrayInt& other, std::string& reason) const throw(INTERP_KERNEL::Exception); @@ -614,7 +614,7 @@ namespace ParaMEDMEM MEDCOUPLING_EXPORT char popBackSilent() throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void pack() const throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT std::size_t getNbOfElemAllocated() const throw(INTERP_KERNEL::Exception) { return _mem.getNbOfElemAllocated(); } - MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + MEDCOUPLING_EXPORT void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT bool isEqual(const DataArrayChar& other) const throw(INTERP_KERNEL::Exception); MEDCOUPLING_EXPORT virtual bool isEqualIfNotWhy(const DataArrayChar& other, std::string& reason) const throw(INTERP_KERNEL::Exception); diff --git a/src/MEDCoupling_Swig/MEDCouplingMemArray.i b/src/MEDCoupling_Swig/MEDCouplingMemArray.i index 6c6f1a0bf..2c3e1944c 100644 --- a/src/MEDCoupling_Swig/MEDCouplingMemArray.i +++ b/src/MEDCoupling_Swig/MEDCouplingMemArray.i @@ -100,7 +100,7 @@ namespace ParaMEDMEM void pushBackValsSilent(const double *valsBg, const double *valsEnd) throw(INTERP_KERNEL::Exception); double popBackSilent() throw(INTERP_KERNEL::Exception); void pack() const throw(INTERP_KERNEL::Exception); - void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); void fillWithZero() throw(INTERP_KERNEL::Exception); void fillWithValue(double val) throw(INTERP_KERNEL::Exception); @@ -2090,7 +2090,7 @@ namespace ParaMEDMEM void pushBackSilent(int val) throw(INTERP_KERNEL::Exception); int popBackSilent() throw(INTERP_KERNEL::Exception); void pack() const throw(INTERP_KERNEL::Exception); - void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); bool isEqual(const DataArrayInt& other) const throw(INTERP_KERNEL::Exception); bool isEqualWithoutConsideringStr(const DataArrayInt& other) const throw(INTERP_KERNEL::Exception); @@ -4402,7 +4402,7 @@ namespace ParaMEDMEM void pushBackValsSilent(const char *valsBg, const char *valsEnd) throw(INTERP_KERNEL::Exception); char popBackSilent() throw(INTERP_KERNEL::Exception); void pack() const throw(INTERP_KERNEL::Exception); - void alloc(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); + void alloc(int nbOfTuple, int nbOfCompo=1) throw(INTERP_KERNEL::Exception); void allocIfNecessary(int nbOfTuple, int nbOfCompo) throw(INTERP_KERNEL::Exception); bool isEqual(const DataArrayChar& other) const throw(INTERP_KERNEL::Exception); bool isEqualWithoutConsideringStr(const DataArrayChar& other) const throw(INTERP_KERNEL::Exception);