Apache Ignite C++
date.h
Go to the documentation of this file.
1 /*
2  * Licensed to the Apache Software Foundation (ASF) under one or more
3  * contributor license agreements. See the NOTICE file distributed with
4  * this work for additional information regarding copyright ownership.
5  * The ASF licenses this file to You under the Apache License, Version 2.0
6  * (the "License"); you may not use this file except in compliance with
7  * the License. You may obtain a copy of the License at
8  *
9  * http://www.apache.org/licenses/LICENSE-2.0
10  *
11  * Unless required by applicable law or agreed to in writing, software
12  * distributed under the License is distributed on an "AS IS" BASIS,
13  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14  * See the License for the specific language governing permissions and
15  * limitations under the License.
16  */
17 
23 #ifndef _IGNITE_DATE
24 #define _IGNITE_DATE
25 
26 #include <stdint.h>
27 
28 #include <ignite/common/common.h>
29 
30 namespace ignite
31 {
35  class IGNITE_IMPORT_EXPORT Date
36  {
37  public:
41  Date();
42 
48  Date(const Date& another);
49 
55  Date(int64_t ms);
56 
63  Date& operator=(const Date& another);
64 
70  int64_t GetMilliseconds() const;
71 
77  int64_t GetSeconds() const;
78 
86  friend bool IGNITE_IMPORT_EXPORT operator==(const Date& val1, const Date& val2);
87 
95  friend bool IGNITE_IMPORT_EXPORT operator!=(const Date& val1, const Date& val2);
96 
104  friend bool IGNITE_IMPORT_EXPORT operator<(const Date& val1, const Date& val2);
105 
113  friend bool IGNITE_IMPORT_EXPORT operator<=(const Date& val1, const Date& val2);
114 
122  friend bool IGNITE_IMPORT_EXPORT operator>(const Date& val1, const Date& val2);
123 
131  friend bool IGNITE_IMPORT_EXPORT operator>=(const Date& val1, const Date& val2);
132  private:
134  int64_t milliseconds;
135  };
136 }
137 
138 #endif //_IGNITE_DATE
ignite
Apache Ignite API.
Definition: cache.h:48
ignite::operator<
bool operator<(const Date &val1, const Date &val2)
Definition: date.cpp:64
ignite::operator>=
bool operator>=(const Date &val1, const Date &val2)
Definition: date.cpp:79
ignite::operator<=
bool operator<=(const Date &val1, const Date &val2)
Definition: date.cpp:69
ignite::Date
Date type.
Definition: date.h:35
ignite::operator>
bool operator>(const Date &val1, const Date &val2)
Definition: date.cpp:74
ignite::operator!=
bool operator!=(const Date &val1, const Date &val2)
Definition: date.cpp:59
ignite::operator==
bool operator==(const Date &val1, const Date &val2)
Definition: date.cpp:54