RMS SDK for C++  0.2.1
A client library for using Microsoft RMS from Linux.
DateTime.h
1 /*
2  * ======================================================================
3  * Copyright (c) Microsoft Open Technologies, Inc. All rights reserved.
4  * Licensed under the MIT License.
5  * See LICENSE.md in the project root for license information.
6  * ======================================================================
7 */
8 
9 #ifndef DATETIME_H
10 #define DATETIME_H
11 
12 #include "types.h"
13 
14 namespace rmsauth {
15 
16 class IDateTime
17 {
18 public:
19  virtual void addDays(int64_t ndays) = 0;
20  virtual void addMonths(int nmonths) = 0;
21  virtual void addYears(int nyears) = 0;
22  virtual void addMSecs(int64_t msecs) = 0;
23  virtual void addSecs(int64_t s) = 0;
24  virtual int64_t toTime() = 0;
25  virtual String toString(const String& format) = 0;
26 };
27 
28 class DateTime : public IDateTime
29 {
30 public:
31  DateTime();
32  DateTime(int64_t sec);
33  void addDays(int64_t ndays) override;
34  void addMSecs(int64_t msecs) override;
35  void addMonths(int nmonths) override;
36  void addSecs(int64_t s) override;
37  void addYears(int nyears) override;
38  int64_t toTime() override;
39  virtual String toString(const String& format) override;
40 private:
41  ptr<IDateTime> pImpl;
42 };
43 
44 } //namespace rmsauth {
45 
46 #endif // DATETIME_H
Definition: DateTime.h:28
Definition: DateTime.h:16
Definition: AcquireTokenForClientHandler.h:14