Iuknown interface, DOT NET Programming

Assignment Help:

Describe IUKNOWN interface

All COM object supports atleast one interface, that is  IUnknown interface. All interfaces are the classes, derived from the base class IUnknown. Every interface supports methods access data and perform operations transparently to the programmer. taking example, IUnknown supports 3 methods, AddRef, Release(), & QueryInterface(). Assuming that pinterf is a pointer to an IUnknown. pinterf->AddRef() increments the reference count. pinterf->Release() decrements the reference count, deleting the object when the reference count reaches 0(zero). pinterf->QueryInterface( IDesired,pDesired) checks to watch  if the current interface (IUnknown) supports another interface, IDesired, creates an instance (via a call to CoCreateInstance()) of the object if the reference count is 0 (the object does not yet exist), and then calls pDesired->AddRef() to increment the reference count (where pDesired is a pointer to IDesired) and returns the pointer to the caller.


Related Discussions:- Iuknown interface

What is difference between namespace and assembly, What is Difference betwe...

What is Difference between NameSpace and Assembly? Following are the differences among namespace and assembly: Assembly is physical grouping of logical units, Namespace, log

Data hiding and encryption would be done on images, Data hiding and encrypt...

Data hiding and encryption would be done on images. Both these process should have a data hiding key and an encryption key correspondingly. Another user should be able to decrypt t

Yuy, Ask queyuyuystion #Minimum 100 words accepted#

Ask queyuyuystion #Minimum 100 words accepted#

How do we connect to sql server ?, How do we connect to SQL SERVER, which n...

How do we connect to SQL SERVER, which namespace do we use ? The code is shown below, after that i will  give the explanation for it. For this sample we will also require a SQL

Explain repeater control, How can you provide an alternating color scheme i...

How can you provide an alternating color scheme in a Repeater control?  AlternatingItemTemplate Like the ItemTemplate element, but rendered for each other row (alternating item

Difference b/w msml and .net framework xml classes, What is the main differ...

What is the main difference b/w MSML and .NET Framework XML classes? The MSXML supports XML DOM and SAX parsers while the .NET framework XML classes support XML DOM and XML rea

How to access view state value of the page in the next page?, How do we acc...

How do we access view state value of the page in the next page? The View state is page specific; it contains information about controls embedded at the particular page. ASP.NET

Title..case statement, Design an interface and add code to command buttons ...

Design an interface and add code to command buttons using case statement, to find coursework to be calculated using formula 0.6*1/6*total Mark

Media player app development for windows, Media Player App Development for ...

Media Player App Development for Windows 8.1 platform with outstanding UI, flexible controls and simple to use. The app should be consist of 1. Normal player controls 2. s

Write Your Message!

Captcha
Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd