17 lines
434 B
C#
17 lines
434 B
C#
using Humanizer;
|
|
|
|
namespace DevDisciples.Json.Tools;
|
|
|
|
public static partial class Json2CSharpTranslator
|
|
{
|
|
public struct PropertyTranslation : ITranslation
|
|
{
|
|
public string Name { get; set; }
|
|
public string Type { get; set; }
|
|
|
|
public void Translate(Context context)
|
|
{
|
|
context.Builder.Append($"\tpublic {Type} {Name.Pascalize()} {{ get; set; }}\n");
|
|
}
|
|
}
|
|
} |