Stuff and things

This commit is contained in:
2021-06-29 19:00:13 -04:00
parent 0ff42f148a
commit 962ad3383f
22 changed files with 320 additions and 226 deletions

View File

@@ -0,0 +1,16 @@
using Microsoft.EntityFrameworkCore.Storage.ValueConversion;
using System;
using System.Collections.Generic;
using System.Linq.Expressions;
using System.Text;
namespace PartSource.Data.Converters
{
public class TypeToStringConverter : ValueConverter<Type, string>
{
public TypeToStringConverter() : base(TypeToString, StringToType) { }
public static Expression<Func<string, Type>> StringToType = value => Type.GetType(value);
public static Expression<Func<Type, string>> TypeToString = value => value.AssemblyQualifiedName;
}
}