⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 rosemagic_tlb.~pas

📁 Rose2003自定义插件开发代码示例,delphi版本
💻 ~PAS
📖 第 1 页 / 共 2 页
字号:
unit RoseMagic_TLB;

// ************************************************************************ //
// WARNING                                                                    
// -------                                                                    
// The types declared in this file were generated from data read from a       
// Type Library. If this type library is explicitly or indirectly (via        
// another type library referring to this type library) re-imported, or the   
// 'Refresh' command of the Type Library Editor activated while editing the   
// Type Library, the contents of this file will be regenerated and all        
// manual modifications will be lost.                                         
// ************************************************************************ //

// PASTLWTR : $Revision:   1.88  $
// File generated on 2004-6-20 14:57:36 from Type Library described below.

// *************************************************************************//
// NOTE:                                                                      
// Items guarded by $IFDEF_LIVE_SERVER_AT_DESIGN_TIME are used by properties  
// which return objects that may need to be explicitly created via a function 
// call prior to any access via the property. These items have been disabled  
// in order to prevent accidental use from within the object inspector. You   
// may enable them by defining LIVE_SERVER_AT_DESIGN_TIME or by selectively   
// removing them from the $IFDEF blocks. However, such items must still be    
// programmatically created via a method of the appropriate CoClass before    
// they can be used.                                                          
// ************************************************************************ //
// Type Lib: C:\Program Files\Ensemble\User-Defined Design Patterns\Examples\RoseMagic\RoseMagic.tlb (1)
// IID\LCID: {952F554D-77E3-4910-837D-284A98C6D569}\0
// Helpfile: 
// DepndLst: 
//   (1) v2.0 stdole, (C:\WINNT\System32\stdole2.tlb)
//   (2) v4.0 StdVCL, (C:\WINNT\System32\STDVCL40.DLL)
//   (3) v4.2 RationalRose, (C:\Program Files\Rational2003\Rose\RationalRose.tlb)
// ************************************************************************ //
{$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers. 
interface

uses Windows, ActiveX, Classes, Graphics, OleServer, OleCtrls, StdVCL, 
  RationalRose_TLB;

// *********************************************************************//
// GUIDS declared in the TypeLibrary. Following prefixes are used:        
//   Type Libraries     : LIBID_xxxx                                      
//   CoClasses          : CLASS_xxxx                                      
//   DISPInterfaces     : DIID_xxxx                                       
//   Non-DISP interfaces: IID_xxxx                                        
// *********************************************************************//
const
  // TypeLibrary Major and minor versions
  RoseMagicMajorVersion = 1;
  RoseMagicMinorVersion = 0;

  LIBID_RoseMagic: TGUID = '{952F554D-77E3-4910-837D-284A98C6D569}';

  IID_ICoRoseMagic: TGUID = '{0A3A2BE1-1212-4D52-BB77-4A84AE0EC864}';
  DIID_ICoRoseMagicEvents: TGUID = '{A0C479BA-EF6C-4FDA-BC99-97A607488EF5}';
  CLASS_CoRoseMagic: TGUID = '{45D103D4-DD91-4B01-AE6A-D313E32DCFC3}';
  IID_ICoAbout: TGUID = '{80BB5C56-A5B6-47F5-96C4-37B093147A79}';
  DIID_ICoAboutEvents: TGUID = '{13065E23-E6D0-4F00-BEB2-7659A45B5E2F}';
  CLASS_CoAbout: TGUID = '{37BC1685-F3ED-401F-B90C-2F8D9B257F28}';
type

// *********************************************************************//
// Forward declaration of types defined in TypeLibrary                    
// *********************************************************************//
  ICoRoseMagic = interface;
  ICoRoseMagicDisp = dispinterface;
  ICoRoseMagicEvents = dispinterface;
  ICoAbout = interface;
  ICoAboutDisp = dispinterface;
  ICoAboutEvents = dispinterface;

// *********************************************************************//
// Declaration of CoClasses defined in Type Library                       
// (NOTE: Here we map each CoClass to its Default Interface)              
// *********************************************************************//
  CoRoseMagic = ICoRoseMagic;
  CoAbout = ICoAbout;


// *********************************************************************//
// Interface: ICoRoseMagic
// Flags:     (4416) Dual OleAutomation Dispatchable
// GUID:      {0A3A2BE1-1212-4D52-BB77-4A84AE0EC864}
// *********************************************************************//
  ICoRoseMagic = interface(IDispatch)
    ['{0A3A2BE1-1212-4D52-BB77-4A84AE0EC864}']
    procedure OnActivate(var roseapp: IRoseApplication); safecall;
    procedure OnDeactivate(var roseapp: IRoseApplication); safecall;
    function  OnEnableContextMenuItems(var roseapp: IRoseApplication; var itemType: Smallint): WordBool; safecall;
    function  OnSelectedContextMenuItem(var roseapp: IRoseApplication; var aInternalName: WideString): WordBool; safecall;
    procedure ShowDesignPatternManager(var roseapp: IRoseApplication); safecall;
  end;

// *********************************************************************//
// DispIntf:  ICoRoseMagicDisp
// Flags:     (4416) Dual OleAutomation Dispatchable
// GUID:      {0A3A2BE1-1212-4D52-BB77-4A84AE0EC864}
// *********************************************************************//
  ICoRoseMagicDisp = dispinterface
    ['{0A3A2BE1-1212-4D52-BB77-4A84AE0EC864}']
    procedure OnActivate(var roseapp: IRoseApplication); dispid 1;
    procedure OnDeactivate(var roseapp: IRoseApplication); dispid 2;
    function  OnEnableContextMenuItems(var roseapp: IRoseApplication; var itemType: Smallint): WordBool; dispid 3;
    function  OnSelectedContextMenuItem(var roseapp: IRoseApplication; var aInternalName: WideString): WordBool; dispid 4;
    procedure ShowDesignPatternManager(var roseapp: IRoseApplication); dispid 5;
  end;

// *********************************************************************//
// DispIntf:  ICoRoseMagicEvents
// Flags:     (0)
// GUID:      {A0C479BA-EF6C-4FDA-BC99-97A607488EF5}
// *********************************************************************//
  ICoRoseMagicEvents = dispinterface
    ['{A0C479BA-EF6C-4FDA-BC99-97A607488EF5}']
  end;

// *********************************************************************//
// Interface: ICoAbout
// Flags:     (4416) Dual OleAutomation Dispatchable
// GUID:      {80BB5C56-A5B6-47F5-96C4-37B093147A79}
// *********************************************************************//
  ICoAbout = interface(IDispatch)
    ['{80BB5C56-A5B6-47F5-96C4-37B093147A79}']
    procedure Start(const RoseInstant: IDispatch); safecall;
  end;

// *********************************************************************//
// DispIntf:  ICoAboutDisp
// Flags:     (4416) Dual OleAutomation Dispatchable
// GUID:      {80BB5C56-A5B6-47F5-96C4-37B093147A79}
// *********************************************************************//
  ICoAboutDisp = dispinterface
    ['{80BB5C56-A5B6-47F5-96C4-37B093147A79}']
    procedure Start(const RoseInstant: IDispatch); dispid 1;
  end;

// *********************************************************************//
// DispIntf:  ICoAboutEvents
// Flags:     (0)
// GUID:      {13065E23-E6D0-4F00-BEB2-7659A45B5E2F}
// *********************************************************************//
  ICoAboutEvents = dispinterface
    ['{13065E23-E6D0-4F00-BEB2-7659A45B5E2F}']
  end;

// *********************************************************************//
// The Class CoCoRoseMagic provides a Create and CreateRemote method to          
// create instances of the default interface ICoRoseMagic exposed by              
// the CoClass CoRoseMagic. The functions are intended to be used by             
// clients wishing to automate the CoClass objects exposed by the         
// server of this typelibrary.                                            
// *********************************************************************//
  CoCoRoseMagic = class
    class function Create: ICoRoseMagic;
    class function CreateRemote(const MachineName: string): ICoRoseMagic;
  end;


// *********************************************************************//
// OLE Server Proxy class declaration
// Server Object    : TCoRoseMagic
// Help String      : CoRoseMagic Object
// Default Interface: ICoRoseMagic
// Def. Intf. DISP? : No
// Event   Interface: ICoRoseMagicEvents
// TypeFlags        : (2) CanCreate
// *********************************************************************//
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
  TCoRoseMagicProperties= class;
{$ENDIF}
  TCoRoseMagic = class(TOleServer)
  private
    FIntf:        ICoRoseMagic;
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
    FProps:       TCoRoseMagicProperties;
    function      GetServerProperties: TCoRoseMagicProperties;
{$ENDIF}
    function      GetDefaultInterface: ICoRoseMagic;
  protected
    procedure InitServerData; override;
    procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
  public
    constructor Create(AOwner: TComponent); override;
    destructor  Destroy; override;
    procedure Connect; override;
    procedure ConnectTo(svrIntf: ICoRoseMagic);
    procedure Disconnect; override;
    procedure OnActivate(var roseapp: IRoseApplication);
    procedure OnDeactivate(var roseapp: IRoseApplication);
    function  OnEnableContextMenuItems(var roseapp: IRoseApplication; var itemType: Smallint): WordBool;
    function  OnSelectedContextMenuItem(var roseapp: IRoseApplication; var aInternalName: WideString): WordBool;
    procedure ShowDesignPatternManager(var roseapp: IRoseApplication);
    property  DefaultInterface: ICoRoseMagic read GetDefaultInterface;
  published
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
    property Server: TCoRoseMagicProperties read GetServerProperties;
{$ENDIF}
  end;

{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
// *********************************************************************//
// OLE Server Properties Proxy Class
// Server Object    : TCoRoseMagic
// (This object is used by the IDE's Property Inspector to allow editing
//  of the properties of this server)
// *********************************************************************//
 TCoRoseMagicProperties = class(TPersistent)
  private
    FServer:    TCoRoseMagic;
    function    GetDefaultInterface: ICoRoseMagic;
    constructor Create(AServer: TCoRoseMagic);
  protected
  public
    property DefaultInterface: ICoRoseMagic read GetDefaultInterface;
  published
  end;
{$ENDIF}


// *********************************************************************//
// The Class CoCoAbout provides a Create and CreateRemote method to          
// create instances of the default interface ICoAbout exposed by              
// the CoClass CoAbout. The functions are intended to be used by             
// clients wishing to automate the CoClass objects exposed by the         
// server of this typelibrary.                                            
// *********************************************************************//
  CoCoAbout = class
    class function Create: ICoAbout;
    class function CreateRemote(const MachineName: string): ICoAbout;
  end;


// *********************************************************************//
// OLE Server Proxy class declaration
// Server Object    : TCoAbout
// Help String      : CoAbout Object
// Default Interface: ICoAbout
// Def. Intf. DISP? : No
// Event   Interface: ICoAboutEvents
// TypeFlags        : (2) CanCreate
// *********************************************************************//
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
  TCoAboutProperties= class;
{$ENDIF}
  TCoAbout = class(TOleServer)
  private
    FIntf:        ICoAbout;
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
    FProps:       TCoAboutProperties;
    function      GetServerProperties: TCoAboutProperties;
{$ENDIF}
    function      GetDefaultInterface: ICoAbout;
  protected
    procedure InitServerData; override;
    procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
  public
    constructor Create(AOwner: TComponent); override;
    destructor  Destroy; override;
    procedure Connect; override;
    procedure ConnectTo(svrIntf: ICoAbout);
    procedure Disconnect; override;
    procedure Start(const RoseInstant: IDispatch);
    property  DefaultInterface: ICoAbout read GetDefaultInterface;
  published
{$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
    property Server: TCoAboutProperties read GetServerProperties;
{$ENDIF}
  end;

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -