25#ifndef __BITPIT_VERTEX_HPP__
26#define __BITPIT_VERTEX_HPP__
31#include "bitpit_common.hpp"
32#include "bitpit_containers.hpp"
39OBinaryStream&
operator<< (OBinaryStream &out,
const Vertex &vertex);
40IBinaryStream& operator>> (IBinaryStream &in, Vertex &vertex);
61 Less(
double tolerance)
62 : m_tolerance(tolerance)
66 bool operator()(
const Vertex &vertex_1,
const Vertex &vertex_2)
const
71 bool operator()(
const Vertex *vertex_1,
const Vertex *vertex_2)
const
76 bool operator()(
const std::array<double, 3> &coords_1,
const std::array<double, 3> &coords_2)
const
78 for (
int d = 0; d < 3; ++d) {
83 return coords_1[d] < coords_2[d];
95 Vertex(
long id,
bool interior =
true);
96 Vertex(
long id,
const std::array<double, 3> &coords,
bool interior =
true);
100 void initialize(
long id,
const std::array<double, 3> &coords,
bool interior);
107 const double &
operator[](
int coord_id)
const;
112 void setCoords(
const std::array<double, 3> &coords);
114 const std::array<double, 3> &
getCoords()
const;
116 void translate(
const std::array<double, 3> &translation);
117 void translate(
double sx,
double sy,
double sz);
118 void rotate(
const std::array<double, 3> &n0,
const std::array<double, 3> &n1,
double angle);
119 void rotate(
double n0x,
double n0y,
double n0z,
double n1x,
double n1y,
double n1z,
double angle);
120 void scale(
const std::array<double, 3> &scaling,
const std::array<double, 3> ¢er);
121 void scale(
double sx,
double sy,
double sz,
double cx,
double cy,
double cz);
123 BITPIT_PUBLIC_API
static const long NULL_ID;
127 void display(std::ostream &out,
unsigned short int indent)
const;
133 std::array<double, 3> m_coords;
137 void _initialize(
long id,
const std::array<double, 3> &coords,
bool interior);
The PatchKernel class provides an interface for defining patches.
Metafunction for generating a pierced vector.
The Vertex class defines the vertexs.
bool operator==(const Vertex &other) const
void setCoords(const std::array< double, 3 > &coords)
void translate(const std::array< double, 3 > &translation)
void display(std::ostream &out, unsigned short int indent) const
unsigned int getBinarySize() const
void initialize(long id, const std::array< double, 3 > &coords, bool interior)
void swap(Vertex &other) noexcept
void scale(const std::array< double, 3 > &scaling, const std::array< double, 3 > ¢er)
void setInterior(bool interior)
void rotate(const std::array< double, 3 > &n0, const std::array< double, 3 > &n1, double angle)
std::array< double, 3 > & getCoords()
double & operator[](int coord_id)
std::ostream & operator<<(std::ostream &, const std::vector< T > &)