reflection - Different versions of the same assembly -
I am writing a cover for a library that has received a huge change in the API between one version and the other, This is required to create an agreement that will allow me to access two versions of the same API. This is my project structure:
- Client.dll - reference - Contract.dll - Version01.dll - Version02.dll - Contract.dll - IMyService.cs - version 01.dll - MyServiceImplementation. Cs - reference - Version01Assembly.dll - Version02.dll - MyServiceImplementation.cs - Reference - Version02Assembly.dll
Need to call me within the project Client.dll May be the service or the implementation of another, and it is quite fine. The issue is that the Assembly filled in Appendaman is always due to version 072. Asambebs.dell in my client's bin folder, I always look for the latest version of this dependency. How can I keep these two libraries reference to a different version of the same assembly?
I hope the question is clear
I have never done that, but I think you have two options -
-
If possible, give a strong name to these assemblies and take them to the GAC.
-
If (1) is not possible, then sub-folders (
v1.x
& amp;v2.x
). Then load the assembly usingAssembly.LoadFrom ()
orAppDomain.Load
[It is possible that you can run in issues of type resolution, so please go through this Read from -]
Comments
Post a Comment