AutoInterface 1.2.1
There is a newer version of this package available.
See the version list below for details.
See the version list below for details.
dotnet add package AutoInterface --version 1.2.1
NuGet\Install-Package AutoInterface -Version 1.2.1
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="AutoInterface" Version="1.2.1"> <PrivateAssets>all</PrivateAssets> <IncludeAssets>runtime; build; native; contentfiles; analyzers</IncludeAssets> </PackageReference>
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add AutoInterface --version 1.2.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
#r "nuget: AutoInterface, 1.2.1"
#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.
// Install AutoInterface as a Cake Addin #addin nuget:?package=AutoInterface&version=1.2.1 // Install AutoInterface as a Cake Tool #tool nuget:?package=AutoInterface&version=1.2.1
The NuGet Team does not provide support for this client. Please contact its maintainers for support.
AutoInterface
AutoInterface is a source generator that generates an interface based on your class/struct.
Basically, you write your class and get the corresponding interface for free.
using AutoInterfaceAttributes;
[AutoInterface]
public class Example : IExample {
public int Number { get; private set; }
public Example() {
ResetNumber();
}
/// <summary>
/// some method description
/// </summary>
public int AddToNumber(int increase) {
Number += increase;
return Number;
}
private void ResetNumber() => Number = 0;
}
// <auto-generated>
#pragma warning disable
#nullable enable annotations
using AutoInterfaceAttributes;
public interface IExample {
int Number { get; }
/// <summary>
/// some method description
/// </summary>
int AddToNumber(int increase);
}
AutoInterface supports:
- classes and structs
- all members (Method, Property, Indexer, Event)
- also explicit Interface members
- summary of class/struct and members
- generic
- parameters for
- interface name
- interface modifier
- interface namespace
- interface inheritance
- static members as static abstract
- ignore specific members
For documentation or sourcecode see github.com/BlackWhiteYoshi/AutoInterface.
There are no supported framework assets in this package.
Learn more about Target Frameworks and .NET Standard.
This package has no dependencies.
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories (1)
Showing the top 1 popular GitHub repositories that depend on AutoInterface:
Repository | Stars |
---|---|
MeltyPlayer/FinModelUtility
Model viewer and command-line tools for extracting models from various GCN/3DS/PC games en-masse.
|
Version | Downloads | Last updated |
---|---|---|
2.4.0 | 871 | 8/19/2024 |
2.3.0 | 3,286 | 4/14/2024 |
2.2.1 | 186 | 4/11/2024 |
2.2.0 | 396 | 4/6/2024 |
2.1.0 | 1,047 | 3/2/2024 |
2.0.2 | 165 | 3/2/2024 |
2.0.1 | 232 | 3/1/2024 |
2.0.0 | 196 | 3/1/2024 |
1.3.0 | 481 | 2/4/2024 |
1.2.6 | 592 | 1/6/2024 |
1.2.5 | 191 | 1/6/2024 |
1.2.4 | 293 | 11/16/2023 |
1.2.3 | 234 | 9/19/2023 |
1.2.2 | 195 | 7/7/2023 |
1.2.1 | 190 | 7/2/2023 |
1.2.0 | 193 | 7/1/2023 |
1.1.0 | 213 | 6/30/2023 |
1.0.1 | 184 | 6/30/2023 |
1.0.0 | 190 | 6/30/2023 |