X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FMEDCoupling_Swig%2FMEDCouplingRefCountObject.i;h=fa29e6032415beaf0db0e8e00c0dbb70bf39c175;hb=8be544a31d08ec0537eef57b60edd48bc70c22db;hp=48003ef559df723474de5192f32e7276d27e03c7;hpb=8e5053c4181a60f206e65e736fbfd8bbca2c0d88;p=tools%2Fmedcoupling.git diff --git a/src/MEDCoupling_Swig/MEDCouplingRefCountObject.i b/src/MEDCoupling_Swig/MEDCouplingRefCountObject.i index 48003ef55..fa29e6032 100644 --- a/src/MEDCoupling_Swig/MEDCouplingRefCountObject.i +++ b/src/MEDCoupling_Swig/MEDCouplingRefCountObject.i @@ -1,4 +1,4 @@ -// Copyright (C) 2007-2015 CEA/DEN, EDF R&D +// Copyright (C) 2007-2016 CEA/DEN, EDF R&D // // This library is free software; you can redistribute it and/or // modify it under the terms of the GNU Lesser General Public @@ -36,7 +36,7 @@ namespace INTERP_KERNEL }; } -namespace ParaMEDMEM +namespace MEDCoupling { class TimeLabel { @@ -49,7 +49,7 @@ namespace ParaMEDMEM }; } -namespace ParaMEDMEM +namespace MEDCoupling { typedef enum { @@ -78,7 +78,7 @@ namespace ParaMEDMEM std::vector c(self->getDirectChildren()); PyObject *ret(PyList_New(c.size())); for(std::size_t i=0;i c(self->getAllTheProgeny()); PyObject *ret(PyList_New(c.size())); for(std::size_t i=0;i cppObjs; - convertFromPyObjVectorOfObj(objs,SWIGTYPE_p_ParaMEDMEM__BigMemoryObject,"BigMemoryObject",cppObjs); + convertFromPyObjVectorOfObj(objs,SWIGTYPE_p_MEDCoupling__BigMemoryObject,"BigMemoryObject",cppObjs); return BigMemoryObject::GetHeapMemorySizeOfObjs(cppObjs); } } @@ -115,6 +115,29 @@ namespace ParaMEDMEM protected: ~RefCountObject(); }; + + class GlobalDict + { + public: + static GlobalDict *GetInstance() throw(INTERP_KERNEL::Exception); + bool hasKey(const std::string& key) const throw(INTERP_KERNEL::Exception); + std::string value(const std::string& key) const throw(INTERP_KERNEL::Exception); + std::vector keys() const throw(INTERP_KERNEL::Exception); + void erase(const std::string& key) throw(INTERP_KERNEL::Exception); + void clear() throw(INTERP_KERNEL::Exception); + void setKeyValue(const std::string& key, const std::string& value) throw(INTERP_KERNEL::Exception); + void setKeyValueForce(const std::string& key, const std::string& value) throw(INTERP_KERNEL::Exception); + private: + GlobalDict(); + public: + %extend + { + std::string __str__() const + { + return self->printSelf(); + } + } + }; } %inline