compilation time vs run time

  • Thread starter Thread starter julien
  • Start date Start date
J

julien

Hello,

I try to understand was is statically compiled, and what is loaded at
tun time.

I have 3 binary file: Program.exe, Plugin.dll, and Share.dll
Share.dll contains objects used by both Plugin.dll and Program.exe.
I compile these 2 program with Share.dll

Do the 2 binary have an embedded version of Share.dll (compilation
time), or do they load Share.dll at run time?

Then, if I modify Share.dll (add methods and properties, modify the
implementation of the methods, etc.) without removing any public method
or property, can I just replace Share.dll (run time) by the next version
without compiling both programs again?

I try to see if I can update share objects without compiling program
using these share objects.

Thanks
Julien
 
Julien,

As long as you don't change the signature of any methods in the assembly,
you can indeed substitute a new shared DLL without recompiling other
assemblies that might call into it. Indeed, dummy assemblies with stubbed
out method implementations are routinely used as local proxies for remoted
classes -- it's a way to provide the metadata to clients without exposing
the code to hackers.

--Bob
 
Yes, you can, unless you have strong-named your assemblies. And yes,
assemblies are loaded at runtime and on-demand. When you compile a
project that refers to other assemblies, only entries are made in the
generated assembly's metadata, the referenced assemblies are not
embedded.

Regards
Senthil
 
Back
Top