mail-archives/mono-devel-list/2013-June/040545.html

113 строки
3.9 KiB
HTML

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<HTML>
<HEAD>
<TITLE> [Mono-dev] Creating classes from referenced assemblies in embedded Mono
</TITLE>
<LINK REL="Index" HREF="index.html" >
<LINK REL="made" HREF="mailto:mono-devel-list%40lists.ximian.com?Subject=Re%3A%20%5BMono-dev%5D%20Creating%20classes%20from%20referenced%20assemblies%20in%20embedded%0A%09Mono&In-Reply-To=%3CBB527BF2-B324-44FA-AC75-F1DA5D2FCD3A%40mugginsoft.com%3E">
<META NAME="robots" CONTENT="index,nofollow">
<style type="text/css">
pre {
white-space: pre-wrap; /* css-2.1, curent FF, Opera, Safari */
}
</style>
<META http-equiv="Content-Type" content="text/html; charset=us-ascii">
<LINK REL="Previous" HREF="040538.html">
<LINK REL="Next" HREF="040554.html">
</HEAD>
<BODY BGCOLOR="#ffffff">
<H1>[Mono-dev] Creating classes from referenced assemblies in embedded Mono</H1>
<B>jonathan at mugginsoft.com</B>
<A HREF="mailto:mono-devel-list%40lists.ximian.com?Subject=Re%3A%20%5BMono-dev%5D%20Creating%20classes%20from%20referenced%20assemblies%20in%20embedded%0A%09Mono&In-Reply-To=%3CBB527BF2-B324-44FA-AC75-F1DA5D2FCD3A%40mugginsoft.com%3E"
TITLE="[Mono-dev] Creating classes from referenced assemblies in embedded Mono">jonathan at mugginsoft.com
</A><BR>
<I>Mon Jun 17 19:54:49 UTC 2013</I>
<P><UL>
<LI>Previous message: <A HREF="040538.html">[Mono-dev] Serialization TimeZoneInfo class
</A></li>
<LI>Next message: <A HREF="040554.html">[Mono-dev] Where can I find GetTargetHandle, etc?
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#40545">[ date ]</a>
<a href="thread.html#40545">[ thread ]</a>
<a href="subject.html#40545">[ subject ]</a>
<a href="author.html#40545">[ author ]</a>
</LI>
</UL>
<HR>
<!--beginarticle-->
<PRE>HI
I embed an existing executable console assembly A.exe in my host OS X app.
A.exe references library assembly B.dll.
I can load and initialise the embedded A.exe without issue.
What is the best way for the host app to create instances of classes that reside in B.dll?
You might ask, well why not just load assembly B.dll in the first place?
Classes in B depend on configuration information (data providers etc) that are loaded in app.config.
I thought that providing a B.config.dll would provide a way forward but perhaps not:
see <A HREF="http://stackoverflow.com/questions/594298/c-sharp-dll-config-file">http://stackoverflow.com/questions/594298/c-sharp-dll-config-file</A>
I could, I suppose, provide explicit methods in A.exe to provide instances of classes in B.dll but that seems primitive.
Or perhaps I need to load B.dll and configure the AppDomain config file separately?
Any pointers appreciated.
Regards
Jonathan Mitchell
Mugginsoft LLP
-------------- next part --------------
An HTML attachment was scrubbed...
URL: &lt;<A HREF="http://lists.ximian.com/pipermail/mono-devel-list/attachments/20130617/673a45d7/attachment-0001.html">http://lists.ximian.com/pipermail/mono-devel-list/attachments/20130617/673a45d7/attachment-0001.html</A>&gt;
</PRE>
<!--endarticle-->
<HR>
<P><UL>
<!--threads-->
<LI>Previous message: <A HREF="040538.html">[Mono-dev] Serialization TimeZoneInfo class
</A></li>
<LI>Next message: <A HREF="040554.html">[Mono-dev] Where can I find GetTargetHandle, etc?
</A></li>
<LI> <B>Messages sorted by:</B>
<a href="date.html#40545">[ date ]</a>
<a href="thread.html#40545">[ thread ]</a>
<a href="subject.html#40545">[ subject ]</a>
<a href="author.html#40545">[ author ]</a>
</LI>
</UL>
<hr>
<a href="http://lists.ximian.com/mailman/listinfo/mono-devel-list">More information about the Mono-devel-list
mailing list</a><br>
</body></html>