Nebula
Loading...
Searching...
No Matches
osxfiletime.h
Go to the documentation of this file.
1#pragma once
2//------------------------------------------------------------------------------
11#include "core/types.h"
12
13//------------------------------------------------------------------------------
14namespace OSX
15{
17{
18public:
22 friend bool operator==(const OSXFileTime& a, const OSXFileTime& b);
24 friend bool operator!=(const OSXFileTime& a, const OSXFileTime& b);
26 friend bool operator>(const OSXFileTime& a, const OSXFileTime& b);
28 friend bool operator<(const OSXFileTime& a, const OSXFileTime& b);
29
30 time_t fileTime;
31};
32
33//------------------------------------------------------------------------------
36inline
38 fileTime(0)
39{
40 // empty
41}
42
43//------------------------------------------------------------------------------
46inline bool
48{
49 return (a.fileTime == b.fileTime);
50}
51
52//------------------------------------------------------------------------------
55inline bool
57{
58 return (a.fileTime != b.fileTime);
59}
60
61//------------------------------------------------------------------------------
64inline bool
66{
67 return (a.fileTime > b.fileTime);
68}
69
70//------------------------------------------------------------------------------
73inline bool
74operator <(const OSXFileTime& a, const OSXFileTime& b)
75{
76 return (a.fileTime < b.fileTime);
77}
78
79} // namespace OSX
Wraps file-system related timestamps on OSX.
Definition osxfiletime.h:17
time_t fileTime
Definition osxfiletime.h:30
friend bool operator>(const OSXFileTime &a, const OSXFileTime &b)
operator >
Definition osxfiletime.h:65
friend bool operator<(const OSXFileTime &a, const OSXFileTime &b)
operator <
Definition osxfiletime.h:74
OSXFileTime()
constructor
Definition osxfiletime.h:37
friend bool operator==(const OSXFileTime &a, const OSXFileTime &b)
operator ==
Definition osxfiletime.h:47
friend bool operator!=(const OSXFileTime &a, const OSXFileTime &b)
operator !=
Definition osxfiletime.h:56
Definition osxsysfunc.h:21
bool operator>(const OSXFileTime &a, const OSXFileTime &b)
Definition osxfiletime.h:65
bool operator<(const OSXFileTime &a, const OSXFileTime &b)
Definition osxfiletime.h:74
bool operator!=(const OSXFileTime &a, const OSXFileTime &b)
Definition osxfiletime.h:56
bool operator==(const OSXFileTime &a, const OSXFileTime &b)
Definition osxfiletime.h:47