4 ms·
Reminds me of COM.
by ChrisSD 8y ago
Reminds me of COM.
- bluGill 8y agoMaybe, but COM's reputation is it is too complex. From what I can tell the reputation is well deserved.
- pjc50 8y agoMuch of COM's horror comes from being an OO interop system designed to work in non-OO C. All sorts of manual reference counting. If you use COM objects in C# it's much less horrifying, although there's a certain amount of "body horror" involved in firing up one whole windows application inside another one. You can run IE in a cell of an Excel spreadsheet, but that doesn't make it a good idea.
- maxxxxx 8y agoWorking with VB made COM really nice. Both for writing COM servers and consuming them. C# is actually a step back because it doesn't do the reference counting right and instead relies on GC to free objects.
- reitanqild 8y ago> You can run IE in a cell of an Excel spreadsheet, but that doesn't make it a good idea. Embedding a MS Works worksheet in a MS Works document however was sometimes a good idea in '95. I've yet to see a better implementation than that and I find it really disappointing that the state of the art has moved backwards in this area (in addition to UX and performance relative to hardware specs).
- maxxxxx 8y agoI agree. Apple also had an effort called "OpenDoc" which they gave up on.
- pjmlp 8y agoCOM works pretty well in Delphi, .NET, C++ Builder, MFC, C++/CX and now C++/WinRT. The problems and boilerplate usually affect those that insist in using the C level APIs.
- Const-me 8y agoIt's too many things at once. The ABI is excellent and is used all the time, see DirectX, MediaFoundation, .NET, UWP, etc, they all use good parts of COM. Scripting support (IDispatch, WSH) is OK despite a bit outdated. Registration infrastructure (HKCR), GUI widgets (ActiveX), threading model (these apartments) and inheritance of implementation (aggregation) ain't good, way overengineered. Compound document format (structured storage), RPC both local and networked, are just horrible.
- int_19h 8y agoCore COM is basically predefined vtable layout and object reference comparison rules combined with IUnknown for lifetime and type queries. It can be verbose, but it's very simple. Stuff like OLE Automation is very much not simple, but it's not a requisite part of it all.
- Koshkin 8y agoThis one is my favorite: https://msdn.microsoft.com/en-us/library/ms809983.aspx https://msdn.microsoft.com/en-us/library/ms809983.aspx