Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
O
ogs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Requirements
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Test cases
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
Insights
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Yuhao Liu
ogs
Commits
5f465a62
Commit
5f465a62
authored
9 years ago
by
Dmitry Yu. Naumov
Browse files
Options
Downloads
Patches
Plain Diff
[MeL] Add hasAnyInactive to ctor parameters.
Allows for delegating ctors. Make _hasAnyInactive a const member.
parent
b0d4cc69
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
MeshLib/ElementStatus.cpp
+4
-2
4 additions, 2 deletions
MeshLib/ElementStatus.cpp
MeshLib/ElementStatus.h
+3
-3
3 additions, 3 deletions
MeshLib/ElementStatus.h
with
7 additions
and
5 deletions
MeshLib/ElementStatus.cpp
+
4
−
2
View file @
5f465a62
...
...
@@ -20,8 +20,10 @@
namespace
MeshLib
{
ElementStatus
::
ElementStatus
(
Mesh
const
*
const
mesh
)
:
_mesh
(
mesh
),
_element_status
(
mesh
->
getNElements
(),
true
),
_hasAnyInactive
(
false
)
ElementStatus
::
ElementStatus
(
Mesh
const
*
const
mesh
,
bool
hasAnyInactive
)
:
_mesh
(
mesh
),
_element_status
(
mesh
->
getNElements
(),
true
),
_hasAnyInactive
(
hasAnyInactive
)
{
const
std
::
vector
<
MeshLib
::
Node
*>&
nodes
(
_mesh
->
getNodes
());
for
(
auto
node
:
nodes
)
...
...
This diff is collapsed.
Click to expand it.
MeshLib/ElementStatus.h
+
3
−
3
View file @
5f465a62
...
...
@@ -27,7 +27,8 @@ class ElementStatus
public:
/// Constructor assuming all nodes and elements
explicit
ElementStatus
(
MeshLib
::
Mesh
const
*
const
mesh
);
explicit
ElementStatus
(
MeshLib
::
Mesh
const
*
const
mesh
,
bool
hasAnyInactive
=
false
);
/// Constructor taking a vector of inactive material IDs
ElementStatus
(
MeshLib
::
Mesh
const
*
const
mesh
,
std
::
vector
<
unsigned
>
const
&
vec_inactive_matIDs
);
...
...
@@ -61,7 +62,7 @@ protected:
/// Node status for each mesh node (value = number of active elements connected to node, 0 means inactive)
std
::
vector
<
unsigned
char
>
_active_nodes
;
bool
_hasAnyInactive
;
bool
const
_hasAnyInactive
;
std
::
vector
<
MeshLib
::
Node
*>
_vec_active_nodes
;
std
::
vector
<
MeshLib
::
Element
*>
_vec_active_eles
;
...
...
@@ -70,4 +71,3 @@ protected:
}
/* namespace */
#endif
/* ELEMENTSTATUS_H_ */
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment