Darin Fisher wrote:
Antoine Julien wrote:
Is it possible to access a Mozilla component from an external application?
Let's say I would like to have an application that interacts with Mozilla. I would then create a component that would do the Mozilla related stuff, and another application (C++) that could communicate with the component to do its stuff. Is such a communication between applications possible with XPCOM? I know it is with COM so I was wondering.
I suspect I would need to retrieve my reference to the component with the nsIServiceManager::getServiceByContractID method, but then I'd need to have access to the nsIServiceManager (or nsIComponentManager for Instances instead of Services). So the whole question becomes basically: can one access the service/componenet manager from outside Mozilla?
_______________________________________________
Mozilla-xpcom mailing list
[EMAIL PROTECTED]
http://mail.mozilla.org/listinfo/mozilla-xpcom
i'm not exactly sure what you are asking. are you asking:
1) can i do something like DCOM with XPCOM? (i.e., where i interact with a XPCOM component remotely via some IPC mechanism)
or,
2) can i load a XPCOM component into my application and use it?
if #2, then yes (sort of). just follow the instructions in:
http://www.mozilla.org/projects/xpcom/book/cxc/
where it talks about loading the GRE. you basically need to either link to xpcom.dll or you need to explicitly load it at runtime. the XPCOM "glue" layer assists in the second option. using XPCOMGlueStartup("c:\path\to\xpcom.dll"), you can load the GRE and then interact with any XPCOM components from within your application.
if #1, then you are out-of-luck. there isn't any support for that yet.
--darin
What I'm asking is #1, ie is there something similar to DCOM with XPCOM?
I made a Mozilla component and installed it in Mozilla. Now I would want a separate application to communicate with that component when Mozilla is running.
So I guess I'm out-of-luck... I'll try to find a way around. Thanks for the reply.
A. _______________________________________________ Mozilla-xpcom mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-xpcom
there is experimental support in the works for this...
see,
http://lxr.mozilla.org/seamonkey/source/ipc/ipcd/client/public/ipcIService.idl
this service provides mozilla with a way to talk to other gecko-based applications. it can be used to implement a D-XPCOM like thing, but there isn't any code for that yet.
--darin _______________________________________________ Mozilla-xpcom mailing list [EMAIL PROTECTED] http://mail.mozilla.org/listinfo/mozilla-xpcom
