Dune Core Modules (unstable)

vertex.hh
1// SPDX-FileCopyrightText: Copyright © DUNE Project contributors, see file LICENSE.md in module root
2// SPDX-License-Identifier: LicenseRef-GPL-2.0-only-with-DUNE-exception
3// -*- tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*-
4// vi: set et ts=4 sw=2 sts=2:
5#ifndef DUNE_DGF_VERTEXBLOCK_HH
6#define DUNE_DGF_VERTEXBLOCK_HH
7
8#include <iostream>
9#include <vector>
10
11#include <dune/grid/io/file/dgfparser/blocks/basic.hh>
12
13namespace Dune
14{
15
16 namespace dgf
17 {
18
19 class VertexBlock
20 : public BasicBlock
21 {
22 int dimvertex; // the dimension of the vertices (determined from DGF file)
23 int dimworld; // the dimension of the world (either dimvertex or given by user)
24 bool goodline; // active line describes a vertex
25 int vtxoffset;
26 int nofParam;
27
28 public:
29 // initialize vertex block
30 VertexBlock ( std :: istream &in, int &pdimworld );
31
32 int get ( std :: vector< std :: vector< double > > &vtx,
33 std :: vector< std :: vector< double > > &param,
34 int &nofp );
35
36 // some information
37 bool ok () const
38 {
39 return goodline;
40 }
41
42 int offset () const
43 {
44 return vtxoffset;
45 }
46
47 private:
48 // get dimworld
49 int getDimWorld ();
50
51 // get next vertex
52 bool next ( std :: vector< double > &point, std :: vector< double > &param );
53 };
54
55 } // end namespace dgf
56
57} // end namespace Dune
58
59#endif
Dune namespace.
Definition: alignedallocator.hh:13
constexpr auto get(std::integer_sequence< T, II... >, std::integral_constant< std::size_t, pos >={})
Return the entry at position pos of the given sequence.
Definition: integersequence.hh:22
Creative Commons License   |  Legal Statements / Impressum  |  Hosted by TU Dresden  |  generated with Hugo v0.111.3 (Dec 22, 23:30, 2024)