Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Docker-in-Docker (DinD) capabilities of public runners deactivated.
More info
Open sidebar
CTA-LAPP
PHOENIX_LIBS
PhoenixHDF5
Commits
9cd9377f
Commit
9cd9377f
authored
Nov 25, 2020
by
Pierre Aubert
Browse files
Add getter with const tensor pointer
parent
75b251f5
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
21 additions
and
1 deletion
+21
-1
src/BackEnd/backend.cpp
src/BackEnd/backend.cpp
+21
-1
No files found.
src/BackEnd/backend.cpp
View file @
9cd9377f
...
...
@@ -368,8 +368,15 @@ std::string ph5_backendTableSourceWrite(const PTable & table){
*/
std
::
string
ph5_backendTableSourceRowSetterGetter
(
const
PTable
&
table
){
std
::
string
body
(
""
),
name
(
table
.
getName
());
body
+=
"void "
+
name
+
"::setRow(size_t i"
;
const
PVecAttribute
&
vecAttriute
=
table
.
getVecAttribute
();
body
+=
"///Set a full row of the table "
+
name
+
"
\n
"
;
body
+=
"/**
\t
@param i : index of the row to be set
\n
"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
body
+=
" *
\t
@param "
+
it
->
getName
()
+
" : attribute to be set
\n
"
;
}
body
+=
"*/
\n
"
;
body
+=
"void "
+
name
+
"::setRow(size_t i"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
std
::
string
type
(
it
->
getType
());
body
+=
", "
+
type
+
" "
;
...
...
@@ -383,6 +390,13 @@ std::string ph5_backendTableSourceRowSetterGetter(const PTable & table){
body
+=
"
\t
set"
+
firstToUpper
(
it
->
getName
())
+
"(i, "
+
it
->
getName
()
+
");
\n
"
;
}
body
+=
"}
\n\n
"
;
body
+=
"///Get a full row of the table "
+
name
+
" (without tensor copy, only with pointer)
\n
"
;
body
+=
"/**
\t
@param i : index of the row to get its values
\n
"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
body
+=
" *
\t
@param[out] "
+
it
->
getName
()
+
" : attribute to be get
\n
"
;
}
body
+=
"*/
\n
"
;
body
+=
"void "
+
name
+
"::getRow(size_t i"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
std
::
string
type
(
it
->
getType
());
...
...
@@ -400,6 +414,12 @@ std::string ph5_backendTableSourceRowSetterGetter(const PTable & table){
}
body
+=
"}
\n\n
"
;
body
+=
"///Get a full row of the table "
+
name
+
" (without tensor copy, only with pointer)
\n
"
;
body
+=
"/**
\t
@param i : index of the row to get its values
\n
"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
body
+=
" *
\t
@param[out] "
+
it
->
getName
()
+
" : attribute to be get
\n
"
;
}
body
+=
"*/
\n
"
;
body
+=
"void "
+
name
+
"::getRow(size_t i"
;
for
(
PVecAttribute
::
const_iterator
it
(
vecAttriute
.
begin
());
it
!=
vecAttriute
.
end
();
++
it
){
std
::
string
type
(
it
->
getType
());
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment