Open dsoronda opened 7 years ago
@dsoronda - thanks a lot for your input and contribution! I'll add it in the next release.
Thanks for quick response, I really need this feature as quick as possible since I use ExpressMapper in all my projects and we are in process of migrating to VS 2017 solution.
Also, by building .NETStandard 1.1+ version you automatically support .NET 4.5+ and .NET Core solutions from single project.
@dsoronda - I think it's not a big deal - I'll try to release a patch in the end of the day. I'll keep you posted.
Any news ?
I just encountered this when targeting netcoreapp1.1
on VS 2017:
Package Expressmapper 1.9.1 is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1).
Already raised an issue for it #128. I would be supported in 1.9.2 release.
Sent from my iPhone
On Mar 22, 2017, at 4:07 PM, Mike Bridge notifications@github.com wrote:
I just encountered this when targeting netcoreapp1.1 on VS 2017:
Package Expressmapper 1.9.1 is not compatible with netcoreapp1.1 (.NETCoreApp,Version=v1.1).
— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub, or mute the thread.
+1 for this enhancement. I really like this library and I'm being blocked because the lack of support for .NET Standard. It can be solved but the tricks are "ugly" and I would rather prefer a clean, built-in support. Hope it will be release soon!
Any updates on this please?
Any news on this?
Any update please?
I'd like to see Dependency Injection for netcore. I really need it for DateTime conversion where I have to use a user timezone service. So my entities have UTC dates but VMs are local ones depending on user context. Something like Resolver does in AutoMapping. Have alook at my example (project attached WebApplication1.zip): Startup.cs
public void ConfigureServices(IServiceCollection services)
{
...
services.AddSingleton<IMappingServiceProvider>(srv =>
new MappingServiceConfig(srv,
new Assembly[]{
typeof(MyMapperProfile).GetTypeInfo().Assembly
})
.GetProvider());
...
}
MyMapperProfile.cs
public class MyMapperProfile : MapperProfile
{
public MyMapperProfile(IMappingServiceProvider mappingProvider, IServiceProvider serviceProvider) : base(mappingProvider, serviceProvider)
{
MappingProvider.Register<MyEntity, MyViewModel>()
.Member(dest => dest.VmNumberOne, src => src.EntityNumberOne)
.Function(dest => dest.VmNumberTwo, src => { return serviceProvider.GetService<IMyService>().MyMethod(src.EntityNumberTwo); });
}
}
Thanks a lot.
Is there an update on this? Kind of in a pickle now, went through compatibility tools that said express mapper worked with .Net Standard but it seems like it doesn't target it.
ExpressMapper will be compatible with Net Standard 2.0 class libraries as it introduces a compatibility shim which lets it include packages compatible with standard but not targeted.
Even with the compatiblity in 2.0, would it make more sense to go with AutoMapper as that's actively developed and it's performance is roughly similar to express mapper?
Dear All,
Thanks a lot for your contribution and patience! My apologies for the delay as I couldn't contribute to ExpressMapper recently for the long time as I was busy with my primary job. I'll try to squeeze some time to add support for .Net Standard 1.X and .Net Standard 2.0.
Thanks for understanding!
Hi anisimovyuriy,
Any luck with .NetStandard support, ExpressMapper is great, was using it in a Xamarin project as a PCL, but would be great if could support .NETStandard 1.5.
Thanks again for your project.
I could use some help getting this project working for netstandard1.2. I got away using 1.3 but I really need 1.2 (windows 8.1 support) The compiler is happy but I need to refactor to have 100% unit test success.
https://github.com/stannynuytkens/ExpressMapper/tree/feature/netstandard12
Please add support for .NETStandard 1.4 (or even 1.1 if possible) so it can be referenced from .NET4.6.1 and Core projects.
.NET Standard Library