RAD Studio VCL Reference
ContentsIndex
PreviousUpNext
InvokeRegistry.TCreateInstanceProc Type

TCreateInstanceProc is the type of the factory routine that returns an instance of an invokable class.

Pascal
TCreateInstanceProc = procedure (out obj: TObject);
C++
(out obj: TObject) ( TCreateInstanceProc)();

InvokeRegistry

TCreateInstanceProc is the type for procedures that return an instance of an invokable class on behalf of the invocation registry. When the class that implements an invokable interface is not a descendant of TInvokableClass, or when you want to control the instantiation of the implementation class (for example to use a single shared instance for all incoming requests), supply a procedure of this type when registering the implementation class. 

obj returns an instance of the invokable class, which can handle the current incoming request. 

 

Copyright(C) 2008 CodeGear(TM). All Rights Reserved.
What do you think about this topic? Send feedback!