Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add C API bindings #1471

Merged
merged 1 commit into from
Apr 20, 2023
Merged

Add C API bindings #1471

merged 1 commit into from
Apr 20, 2023

Conversation

mewim
Copy link
Collaborator

@mewim mewim commented Apr 17, 2023

This PR adds C API bindings. The C API binding shares the same so/dylib file with the C++ library but uses a C header file with opaque pointer pattern. The PR also modifies the release build pipeline to bundle the C header file. The build process has been tested on https://github.com/kuzudb/kuzu/actions/runs/4747264688 and https://github.com/kuzudb/kuzu/actions/runs/4747263697. The generated lib has been tested on both Linux and macOS.

@mewim mewim force-pushed the c-api branch 2 times, most recently from f068f07 to dac5477 Compare April 19, 2023 07:00
@mewim mewim changed the title [WIP] C api [WIP] Add C API bindings Apr 19, 2023
@codecov
Copy link

codecov bot commented Apr 19, 2023

Codecov Report

Patch coverage: 99.44% and project coverage change: +0.32 🎉

Comparison is base (a5e9793) 91.83% compared to head (1f17925) 92.15%.

Additional details and impacted files
@@            Coverage Diff             @@
##           master    #1471      +/-   ##
==========================================
+ Coverage   91.83%   92.15%   +0.32%     
==========================================
  Files         661      669       +8     
  Lines       23142    23676     +534     
==========================================
+ Hits        21252    21819     +567     
+ Misses       1890     1857      -33     
Impacted Files Coverage Δ
src/include/main/connection.h 100.00% <ø> (ø)
src/main/connection.cpp 93.41% <ø> (+2.25%) ⬆️
src/main/database.cpp 100.00% <ø> (+0.83%) ⬆️
src/c_api/connection.cpp 96.10% <96.10%> (ø)
src/c_api/data_type.cpp 100.00% <100.00%> (ø)
src/c_api/database.cpp 100.00% <100.00%> (ø)
src/c_api/flat_tuple.cpp 100.00% <100.00%> (ø)
src/c_api/prepared_statement.cpp 100.00% <100.00%> (ø)
src/c_api/query_result.cpp 100.00% <100.00%> (ø)
src/c_api/query_summary.cpp 100.00% <100.00%> (ø)
... and 1 more

... and 8 files with indirect coverage changes

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

@mewim mewim changed the title [WIP] Add C API bindings Add C API bindings Apr 19, 2023
@mewim mewim marked this pull request as ready for review April 19, 2023 19:25
@mewim mewim requested a review from ray6080 April 19, 2023 19:26
Copy link
Contributor

@ray6080 ray6080 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice PR!

src/include/c_api/kuzu.h Show resolved Hide resolved
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants