Code exchange between compact and full .NET Framework

I have a whole bunch of projects that I want to reuse between a .NET map and a full map. I read Daniel Mot an incredibly informative article about this topic ( http://msdn.microsoft.com/en-us/magazine/cc163387.aspx )

So, two main methods:

1) Point the compact frame (i.e. go to the lowest common denominator)

2) They have different projects that refer to the same source.

I would rather go with method 1 simply because I would like to write ONCE, build ONCE and deploy ONCE. Are there any problems with performance / memory / stability going to this approach?

+4
source share
1 answer

The first option sounds great in theory until you are working on one of your projects, and you really would like to implement some function for the full version, but you cannot have a compact version because it does not support it.

I would suggest trying to isolate all the “lowest common denominator” code into separate assemblies from everything else. If you handle the problem section correctly, you can have a front end for your complete and compact projects by connecting the appropriate assemblies in each corresponding interface.

However, I think this is probably a good tip to start by aiming at a compact framework. Separate the problems when necessary, and when you get to the point where you really need an extra feature in the full version, then you need to split into two front ends. Do not do this until you need it, otherwise YAGNI.

+2
source

Source: https://habr.com/ru/post/1286770/


All Articles