//////////////////IUknown Interface
| 186 | |
| 187 | ///////////////////////IUknown Interface |
| 188 | HRESULT IStorageTrigger::QueryInterface(const IID &riid, void **ppvObj) { |
| 189 | // Always set out parameter to NULL, validating it first. |
| 190 | if (!ppvObj) { |
| 191 | //printf("QueryInterface INVALID\n"); |
| 192 | return E_INVALIDARG; |
| 193 | } |
| 194 | if (riid == IID_IUnknown) |
| 195 | { |
| 196 | *ppvObj = static_cast<IStorageTrigger *>(this); |
| 197 | //reinterpret_cast<IUnknown*>(*ppvObj)->AddRef(); |
| 198 | } |
| 199 | else if (riid == IID_IStorage) |
| 200 | { |
| 201 | *ppvObj = static_cast<IStorageTrigger *>(this); |
| 202 | } |
| 203 | else if (riid == IID_IMarshal) |
| 204 | { |
| 205 | *ppvObj = static_cast<IStorageTrigger *>(this); |
| 206 | } |
| 207 | else |
| 208 | { |
| 209 | *ppvObj = NULL; |
| 210 | //printf("QueryInterface NOINT\n"); |
| 211 | return E_NOINTERFACE; |
| 212 | } |
| 213 | // Increment the reference count and return the pointer. |
| 214 | |
| 215 | return S_OK; |
| 216 | |
| 217 | } |
| 218 | |
| 219 | |
| 220 | ULONG IStorageTrigger::AddRef() { |
nothing calls this directly
no outgoing calls
no test coverage detected