Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
pugs
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
GitLab community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
code
pugs
Commits
75ecd2e5
Commit
75ecd2e5
authored
Mar 29, 2022
by
Stéphane Del Pino
Browse files
Options
Downloads
Patches
Plain Diff
Cosmetic clean-up
parent
4ae247d5
No related branches found
No related tags found
1 merge request
!136
Displace NamedBoundaryDescriptor and NumberedBoundaryDescriptor
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
src/mesh/IBoundaryDescriptor.hpp
+10
-7
10 additions, 7 deletions
src/mesh/IBoundaryDescriptor.hpp
src/mesh/NamedBoundaryDescriptor.hpp
+4
-7
4 additions, 7 deletions
src/mesh/NamedBoundaryDescriptor.hpp
src/mesh/NumberedBoundaryDescriptor.hpp
+3
-3
3 additions, 3 deletions
src/mesh/NumberedBoundaryDescriptor.hpp
with
17 additions
and
17 deletions
src/mesh/IBoundaryDescriptor.hpp
+
10
−
7
View file @
75ecd2e5
...
...
@@ -19,18 +19,20 @@ class IBoundaryDescriptor
public
:
friend
std
::
ostream
&
operator
<<
(
std
::
ostream
&
os
,
const
IBoundaryDescriptor
&
b
d
)
operator
<<
(
std
::
ostream
&
os
,
const
IBoundaryDescriptor
&
b
oundary_descriptor
)
{
return
b
d
.
_write
(
os
);
return
b
oundary_descriptor
.
_write
(
os
);
}
virtual
bool
operator
==
(
const
RefId
&
ref_id
)
const
=
0
;
friend
bool
operator
==
(
const
RefId
&
ref_id
,
const
IBoundaryDescriptor
&
bcd
)
[[
nodiscard
]]
virtual
bool
operator
==
(
const
RefId
&
ref_id
)
const
=
0
;
[[
nodiscard
]]
friend
bool
operator
==
(
const
RefId
&
ref_id
,
const
IBoundaryDescriptor
&
boundary_descriptor
)
{
return
b
cd
==
ref_id
;
return
b
oundary_descriptor
==
ref_id
;
}
virtual
Type
type
()
const
=
0
;
[[
nodiscard
]]
virtual
Type
type
()
const
=
0
;
IBoundaryDescriptor
(
const
IBoundaryDescriptor
&
)
=
delete
;
IBoundaryDescriptor
(
IBoundaryDescriptor
&&
)
=
delete
;
...
...
@@ -38,4 +40,5 @@ class IBoundaryDescriptor
virtual
~
IBoundaryDescriptor
()
=
default
;
};
#endif // I_BOUNDARY_DESCRIPTOR_HPP
This diff is collapsed.
Click to expand it.
src/mesh/NamedBoundaryDescriptor.hpp
+
4
−
7
View file @
75ecd2e5
...
...
@@ -6,7 +6,7 @@
#include
<iostream>
#include
<string>
class
NamedBoundaryDescriptor
:
public
IBoundaryDescriptor
class
NamedBoundaryDescriptor
final
:
public
IBoundaryDescriptor
{
private:
std
::
string
m_name
;
...
...
@@ -19,13 +19,13 @@ class NamedBoundaryDescriptor : public IBoundaryDescriptor
}
public
:
bool
[[
nodiscard
]]
bool
operator
==
(
const
RefId
&
ref_id
)
const
final
{
return
m_name
==
ref_id
.
tagName
();
}
Type
[[
nodiscard
]]
Type
type
()
const
final
{
return
Type
::
named
;
...
...
@@ -33,10 +33,7 @@ class NamedBoundaryDescriptor : public IBoundaryDescriptor
NamedBoundaryDescriptor
(
const
NamedBoundaryDescriptor
&
)
=
delete
;
NamedBoundaryDescriptor
(
NamedBoundaryDescriptor
&&
)
=
delete
;
NamedBoundaryDescriptor
(
const
std
::
string
&
name
)
:
m_name
(
name
)
{
;
}
NamedBoundaryDescriptor
(
const
std
::
string
&
name
)
:
m_name
(
name
)
{}
virtual
~
NamedBoundaryDescriptor
()
=
default
;
};
...
...
This diff is collapsed.
Click to expand it.
src/mesh/NumberedBoundaryDescriptor.hpp
+
3
−
3
View file @
75ecd2e5
...
...
@@ -5,7 +5,7 @@
#include
<iostream>
class
NumberedBoundaryDescriptor
:
public
IBoundaryDescriptor
class
NumberedBoundaryDescriptor
final
:
public
IBoundaryDescriptor
{
private:
unsigned
int
m_number
;
...
...
@@ -17,14 +17,14 @@ class NumberedBoundaryDescriptor : public IBoundaryDescriptor
return
os
;
}
bool
[[
nodiscard
]]
bool
operator
==
(
const
RefId
&
ref_id
)
const
final
{
return
m_number
==
ref_id
.
tagNumber
();
}
public
:
Type
[[
nodiscard
]]
Type
type
()
const
final
{
return
Type
::
numbered
;
...
...
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