Add ProxyInterfaceConsumerViaNuGet project
This commit is contained in:
@@ -0,0 +1,6 @@
|
||||
namespace ProxyInterfaceConsumer
|
||||
{
|
||||
public interface IMyInterface
|
||||
{
|
||||
}
|
||||
}
|
||||
@@ -1,5 +1,4 @@
|
||||
using System.Collections.Generic;
|
||||
using Microsoft.CodeAnalysis;
|
||||
|
||||
namespace ProxyInterfaceConsumer
|
||||
{
|
||||
@@ -20,6 +19,8 @@ namespace ProxyInterfaceConsumer
|
||||
|
||||
public E E { get; set; }
|
||||
|
||||
public IMyInterface MyInterface { get; set; }
|
||||
|
||||
public int Add(string s)
|
||||
{
|
||||
return 600;
|
||||
@@ -32,12 +33,7 @@ namespace ProxyInterfaceConsumer
|
||||
|
||||
public void Void()
|
||||
{
|
||||
//
|
||||
}
|
||||
|
||||
public Compilation Compilation { get; set; }
|
||||
|
||||
public INamedTypeSymbol MyNamedTypeSymbol { get; set; }
|
||||
}
|
||||
|
||||
public enum E
|
||||
|
||||
@@ -1,11 +1,17 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Text.Json;
|
||||
using AutoMapper;
|
||||
|
||||
namespace ProxyInterfaceConsumer
|
||||
{
|
||||
public class Program
|
||||
{
|
||||
private static JsonSerializerOptions JsonSerializerOptions = new ()
|
||||
{
|
||||
WriteIndented = true
|
||||
};
|
||||
|
||||
public static void Main()
|
||||
{
|
||||
var c = new Clazz
|
||||
@@ -20,7 +26,7 @@ namespace ProxyInterfaceConsumer
|
||||
var tp = new TestProxy(t);
|
||||
tp.Cs = new List<IClazz> { cp };
|
||||
|
||||
Console.WriteLine(System.Text.Json.JsonSerializer.Serialize(t));
|
||||
Console.WriteLine(JsonSerializer.Serialize(t, JsonSerializerOptions));
|
||||
Console.WriteLine(new string('-', 80));
|
||||
|
||||
|
||||
@@ -35,7 +41,7 @@ namespace ProxyInterfaceConsumer
|
||||
//p.Compilation = null;
|
||||
//p.Add("x");
|
||||
//p.Void();
|
||||
Console.WriteLine(System.Text.Json.JsonSerializer.Serialize(p));
|
||||
Console.WriteLine(JsonSerializer.Serialize(p, JsonSerializerOptions));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -7,13 +7,12 @@
|
||||
|
||||
<ItemGroup>
|
||||
<PackageReference Include="AutoMapper" Version="10.1.1" />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.Analyzers" Version="3.3.2">
|
||||
<!--<PackageReference Include="Microsoft.CodeAnalysis.Analyzers" Version="3.3.2">
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
</PackageReference>
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.Common" Version="3.10.0" />
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="3.10.0" />
|
||||
<!--<PackageReference Include="TinyMapper" Version="3.0.3" />-->
|
||||
<PackageReference Include="Microsoft.CodeAnalysis.CSharp" Version="3.10.0" />-->
|
||||
</ItemGroup>
|
||||
|
||||
<ItemGroup>
|
||||
|
||||
Reference in New Issue
Block a user