C#
Build dependencies:
.NET 7 SDK
.NET 7 is needed only to build from source; the compiled binaries support at minimum .NET 5.
Build
Building TileDB-CSharp from source can be done using the following commands in a cloned repository.
As a final build step, we can verify our installation by running unit tests
Development
To help get started using TileDB-CSharp we can run the TileDB.CSharp.Example project:
After the TileDB.CSharp project is built and tests are passing we can make a new .NET project and add a reference to TileDB.CSharp, granting us access to the TileDB-CSharp API.
Resulting in TileDB-Project/ConsoleApp/ConsoleApp.csproj
generating the following configuration:
Using custom native libraries
The TileDB.CSharp
project uses the official native binaries from NuGet. You can during development provide your own native library for purposes like testing. To do that, you have to go to the Directory.Packages.props
file of your repository, and set the LocalLibraryFile
property to the path of your local native binary. This will bypass the standard acquisition mechanism and simply copy the libeary to your project's output directory.
The shipped TileDB.CSharp
NuGet package supports only the official native binaries at the moment. Please contact us or open a GitHub issue if you want to use TileDB from C# with custom native binaries.
Last updated