Xxfast.Kotlin.Native.Interop 0.9.0

dotnet add package Xxfast.Kotlin.Native.Interop --version 0.9.0
                    
NuGet\Install-Package Xxfast.Kotlin.Native.Interop -Version 0.9.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Xxfast.Kotlin.Native.Interop" Version="0.9.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Xxfast.Kotlin.Native.Interop" Version="0.9.0" />
                    
Directory.Packages.props
<PackageReference Include="Xxfast.Kotlin.Native.Interop" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Xxfast.Kotlin.Native.Interop --version 0.9.0
                    
#r "nuget: Xxfast.Kotlin.Native.Interop, 0.9.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Xxfast.Kotlin.Native.Interop@0.9.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Xxfast.Kotlin.Native.Interop&version=0.9.0
                    
Install as a Cake Addin
#tool nuget:?package=Xxfast.Kotlin.Native.Interop&version=0.9.0
                    
Install as a Cake Tool

Xxfast.Kotlin.Native.Interop

kotlin-native-nuget

Stability CI codecov NuGet

The shared types behind NuGet packages built from Kotlin/Native libraries with kotlin-native-nuget.

You don't reference this package yourself. Every package the plugin builds depends on it, so it arrives with the first Kotlin-built package you install. Because they all share this one assembly, an exception thrown by any of them is the same .NET type, whichever package it came from.

What's in it

All types live in the Kotlin.Native.Interop namespace.

  • KotlinException: a Kotlin exception with no closer .NET equivalent.
  • Mapped exceptions that keep their usual .NET base type, such as KotlinArgumentException (ArgumentException), KotlinInvalidOperationException (InvalidOperationException) and KotlinIOException (IOException).
  • IKotlinException: implemented by all of the above. It carries the Kotlin class name and the Kotlin stack trace.
  • KotlinOptional<T>: a parameter you can leave unset so Kotlin evaluates its default.
  • KotlinNothing: the C# spelling of Kotlin's Nothing as a type argument.

Catching a Kotlin exception

using Kotlin.Native.Interop;

try
{
    MappedExceptions.CheckOreoWeight(10);
}
catch (KotlinArgumentException ex)
{
    Console.WriteLine(ex.Message);
}

A mapped exception is also caught by its .NET base type, so catch (ArgumentException) works too.

Versioning

This package is released with the plugin, at the plugin's version. A package built by plugin X depends on this one from X up to the next major, so packages built by different plugin versions restore onto a single copy.

Product Compatible and additional computed target framework versions.
.NET net8.0 is compatible.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed.  net9.0 was computed.  net9.0-android was computed.  net9.0-browser was computed.  net9.0-ios was computed.  net9.0-maccatalyst was computed.  net9.0-macos was computed.  net9.0-tvos was computed.  net9.0-windows was computed.  net10.0 was computed.  net10.0-android was computed.  net10.0-browser was computed.  net10.0-ios was computed.  net10.0-maccatalyst was computed.  net10.0-macos was computed.  net10.0-tvos was computed.  net10.0-windows was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net8.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.9.0 101 10/5/2026