swift
Loading...
Searching...
No Matches
aircraftsituationchangelist.cpp
1// SPDX-FileCopyrightText: Copyright (C) 2018 swift Project Community / Contributors
2// SPDX-License-Identifier: GPL-3.0-or-later OR LicenseRef-swift-pilot-client-1
3
5
6SWIFT_DEFINE_SEQUENCE_MIXINS(swift::misc::aviation, CAircraftSituationChange, CAircraftSituationChangeList)
7
8namespace swift::misc::aviation
9{
13
15 {
16 if (this->isEmpty())
17 {
19 }
20 return this->front();
21 }
22
24 {
25 if (this->isEmpty())
26 {
28 }
29 return this->back();
30 }
31
33 {
34 if (this->size() > index)
35 {
36 return (*this)[index];
37 }
39 }
40} // namespace swift::misc::aviation
Value object about changes in situations.
static const CAircraftSituationChange & null()
NULL object.
CAircraftSituationChange indexOrNull(int index) const
Index or NULL.
CAircraftSituationChangeList()=default
Default constructor.
CAircraftSituationChange frontOrNull() const
Front or NULL.
CAircraftSituationChange backOrNull() const
Back or NULL.
#define SWIFT_DEFINE_SEQUENCE_MIXINS(Namespace, T, List)
Explicit template definition of mixins for a CSequence subclass.
Definition sequence.h:63