IceRpc.Ice
0.6.0
Prefix Reserved
dotnet add package IceRpc.Ice --version 0.6.0
NuGet\Install-Package IceRpc.Ice -Version 0.6.0
<PackageReference Include="IceRpc.Ice" Version="0.6.0" />
<PackageVersion Include="IceRpc.Ice" Version="0.6.0" />
<PackageReference Include="IceRpc.Ice" />
paket add IceRpc.Ice --version 0.6.0
#r "nuget: IceRpc.Ice, 0.6.0"
#:package IceRpc.Ice@0.6.0
#addin nuget:?package=IceRpc.Ice&version=0.6.0
#tool nuget:?package=IceRpc.Ice&version=0.6.0
IceRPC + Ice integration
The IceRPC framework provides extensive interop support for the Ice RPC framework through:
- an implementation of the ice protocol, provided by the IceRpc NuGet package
- integration code between the IceRPC core APIs and code generated by Ice's Slice compiler (this package)
With IceRPC, you can use the ice and icerpc protocols to send requests and responses with payloads encoded in
the serialization format of your choice. You typically use Ice's IDL (Ice Slice) and its associated encoding (the Ice
encoding) with the ice protocol, to communicate with Ice-based applications. Nevertheless, this package is
protocol-agnostic, and allows you to use Ice Slice and the Ice encoding with the icerpc protocol as well.
Package | Source code | Documentation | Examples | API reference
Sample Code
// Contract written in Ice's Slice language and saved in a `.ice` file.
module VisitorCenter
{
/// Represents a simple greeter.
interface Greeter
{
/// Creates a personalized greeting.
/// @param name The name of the person to greet.
/// @return The greeting.
string greet(string name);
}
}
// Client application
using IceRpc;
using VisitorCenter;
// Use the ice protocol for compatibility with ZeroC Ice. We use the default port for the
// ice protocol, 4061.
await using var connection = new ClientConnection(new Uri("ice://localhost"));
// The service address URI includes the protocol to use (ice).
var greeter = new GreeterProxy(connection, new Uri("ice:/greeter"));
string greeting = await greeter.GreetAsync(Environment.UserName);
Console.WriteLine(greeting);
await connection.ShutdownAsync();
// Server application
using IceRpc;
using IceRpc.Features;
using VisitorCenter;
// Use the ice protocol for compatibility with ZeroC Ice.
await using var server = new Server(new Chatbot(), new Uri("ice://[::0]"));
// Start accepting requests on the default port for the ice protocol, 4061.
server.Listen();
// Wait until the console receives a Ctrl+C.
await CancelKeyPressed;
await server.ShutdownAsync();
// IGreeterService is an interface generated by slice2cs (Ice's Slice compiler for C#).
// The [Service] attribute instructs the Service Generator to implement IDispatcher by
// routing "greet" requests to the GreetAsync method.
[Service]
internal partial class Chatbot : IGreeterService
{
public ValueTask<string> GreetAsync(
string name,
IFeatureCollection features,
CancellationToken cancellationToken)
{
Console.WriteLine($"Dispatching greet request {{ name = '{name}' }}");
return new($"Hello, {name}!");
}
}
| Product | Versions Compatible and additional computed target framework versions. |
|---|---|
| .NET | net10.0 is compatible. 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. |
-
net10.0
- dunet (>= 1.16.2)
- IceRpc (= 0.6.0)
- IceRpc.ServiceGenerator (= 0.6.0)
- Microsoft.Extensions.DependencyInjection.Abstractions (>= 10.0.8)
- Microsoft.Extensions.Logging.Abstractions (>= 10.0.8)
NuGet packages (1)
Showing the top 1 NuGet packages that depend on IceRpc.Ice:
| Package | Downloads |
|---|---|
|
IceRpc.Locator
Locator interceptor for IceRPC |
GitHub repositories
This package is not used by any popular GitHub repositories.
| Version | Downloads | Last Updated |
|---|---|---|
| 0.6.0 | 36 | 6/5/2026 |