eliminated spurious estra leading '/'
[asdcplib.git] / src / KM_util.h
index d8b9bb3ddd2b82b800928c1fe92f622116080518..6bf2366cf991b3540a07b22493e51cfdb184e280 100755 (executable)
@@ -1,5 +1,5 @@
 /*
-Copyright (c) 2005-2008, John Hurst
+Copyright (c) 2005-2009, John Hurst
 All rights reserved.
 
 Redistribution and use in source and binary forms, with or without
@@ -362,7 +362,7 @@ namespace Kumu
   void GenRandomValue(SymmetricKey&);
 
   //
-  // 2004-05-01T13:20:00-00:00
+  // 2004-05-01T13:20:00+00:00
   const ui32_t DateTimeLen = 25; //  the number of chars in the xs:dateTime format (sans milliseconds)
 
   // UTC time+date representation
@@ -387,17 +387,20 @@ namespace Kumu
       bool operator==(const Timestamp& rhs) const;
       bool operator!=(const Timestamp& rhs) const;
 
-      // Write the timestamp value to the given buffer in the form 2004-05-01T13:20:00-00:00
+      // Write the timestamp value to the given buffer in the form 2004-05-01T13:20:00+00:00
       // returns 0 if the buffer is smaller than DateTimeLen
       const char* EncodeString(char* str_buf, ui32_t buf_len) const;
+      const char* EncodeStringWithOffset(char* str_buf, ui32_t buf_len,
+                                        i32_t offset_minutes = 0) const;
 
       // decode and set value from string formatted by EncodeString
       bool        DecodeString(const char* datestr);
 
-      // Add the given number of days or hours to the timestamp value.
+      // Add the given number of days, hours, or minutes to the timestamp value.
       // Values less than zero will cause the timestamp to decrease
       void AddDays(i32_t);
       void AddHours(i32_t);
+      void AddMinutes(i32_t);
 
       // Read and write the timestamp value as a byte string having
       // the following format: