DouglasDwyer.Imp 1.0.0.1

Imp.NET is a fast, high-level, object-oriented C# networking library that supports the invocation of remote methods through proxy interface objects.

Install-Package DouglasDwyer.Imp -Version 1.0.0.1
dotnet add package DouglasDwyer.Imp --version 1.0.0.1
<PackageReference Include="DouglasDwyer.Imp" Version="1.0.0.1" />
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add DouglasDwyer.Imp --version 1.0.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: DouglasDwyer.Imp, 1.0.0.1"
#r directive can be used in F# Interactive, C# scripting and .NET Interactive. Copy this into the interactive tool or source code of the script to reference the package.
// Install DouglasDwyer.Imp as a Cake Addin
#addin nuget:?package=DouglasDwyer.Imp&version=1.0.0.1

// Install DouglasDwyer.Imp as a Cake Tool
#tool nuget:?package=DouglasDwyer.Imp&version=1.0.0.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.

Nuget
Downloads

Imp.NET

Imp.NET is a fast, high-level, object-oriented C# networking library that supports the invocation of remote methods through proxy interface objects. Imp.NET combines the power of the System.Reflection.Emit namespace with the flexibility of source generators to provide a seamless networking experience, without the hassle of network streams or pesky sockets. With Imp.NET, one writes networked code that looks identical to fully local code. Its fast and powerful features make it the perfect choice for any C# application.

Imp.NET may optionally be used without its source generator.

Features

With Imp.NET, you can:

  • Write networked code with remote method calls that looks exactly like normal/local code
  • Send shared objects as method arguments across the network via interfaces, and remotely invoke methods/properties on them as though they are local objects
  • Send non-shared objects as method arguments across the network by value using a serializer
  • Pass any class that inherits from an interface, including library classes, across the network as a shared interface
  • Call remote methods synchronously or asynchronously with the use of Tasks and the await keyword
  • Use UDP and the Unreliable attribute to send data across the network with less overhead

Installation

Imp.NET can be obtained as a Nuget package. To import it into your project, either download DouglasDwyer.Imp from the Visual Studio package manager or run the command Install-Package DouglasDwyer.Imp using the package manager console.

Getting started

Please see the documentation for a complete guide on setting up an Imp.NET application.

Example

Imp.NET abstracts away the details of networking by automatically generating remote proxy classes that inherit from shared interfaces. In the following client-side example, a client connects to a server, then gets a remote representation of the server object, which is of the user-defined type IChatServer. Then, the client repeatedly sends messages read from the console to the server. Despite the fact that the code is executing client-side, the call to SendMessage executes on the server, as the server variable is a remote/server-owned object:

ChatClient client = new ChatClient();
client.Connect("127.0.0.1", 10);

IChatServer server = client.Server;
while(true)
{
    server.SendMessage(Console.ReadLine());
}

Thus, Imp.NET provides an incredibly simple way for clients and servers to interact. The user can define custom "shared" properties and methods. These members may then be accessed remotely, as though they existed in the local runtime.

Nuget
Downloads

Imp.NET

Imp.NET is a fast, high-level, object-oriented C# networking library that supports the invocation of remote methods through proxy interface objects. Imp.NET combines the power of the System.Reflection.Emit namespace with the flexibility of source generators to provide a seamless networking experience, without the hassle of network streams or pesky sockets. With Imp.NET, one writes networked code that looks identical to fully local code. Its fast and powerful features make it the perfect choice for any C# application.

Imp.NET may optionally be used without its source generator.

Features

With Imp.NET, you can:

  • Write networked code with remote method calls that looks exactly like normal/local code
  • Send shared objects as method arguments across the network via interfaces, and remotely invoke methods/properties on them as though they are local objects
  • Send non-shared objects as method arguments across the network by value using a serializer
  • Pass any class that inherits from an interface, including library classes, across the network as a shared interface
  • Call remote methods synchronously or asynchronously with the use of Tasks and the await keyword
  • Use UDP and the Unreliable attribute to send data across the network with less overhead

Installation

Imp.NET can be obtained as a Nuget package. To import it into your project, either download DouglasDwyer.Imp from the Visual Studio package manager or run the command Install-Package DouglasDwyer.Imp using the package manager console.

Getting started

Please see the documentation for a complete guide on setting up an Imp.NET application.

Example

Imp.NET abstracts away the details of networking by automatically generating remote proxy classes that inherit from shared interfaces. In the following client-side example, a client connects to a server, then gets a remote representation of the server object, which is of the user-defined type IChatServer. Then, the client repeatedly sends messages read from the console to the server. Despite the fact that the code is executing client-side, the call to SendMessage executes on the server, as the server variable is a remote/server-owned object:

ChatClient client = new ChatClient();
client.Connect("127.0.0.1", 10);

IChatServer server = client.Server;
while(true)
{
    server.SendMessage(Console.ReadLine());
}

Thus, Imp.NET provides an incredibly simple way for clients and servers to interact. The user can define custom "shared" properties and methods. These members may then be accessed remotely, as though they existed in the local runtime.

Release Notes

Fixed documentation for release

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version History

Version Downloads Last updated
1.0.0.1 87 3/21/2021
1.0.0 42 3/21/2021