Skip to content
GitLab
Explore
Sign in
Register
Primary navigation
Search or go to…
Project
C
CaosDB Octave library
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Iterations
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Locked files
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Package Registry
Container Registry
Model registry
Operate
Environments
Terraform modules
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Code review analytics
Issue analytics
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
caosdb
Software
CaosDB Octave library
Commits
70aa4c4e
Commit
70aa4c4e
authored
3 years ago
by
Daniel Hornung
Browse files
Options
Downloads
Patches
Plain Diff
MAINT: Removed old info() function that was never used.
parent
6f5af439
No related branches found
No related tags found
1 merge request
!2
ENH: Retrieving single entities works on the mex side.
Pipeline
#11884
passed with warnings
3 years ago
Stage: setup
Stage: test
Stage: deploy
Pipeline: caosdb-octaveinttest
#11887
Changes
2
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/private/maox_query.cpp
+0
-26
0 additions, 26 deletions
src/private/maox_query.cpp
src/private/maox_retrieve.cpp
+0
-27
0 additions, 27 deletions
src/private/maox_retrieve.cpp
with
0 additions
and
53 deletions
src/private/maox_query.cpp
+
0
−
26
View file @
70aa4c4e
...
...
@@ -14,32 +14,6 @@ using caosdb::transaction::Transaction;
using
caosdb
::
transaction
::
TransactionStatus
;
using
std
::
string
;
auto
info
(
const
string
&
connection_name
)
->
mxArray
*
;
/**
* The implementation of the info retrieval.
*/
auto
info
(
string
const
&
connection_name
)
->
mxArray
*
{
std
::
shared_ptr
<
Connection
>
connection
=
nullptr
;
if
(
connection_name
.
empty
())
{
connection
=
ConnectionManager
::
GetDefaultConnection
();
}
else
{
connection
=
ConnectionManager
::
GetConnection
(
connection_name
);
}
const
auto
&
version_info
=
connection
->
RetrieveVersionInfo
();
const
char
*
keys
[]
=
{
"major"
,
"minor"
,
"patch"
,
"pre_release"
,
// NOLINT
"build"
};
std
::
array
<
mwSize
,
2
>
dims
=
{
1
,
1
};
mxArray
*
info_struct
=
mxCreateStructArray
(
2
,
dims
.
data
(),
5
,
keys
);
// NOLINT
mxSetField
(
info_struct
,
0
,
"major"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetMajor
()));
mxSetField
(
info_struct
,
0
,
"minor"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetMinor
()));
mxSetField
(
info_struct
,
0
,
"patch"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetPatch
()));
mxSetField
(
info_struct
,
0
,
"pre_release"
,
mxCreateString
(
version_info
.
GetPreRelease
().
c_str
()));
mxSetField
(
info_struct
,
0
,
"build"
,
mxCreateString
(
version_info
.
GetBuild
().
c_str
()));
return
info_struct
;
}
/**
* @brief Execute a query.
*
...
...
This diff is collapsed.
Click to expand it.
src/private/maox_retrieve.cpp
+
0
−
27
View file @
70aa4c4e
#include
"caosdb/connection.h"
// for Connection, ConnectionManager
#include
"caosdb/constants.h"
// for LIBCAOSDB_VERSION_MAJOR, LIBCAOSDB_VE...
#include
"caosdb/exceptions.h"
// for all error handling
#include
"caosdb/info.h"
// for VersionInfo
#include
"maoxdb.hpp"
// caosDB utils for mex files
#include
"mex.h"
// for mxArray, mexFunction
#include
<cstring>
// for strcmp
...
...
@@ -14,32 +13,6 @@ using caosdb::transaction::Transaction;
using
caosdb
::
transaction
::
TransactionStatus
;
using
std
::
string
;
auto
info
(
const
string
&
connection_name
)
->
mxArray
*
;
/**
* The implementation of the info retrieval.
*/
auto
info
(
string
const
&
connection_name
)
->
mxArray
*
{
std
::
shared_ptr
<
Connection
>
connection
=
nullptr
;
if
(
connection_name
.
empty
())
{
connection
=
ConnectionManager
::
GetDefaultConnection
();
}
else
{
connection
=
ConnectionManager
::
GetConnection
(
connection_name
);
}
const
auto
&
version_info
=
connection
->
RetrieveVersionInfo
();
const
char
*
keys
[]
=
{
"major"
,
"minor"
,
"patch"
,
"pre_release"
,
// NOLINT
"build"
};
std
::
array
<
mwSize
,
2
>
dims
=
{
1
,
1
};
mxArray
*
info_struct
=
mxCreateStructArray
(
2
,
dims
.
data
(),
5
,
keys
);
// NOLINT
mxSetField
(
info_struct
,
0
,
"major"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetMajor
()));
mxSetField
(
info_struct
,
0
,
"minor"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetMinor
()));
mxSetField
(
info_struct
,
0
,
"patch"
,
maoxdb
::
mxScalarUINT64
(
version_info
.
GetPatch
()));
mxSetField
(
info_struct
,
0
,
"pre_release"
,
mxCreateString
(
version_info
.
GetPreRelease
().
c_str
()));
mxSetField
(
info_struct
,
0
,
"build"
,
mxCreateString
(
version_info
.
GetBuild
().
c_str
()));
return
info_struct
;
}
/**
* @brief Retrieve one or more entities.
*
...
...
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