Home
Downloads
Documentation
Installation
User Guide
man-pages
API Documentation
README
Release Notes
Changes
License
Support
SourceForge Project
Main Page
Related Pages
Namespaces
Classes
Files
File List
File Members
All
Classes
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Pages
src
surfMesh
surfaceFormats
tri
TRIsurfaceFormatCore.H
Go to the documentation of this file.
1
/*---------------------------------------------------------------------------*\
2
========= |
3
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
4
\\ / O peration |
5
\\ / A nd | Copyright (C) 1991-2010 OpenCFD Ltd.
6
\\/ M anipulation |
7
-------------------------------------------------------------------------------
8
License
9
This file is part of OpenFOAM.
10
11
OpenFOAM is free software: you can redistribute it and/or modify it
12
under the terms of the GNU General Public License as published by
13
the Free Software Foundation, either version 3 of the License, or
14
(at your option) any later version.
15
16
OpenFOAM is distributed in the hope that it will be useful, but WITHOUT
17
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
18
FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
19
for more details.
20
21
You should have received a copy of the GNU General Public License
22
along with OpenFOAM. If not, see <http://www.gnu.org/licenses/>.
23
24
Class
25
Foam::fileFormats::TRIsurfaceFormatCore
26
27
Description
28
Internal class used by the TRIsurfaceFormat
29
30
SourceFiles
31
TRIsurfaceFormatCore.C
32
33
\*---------------------------------------------------------------------------*/
34
35
#ifndef TRIsurfaceFormatCore_H
36
#define TRIsurfaceFormatCore_H
37
38
#include <
surfMesh/surfaceFormatsCore.H
>
39
#include <
OpenFOAM/triFace.H
>
40
41
#include <
OpenFOAM/IFstream.H
>
42
#include <
OpenFOAM/Ostream.H
>
43
#include <
OpenFOAM/OFstream.H
>
44
45
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
46
47
namespace
Foam
48
{
49
namespace
fileFormats
50
{
51
52
/*---------------------------------------------------------------------------*\
53
Class TRIsurfaceFormatCore Declaration
54
\*---------------------------------------------------------------------------*/
55
56
class
TRIsurfaceFormatCore
57
:
58
public
surfaceFormatsCore
59
{
60
// Private Data
61
62
bool
sorted_;
63
64
//- The points supporting the facets
65
pointField
points_;
66
67
//- The zones associated with the faces
68
List<label>
zoneIds_;
69
70
//- The solid count, in the order of their first appearance
71
List<label>
sizes_;
72
73
74
// Private Member Functions
75
76
//- Disallow default bitwise copy construct
77
TRIsurfaceFormatCore
(
const
TRIsurfaceFormatCore
&);
78
79
//- Disallow default bitwise assignment
80
void
operator=(
const
TRIsurfaceFormatCore
&);
81
82
bool
read(
const
fileName
&);
83
84
85
public
:
86
87
// Constructors
88
89
//- Read from file, filling in the information
90
TRIsurfaceFormatCore
(
const
fileName
&);
91
92
93
// Destructor
94
95
~TRIsurfaceFormatCore
();
96
97
98
// Member Functions
99
100
//- File read was already sorted
101
bool
sorted
()
const
102
{
103
return
sorted_;
104
}
105
106
//- Flush all values
107
void
clear
()
108
{
109
sorted_ =
true
;
110
points_.
clear
();
111
zoneIds_.
clear
();
112
sizes_.
clear
();
113
}
114
115
//- Return full access to the points
116
pointField
&
points
()
117
{
118
return
points_;
119
}
120
121
//- Return full access to the zones
122
List<label>
&
zoneIds
()
123
{
124
return
zoneIds_;
125
}
126
127
//- The list of zone sizes in the order of their first appearance
128
List<label>
&
sizes
()
129
{
130
return
sizes_;
131
}
132
};
133
134
135
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
136
137
}
// End namespace fileFormats
138
}
// End namespace Foam
139
140
// * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * //
141
142
#endif
143
144
// ************************ vim: set sw=4 sts=4 et: ************************ //