Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
A
asapo
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
Package registry
Container registry
Model registry
Operate
Terraform modules
Analyze
Contributor 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
Joao Alvim Oliveira Dias De Almeida
asapo
Commits
0939603a
Commit
0939603a
authored
3 years ago
by
Juergen Hannappel
Committed by
Juergen Hannappel
3 years ago
Browse files
Options
Downloads
Patches
Plain Diff
new header and glue code for C api
parent
eaef4d28
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
consumer/api/c/include/asapo/consumer_c.h
+24
-0
24 additions, 0 deletions
consumer/api/c/include/asapo/consumer_c.h
consumer/api/c/src/consumer_c_glue.cpp
+20
-0
20 additions, 0 deletions
consumer/api/c/src/consumer_c_glue.cpp
with
44 additions
and
0 deletions
consumer/api/c/include/asapo/consumer_c.h
0 → 100644
+
24
−
0
View file @
0939603a
#ifndef __CONSUMER_C_H__
#define __CONSUMER_C_H__
#ifndef __CONSUMER_C_INTERFACE_IMPLEMENTATION__
typedef
void
*
asapoConsumer
;
typedef
void
*
asapoSourceCredentials
;
typedef
void
*
asapoError
;
struct
asapoErrorBuffer
{
asapoError
error
;
};
typedef
void
*
asapoMessageMeta
;
typedef
void
*
asapoMessageData
;
#endif
asapoConsumer
asapoCreateConsumer
(
const
char
*
server_name
,
const
char
*
source_path
,
_Bool
has_filesysytem
,
asapoSourceCredentials
source
,
asapoErrorBuffer
*
error
);
asapoMessageMeta
asapoCreateMessageMeta
();
void
asapoDeleteMessageMeta
(
asapoMessageMeta
*
meta
);
#endif
This diff is collapsed.
Click to expand it.
consumer/api/c/src/consumer_c_glue.cpp
0 → 100644
+
20
−
0
View file @
0939603a
#define __CONSUMER_C_INTERFACE_IMPLEMENTATION__
#include
<consumer.h>
typedef
asapo
::
Consumer
*
asapoConsumer
;
#include
"consumer_c.h"
extern
c
{
asapoConsumer
asapoCreateConsumer
(
const
char
*
server_name
,
const
char
*
source_path
,
_Bool
has_filesysytem
,
asapoSourceCredentials
source
,
asapoErrorBuffer
*
error
)
{
auto
c
=
asapo
::
ConsumerFactory
::
CreateConsumer
(
server_name
,
source_path
,
has_filesysytem
,
source_path
,
&
(
error
->
error
));
return
c
.
release
()
:
}
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