Only generate setters and getters for public properties (#47)

* Only generate setters and getters for public properties

* .
This commit is contained in:
Stef Heyenrath
2022-12-13 19:18:30 +01:00
committed by GitHub
parent 72a40e6f6a
commit d340c6af7c
10 changed files with 158 additions and 12 deletions
@@ -0,0 +1,28 @@
//----------------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by https://github.com/StefH/ProxyInterfaceSourceGenerator.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//----------------------------------------------------------------------------------------
#nullable enable
using System;
namespace ProxyInterfaceSourceGeneratorTests.Source
{
public partial interface IMixedVisibility
{
ProxyInterfaceSourceGeneratorTests.Source.MixedVisibility _Instance { get; }
string Foo { get; }
}
}
#nullable disable
@@ -0,0 +1,37 @@
//----------------------------------------------------------------------------------------
// <auto-generated>
// This code was generated by https://github.com/StefH/ProxyInterfaceSourceGenerator.
//
// Changes to this file may cause incorrect behavior and will be lost if
// the code is regenerated.
// </auto-generated>
//----------------------------------------------------------------------------------------
#nullable enable
using System;
namespace ProxyInterfaceSourceGeneratorTests.Source
{
public partial class MixedVisibilityProxy : IMixedVisibility
{
public ProxyInterfaceSourceGeneratorTests.Source.MixedVisibility _Instance { get; }
public string Foo { get => _Instance.Foo; }
public MixedVisibilityProxy(ProxyInterfaceSourceGeneratorTests.Source.MixedVisibility instance)
{
_Instance = instance;
}
}
}
#nullable disable