Subversion Repositories simple_log_event

Rev

Rev 2 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

  1. unit ViaThinkSoftSimpleLogEvent_TLB;
  2.  
  3. // ************************************************************************ //
  4. // WARNUNG
  5. // -------
  6. // Die in dieser Datei deklarierten Typen wurden aus Daten einer Typbibliothek
  7. // generiert. Wenn diese Typbibliothek explizit oder indirekt (über eine
  8. // andere Typbibliothek) reimportiert wird oder wenn der Befehl
  9. // 'Aktualisieren' im Typbibliotheks-Editor während des Bearbeitens der
  10. // Typbibliothek aktiviert ist, wird der Inhalt dieser Datei neu generiert und
  11. // alle manuell vorgenommenen Änderungen gehen verloren.
  12. // ************************************************************************ //
  13.  
  14. // $Rev: 52393 $
  15. // Datei am 30.04.2020 23:02:59 erzeugt aus der unten beschriebenen Typbibliothek.
  16.  
  17. // ************************************************************************  //
  18. // Typbib.: C:\Users\DELL User\SVN\SimpleLogEvent\trunk\TLB\ViaThinkSoftSimpleLogEvent (1)
  19. // LIBID: {D7654BA7-41D0-4FF9-8543-C3A4DA936856}
  20. // LCID: 0
  21. // Hilfedatei:
  22. // Hilfe-String: ViaThinkSoftSimpleLogEvent Library
  23. // Liste der Abhäng.:
  24. //   (1) v2.0 stdole, (C:\Windows\SysWOW64\stdole2.tlb)
  25. // SYS_KIND: SYS_WIN32
  26. // ************************************************************************ //
  27. {$TYPEDADDRESS OFF} // Unit muss ohne Typüberprüfung für Zeiger compiliert werden.
  28. {$WARN SYMBOL_PLATFORM OFF}
  29. {$WRITEABLECONST ON}
  30. {$VARPROPSETTER ON}
  31. {$ALIGN 4}
  32.  
  33. interface
  34.  
  35. uses Winapi.Windows, System.Classes, System.Variants, System.Win.StdVCL, Vcl.Graphics, Vcl.OleServer, Winapi.ActiveX;
  36.  
  37. // *********************************************************************//
  38. // In der Typbibliothek deklarierte GUIDS. Die folgenden Präfixe werden verwendet:
  39. //   Typbibliotheken      : LIBID_xxxx
  40. //   CoClasses            : CLASS_xxxx
  41. //   DISPInterfaces       : DIID_xxxx
  42. //   Nicht-DISP-Interfaces: IID_xxxx
  43. // *********************************************************************//
  44. const
  45.   // Haupt- und Nebenversionen der Typbibliothek
  46.   ViaThinkSoftSimpleLogEventMajorVersion = 1;
  47.   ViaThinkSoftSimpleLogEventMinorVersion = 0;
  48.  
  49.   LIBID_ViaThinkSoftSimpleLogEvent: TGUID = '{D7654BA7-41D0-4FF9-8543-C3A4DA936856}';
  50.  
  51.   IID_IViaThinkSoftSimpleEventLog: TGUID = '{4094657E-8199-460F-A3DD-5BB63B6B0F65}';
  52.   CLASS_ViaThinkSoftSimpleEventLog: TGUID = '{E4270053-A217-498C-B395-9EF33187E8C2}';
  53.  
  54. // *********************************************************************//
  55. // Deklaration von in der Typbibliothek definierten Aufzählungen
  56. // *********************************************************************//
  57. // Konstanten für enum LogEventType
  58. type
  59.   LogEventType = TOleEnum;
  60. const
  61.   Success = $00000000;
  62.   Informational = $00000001;
  63.   Warning = $00000002;
  64.   Error = $00000003;
  65.  
  66. type
  67.  
  68. // *********************************************************************//
  69. // Forward-Deklaration von in der Typbibliothek definierten Typen
  70. // *********************************************************************//
  71.   IViaThinkSoftSimpleEventLog = interface;
  72.   IViaThinkSoftSimpleEventLogDisp = dispinterface;
  73.  
  74. // *********************************************************************//
  75. // Deklaration von in der Typbibliothek definierten CoClasses
  76. // (HINWEIS: Hier wird jede CoClass ihrem Standard-Interface zugewiesen)
  77. // *********************************************************************//
  78.   ViaThinkSoftSimpleEventLog = IViaThinkSoftSimpleEventLog;
  79.  
  80.  
  81. // *********************************************************************//
  82. // Interface: IViaThinkSoftSimpleEventLog
  83. // Flags:     (4416) Dual OleAutomation Dispatchable
  84. // GUID:      {4094657E-8199-460F-A3DD-5BB63B6B0F65}
  85. // *********************************************************************//
  86.   IViaThinkSoftSimpleEventLog = interface(IDispatch)
  87.     ['{4094657E-8199-460F-A3DD-5BB63B6B0F65}']
  88.     procedure LogEvent(const SourceName: WideString; EventType: LogEventType;
  89.                        const LogMsg: WideString); safecall;
  90.   end;
  91.  
  92. // *********************************************************************//
  93. // DispIntf:  IViaThinkSoftSimpleEventLogDisp
  94. // Flags:     (4416) Dual OleAutomation Dispatchable
  95. // GUID:      {4094657E-8199-460F-A3DD-5BB63B6B0F65}
  96. // *********************************************************************//
  97.   IViaThinkSoftSimpleEventLogDisp = dispinterface
  98.     ['{4094657E-8199-460F-A3DD-5BB63B6B0F65}']
  99.     procedure LogEvent(const SourceName: WideString; EventType: LogEventType;
  100.                        const LogMsg: WideString); dispid 201;
  101.   end;
  102.  
  103. // *********************************************************************//
  104. // Die Klasse CoViaThinkSoftSimpleEventLog stellt die Methoden Create und CreateRemote zur
  105. // Verfügung, um Instanzen des Standard-Interface IViaThinkSoftSimpleEventLog, dargestellt
  106. // von CoClass ViaThinkSoftSimpleEventLog, zu erzeugen. Diese Funktionen können
  107. // von einem Client verwendet werden, der die CoClasses automatisieren
  108. // will, die von dieser Typbibliothek dargestellt werden.
  109. // *********************************************************************//
  110.   CoViaThinkSoftSimpleEventLog = class
  111.     class function Create: IViaThinkSoftSimpleEventLog;
  112.     class function CreateRemote(const MachineName: string): IViaThinkSoftSimpleEventLog;
  113.   end;
  114.  
  115. implementation
  116.  
  117. uses System.Win.ComObj;
  118.  
  119. class function CoViaThinkSoftSimpleEventLog.Create: IViaThinkSoftSimpleEventLog;
  120. begin
  121.   Result := CreateComObject(CLASS_ViaThinkSoftSimpleEventLog) as IViaThinkSoftSimpleEventLog;
  122. end;
  123.  
  124. class function CoViaThinkSoftSimpleEventLog.CreateRemote(const MachineName: string): IViaThinkSoftSimpleEventLog;
  125. begin
  126.   Result := CreateRemoteComObject(MachineName, CLASS_ViaThinkSoftSimpleEventLog) as IViaThinkSoftSimpleEventLog;
  127. end;
  128.  
  129. end.
  130.  
  131.