home *** CD-ROM | disk | FTP | other *** search
/ Delphi Magazine Collection 2001 / Delphi Magazine Collection 20001 (2001).iso / DISKS / Issue45 / Clinic / Server / ServerClass.pas < prev    next >
Encoding:
Pascal/Delphi Source File  |  2000-11-02  |  620 b   |  32 lines

  1. unit ServerClass;
  2.  
  3. interface
  4.  
  5. uses
  6.   Windows, Messages, SysUtils, Classes, Graphics, Controls, ComObj, StdVcl,
  7.   CorbaObj, Server_TLB;
  8.  
  9. type
  10.  
  11.   TTest = class(TCorbaImplementation, ITest)
  12.   private
  13.     { Private declarations }
  14.   public
  15.     { Public declarations }
  16.   protected
  17.     function Get_DateAndTime: TDateTime; safecall;
  18.   end;
  19.  
  20. implementation
  21.  
  22. uses CorbInit;
  23.  
  24. function TTest.Get_DateAndTime: TDateTime;
  25. begin
  26.   Result := Now
  27. end;
  28.  
  29. initialization
  30.   TCorbaObjectFactory.Create('TestFactory', 'Test', 'IDL:Server/TestFactory:1.0', ITest,
  31.     TTest, iMultiInstance, tmSingleThread);
  32. end.