OpenMS
3.6.0
Main Page
Related Pages
Topics
Namespaces
Concepts
Classes
Files
File List
File Members
Loading...
Searching...
No Matches
Date.h
Go to the documentation of this file.
1
// Copyright (c) 2002-present, OpenMS Inc. -- EKU Tuebingen, ETH Zurich, and FU Berlin
2
// SPDX-License-Identifier: BSD-3-Clause
3
//
4
// --------------------------------------------------------------------------
5
// $Maintainer: Timo Sachsenberg$
6
// $Authors: Marc Sturm $
7
// --------------------------------------------------------------------------
8
9
#pragma once
10
11
#include <
OpenMS/CONCEPT/Types.h
>
12
#include <
OpenMS/DATASTRUCTURES/String.h
>
13
#include <OpenMS/OpenMSConfig.h>
14
15
namespace
OpenMS
16
{
25
class
OPENMS_DLLAPI
Date
26
{
27
public
:
28
34
Date
();
35
37
Date
(
const
Date
& date) =
default
;
38
40
Date
(
Date
&&) noexcept = default;
41
43
~
Date
() = default;
44
46
Date
& operator=(const
Date
& source) = default;
47
49
Date
& operator=(
Date
&&) & noexcept = default;
50
52
bool
operator==(const
Date
& rhs) const;
53
55
bool
operator!=(const
Date
& rhs) const;
56
58
bool
operator<(const
Date
& rhs) const;
59
70
void
set(const
String
& date);
71
77
void
set(
UInt
month,
UInt
day,
UInt
year);
78
80
static
Date
today();
81
87
String
get() const;
88
94
void
get(
UInt
& month,
UInt
& day,
UInt
& year) const;
95
97
void
clear();
98
100
bool
isValid() const;
101
103
bool
isNull() const;
104
106
int
year() const;
107
109
int
month() const;
110
112
int
day() const;
113
114
private:
115
struct
Fields
{
116
int
year = 0, month = 0, day = 0;
117
bool
valid =
false
;
118
} fields_;
119
};
120
}
// namespace OpenMS
String.h
Types.h
OpenMS::Date
Date Class.
Definition
Date.h:26
OpenMS::Date::Date
Date(const Date &date)=default
Copy constructor.
OpenMS::Date::Date
Date(Date &&) noexcept=default
Move constructor.
OpenMS::Date::Date
Date()
Default constructor.
OpenMS::Date::Fields
Definition
Date.h:115
OpenMS::String
A more convenient string class.
Definition
String.h:32
OpenMS::UInt
unsigned int UInt
Unsigned integer type.
Definition
Types.h:64
OpenMS
Main OpenMS namespace.
Definition
openswathalgo/include/OpenMS/OPENSWATHALGO/DATAACCESS/ISpectrumAccess.h:19
OpenMS
DATASTRUCTURES
Date.h
Generated on Sun Mar 22 2026 01:48:06 for OpenMS by
1.9.8