Package Description

Latest prerelease 1.0.0-beta.7
Stable release none yet (prerelease only)
Downloads 1,925
Last published 2025-10-17
Target frameworks .NETStandard2.0

Install

dotnet add package TimeWarp.SourceGenerators --prerelease

NuGet ยท Source


Dotnet Stars Discord workflow nuget nuget Issues Open Forks License Twitter

Twitter Twitter

TimeWarp.SourceGenerators

TimeWarp Logo

TimeWarp.SourceGenerators is our collection of source generators.

Give a Star! :star:

If you like or are using this project please give it a star. Thank you!

Features

Interface Delegation Generator

Implements Delphi-style interface delegation for C#. Mark fields or properties with [Implements] to automatically generate forwarding methods for interface members.

Usage

public partial class DataService : ILogger, IDataProcessor<string>
{
    [Implements]
    private readonly ILogger Logger;

    [Implements]
    private readonly IDataProcessor<string> Processor;

    public DataService(ILogger logger, IDataProcessor<string> processor)
    {
        Logger = logger;
        Processor = processor;
    }

    // Optionally override specific methods
    public string Process(string input)
    {
        // Custom implementation
        return Processor.Process(input.ToUpper());
    }
}

The generator will automatically create forwarding implementations for all interface methods and properties, except those you explicitly implement.

Requirements

Diagnostics

File Name Rule Analyzer

Enforces kebab-case naming convention for C# files.

Configuration

Configure exceptions in .editorconfig:

[*.cs]
dotnet_diagnostic.TWA001.excluded_files = Program.cs;Startup.cs;*.Designer.cs

Getting started

To quickly get started I recommend reviewing the samples in this repo.

Installation

dotnet add package TimeWarp.SourceGenerators

You can see the latest NuGet packages from the official TimeWarp NuGet page.

Releases

See the Release Notes

Unlicense

License

Contributing

Time is of the essence. Before developing a Pull Request I recommend opening a discussion.

Please feel free to make suggestions and help out with the documentation. Please refer to Markdown for how to write markdown files.

Contact

Sometimes the github notifications get lost in the shuffle. If you file an issue and don't get a response in a timely manner feel free to ping on our Discord server.

Discord