public Type GetUnderlyingType() { var assembly = AppDomain.CurrentDomain.GetAssemblies().FirstOrDefault(x => x.GetName().Name == Assembly) ?? ImplementationsProvider.Instance.GetAssemblies().FirstOrDefault(x => x.GetName().Name == Assembly); if (assembly == null) { return(null); } Type t = assembly.GetType(FullName); if (t != null && t.IsGenericType) { return(t.MakeGenericType(GenericTypeArgs.Select(x => x.GetUnderlyingType()).ToArray())); } return(t); }
public override string ToString() => IsGenericType ? $"{Name.Split('`').FirstOrDefault()}<{string.Join(",", GenericTypeArgs.Select(x => x.Name))}>" : Name;