ESyS-Particle
2.3.4
Vec3Comparer.h
Go to the documentation of this file.
1
// //
3
// Copyright (c) 2003-2017 by The University of Queensland //
4
// Centre for Geoscience Computing //
5
// http://earth.uq.edu.au/centre-geoscience-computing //
6
// //
7
// Primary Business: Brisbane, Queensland, Australia //
8
// Licensed under the Open Software License version 3.0 //
9
// http://www.apache.org/licenses/LICENSE-2.0 //
10
// //
12
13
14
#ifndef ESYS_LSMVEC3COMPARE_H
15
#define ESYS_LSMVEC3COMPARE_H
16
17
#include "
Foundation/vec3.h
"
18
19
namespace
esys
20
{
21
namespace
lsm
22
{
23
class
Vec3XyzComparer
24
{
25
public
:
26
bool
operator()
(
const
Vec3
&v1,
const
Vec3
&v2)
const
27
{
28
return
29
(
30
(v1.
X
() < v2.
X
())
31
||
32
(
33
(v1.
X
() == v2.
X
())
34
&&
35
(
36
(v1.
Y
() < v2.
Y
())
37
||
38
(
39
(v1.
Y
() == v2.
Y
())
40
&&
41
(v1.
Z
() < v2.
Z
())
42
)
43
)
44
)
45
);
46
}
47
};
48
49
class
Vec3ZyxComparer
50
{
51
public
:
52
bool
operator()
(
const
Vec3
&v1,
const
Vec3
&v2)
const
53
{
54
return
55
(
56
(v1.
Z
() < v2.
Z
())
57
||
58
(
59
(v1.
Z
() == v2.
Z
())
60
&&
61
(
62
(v1.
Y
() < v2.
Y
())
63
||
64
(
65
(v1.
Y
() == v2.
Y
())
66
&&
67
(v1.
X
() < v2.
X
())
68
)
69
)
70
)
71
);
72
}
73
};
74
}
75
}
76
#endif
esys::lsm::Vec3XyzComparer::operator()
bool operator()(const Vec3 &v1, const Vec3 &v2) const
Definition:
Vec3Comparer.h:26
esys::lsm::Vec3ZyxComparer::operator()
bool operator()(const Vec3 &v1, const Vec3 &v2) const
Definition:
Vec3Comparer.h:52
esys::lsm::Vec3XyzComparer
Definition:
Vec3Comparer.h:24
Vec3::X
VEC3_INLINE double & X()
Definition:
vec3.h:119
esys
Definition:
CheckPointable.cpp:17
Vec3::Z
VEC3_INLINE double & Z()
Definition:
vec3.h:121
Vec3::Y
VEC3_INLINE double & Y()
Definition:
vec3.h:120
Vec3
Definition:
vec3.h:47
vec3.h
esys::lsm::Vec3ZyxComparer
Definition:
Vec3Comparer.h:50
Tools
StressCalculator
Vec3Comparer.h
Generated by
1.8.20