What is the ($Foo)PS project in my $Foo ATL solution for?

后端 未结 3 1948
被撕碎了的回忆
被撕碎了的回忆 2021-02-01 16:20

Creating an ATL project in MSVC seems to create not one but two projects; the latter named the same as the former but with PS appended to its name. What is the purpose of this

3条回答
  •  忘掉有多难
    2021-02-01 17:15

    It's proxy/stub code, which contains non-standard data marshallers needed to transfer data between different apartments (threading related). It's used when application, which calls your COM object, uses different COM threading model. There was an option in ATL/COM wizard to merge this code into main library. In many common scenarios you don't have to worry about it (i.e. when your COM dll runs in the client context), unless you want to write a custom marshaller.

提交回复
热议问题