Index: XIOS/trunk/src/io/onetcdf4.hpp
===================================================================
--- XIOS/trunk/src/io/onetcdf4.hpp	(revision 686)
+++ XIOS/trunk/src/io/onetcdf4.hpp	(revision 707)
@@ -26,26 +26,26 @@
 
             /// Constructeurs ///
-            CONetCDF4(const StdString & filename, bool append, bool useClassicFormat = false,
-                      const MPI_Comm * comm = NULL, bool multifile = true);
+            CONetCDF4(const StdString& filename, bool append, bool useClassicFormat = false,
+                      const MPI_Comm* comm = NULL, bool multifile = true);
 
-            CONetCDF4(const CONetCDF4 & onetcdf4);       // Not implemented.
-            CONetCDF4(const CONetCDF4 * const onetcdf4); // Not implemented.
+            CONetCDF4(const CONetCDF4& onetcdf4);       // Not implemented.
+            CONetCDF4(const CONetCDF4* const onetcdf4); // Not implemented.
 
 
             /// Initialisation ///
-            void initialize(const StdString & filename, bool append, bool useClassicFormat,
-                            const MPI_Comm * comm, bool multifile);
-            void close(void) ;
-            void sync(void) ;
+            void initialize(const StdString& filename, bool append, bool useClassicFormat,
+                            const MPI_Comm* comm, bool multifile);
+            void close(void);
+            void sync(void);
             void definition_start(void);
             void definition_end(void);
 
             /// Mutateurs ///
-            void setCurrentPath(const CONetCDF4Path & path);
+            void setCurrentPath(const CONetCDF4Path& path);
 
-            int addGroup(const StdString & name);
+            int addGroup(const StdString& name);
             int addDimension(const StdString& name, const StdSize size = UNLIMITED_DIM);
-            int addVariable(const StdString & name, nc_type type,
-                            const std::vector<StdString> & dim);
+            int addVariable(const StdString& name, nc_type type,
+                            const std::vector<StdString>& dim);
 
       //----------------------------------------------------------------
@@ -53,22 +53,22 @@
 
             template <class T>
-               void setDefaultValue(const StdString & varname, const T * value = NULL);
+               void setDefaultValue(const StdString& varname, const T* value = NULL);
 
             void setCompressionLevel(const StdString& varname, int compressionLevel);
 
-            template <class T>  void addAttribute (const StdString & name, const T & value, const StdString * varname = NULL);
+            template <class T>  void addAttribute (const StdString& name, const T& value, const StdString* varname = NULL);
 
             /// Ecriture des donnÃ©es ///
             template <class T, int ndim>
-               void writeData(const CArray<T,ndim>& data, const StdString & name,
+               void writeData(const CArray<T,ndim>& data, const StdString& name,
                               bool collective, StdSize record,
-                              const std::vector<StdSize> * start = NULL,
-                              const std::vector<StdSize> * count = NULL);
+                              const std::vector<StdSize>* start = NULL,
+                              const std::vector<StdSize>* count = NULL);
 
-            void writeData(const CArray<int, 2>& data, const StdString & name);
-            void writeTimeAxisData(const CArray<double,1>& data, const StdString & name,
-                                   bool collective, StdSize record, bool Isroot) ;
+            void writeData(const CArray<int, 2>& data, const StdString& name);
+            void writeTimeAxisData(const CArray<double,1>& data, const StdString& name,
+                                   bool collective, StdSize record, bool Isroot);
             /// Accesseur ///
-            const CONetCDF4Path & getCurrentPath(void) const;
+            const CONetCDF4Path& getCurrentPath(void) const;
 
             /// Destructeur ///
@@ -86,13 +86,15 @@
             /// Accesseurs ///
             int getCurrentGroup(void);
-            int getGroup(const CONetCDF4Path & path);
-            int getVariable(const StdString & varname);
-            int getDimension(const StdString & dimname);
-            std::vector<StdSize>   getDimensions       (const StdString & varname);
-            std::vector<StdString> getDimensionsIdList (const StdString * varname);
+            int getGroup(const CONetCDF4Path& path);
+            int getVariable(const StdString& varname);
+            int getDimension(const StdString& dimname);
+            std::vector<StdSize>   getDimensions       (const StdString& varname);
+            std::vector<StdString> getDimensionsIdList (const StdString* varname);
             int       getUnlimitedDimension(void);
             StdString getUnlimitedDimensionName(void);
 
-            bool varExist(const StdString & varname);
+            void getTimeAxisBounds(CArray<double,2>& timeAxisBounds, const StdString& name, bool collective);
+
+            bool varExist(const StdString& varname);
 
             bool useClassicFormat; //!< If true, NetCDF4 will use the classic NetCDF3 format
@@ -101,15 +103,14 @@
 
          private :
+            template <class T>
+            void writeData_(int grpid, int varid,
+                            const std::vector<StdSize>& sstart,
+                            const std::vector<StdSize>& scount, T* data);
 
-            template <class T>
-               void writeData_(int grpid, int varid,
-                               const std::vector<StdSize> & sstart,
-                               const std::vector<StdSize> & scount, T * data);
-
-            void getWriteDataInfos(const StdString & name, StdSize record, StdSize & array_size,
-                                   std::vector<StdSize> & sstart,
-                                   std::vector<StdSize> & scount,
-                                   const std::vector<StdSize> * start,
-                                   const std::vector<StdSize> * count);
+            void getWriteDataInfos(const StdString& name, StdSize record, StdSize& array_size,
+                                   std::vector<StdSize>& sstart,
+                                   std::vector<StdSize>& scount,
+                                   const std::vector<StdSize>* start,
+                                   const std::vector<StdSize>* count);
 
             /// PropriÃ©tÃ©s privÃ©es ///
@@ -117,8 +118,5 @@
             int ncidp;
             bool wmpi;
-            /*! Number of records already written when opening an existing file.
-             *  always 0 when creating a new file */
-            size_t recordOffset;
-            map<int,size_t> timeAxis ;
+            map<int,size_t> timeAxis;
       }; // class CONetCDF4
 
