[1691] | 1 | unit VERGENCECONTEXTORLib_TLB;
|
---|
| 2 | { **************************************************************
|
---|
| 3 | Package: XWB - Kernel RPCBroker
|
---|
| 4 | Date Created: Sept 18, 1997 (Version 1.1)
|
---|
| 5 | Site Name: Oakland, OI Field Office, Dept of Veteran Affairs
|
---|
| 6 | Developers: Danila Manapsal, Don Craven, Joel Ivey
|
---|
| 7 | Description: Contains TRPCBroker and related components.
|
---|
| 8 | Current Release: Version 1.1 Patch 47 (Jun. 17, 2008))
|
---|
| 9 | *************************************************************** }
|
---|
| 10 |
|
---|
| 11 |
|
---|
| 12 | // ************************************************************************ //
|
---|
| 13 | // WARNING
|
---|
| 14 | // -------
|
---|
| 15 | // The types declared in this file were generated from data read from a
|
---|
| 16 | // Type Library. If this type library is explicitly or indirectly (via
|
---|
| 17 | // another type library referring to this type library) re-imported, or the
|
---|
| 18 | // 'Refresh' command of the Type Library Editor activated while editing the
|
---|
| 19 | // Type Library, the contents of this file will be regenerated and all
|
---|
| 20 | // manual modifications will be lost.
|
---|
| 21 | // ************************************************************************ //
|
---|
| 22 |
|
---|
| 23 | // PASTLWTR : $Revision: 1.88.1.0.1.0 $
|
---|
| 24 | // File generated on 2/9/2004 9:12:53 AM from Type Library described below.
|
---|
| 25 |
|
---|
| 26 | // *************************************************************************//
|
---|
| 27 | // NOTE:
|
---|
| 28 | // Items guarded by $IFDEF_LIVE_SERVER_AT_DESIGN_TIME are used by properties
|
---|
| 29 | // which return objects that may need to be explicitly created via a function
|
---|
| 30 | // call prior to any access via the property. These items have been disabled
|
---|
| 31 | // in order to prevent accidental use from within the object inspector. You
|
---|
| 32 | // may enable them by defining LIVE_SERVER_AT_DESIGN_TIME or by selectively
|
---|
| 33 | // removing them from the $IFDEF blocks. However, such items must still be
|
---|
| 34 | // programmatically created via a method of the appropriate CoClass before
|
---|
| 35 | // they can be used.
|
---|
| 36 | // ************************************************************************ //
|
---|
| 37 | // Type Lib: D:\Development\BDK32_p40\Source\VergenceContextor.dll (1)
|
---|
| 38 | // IID\LCID: {30AFBABD-5FD3-11D3-8727-0060B0B5E137}\0
|
---|
| 39 | // Helpfile:
|
---|
| 40 | // DepndLst:
|
---|
| 41 | // (1) v2.0 stdole, (C:\WINNT\System32\stdole2.tlb)
|
---|
| 42 | // (2) v4.0 StdVCL, (C:\WINNT\System32\STDVCL40.DLL)
|
---|
| 43 | // Errors:
|
---|
| 44 | // Hint: Member 'Set' of 'IResponseDialogAccessor' changed to 'Set_'
|
---|
| 45 | // Error creating palette bitmap of (TContextor) : Invalid GUID format
|
---|
| 46 | // Error creating palette bitmap of (TContextItemCollection) : Invalid GUID format
|
---|
| 47 | // Error creating palette bitmap of (TContextItem) : Invalid GUID format
|
---|
| 48 | // Error creating palette bitmap of (TResponseDialog) : Invalid GUID format
|
---|
| 49 | // Error creating palette bitmap of (TContextorParticipant) : Invalid GUID format
|
---|
| 50 | // ************************************************************************ //
|
---|
| 51 | {$TYPEDADDRESS OFF} // Unit must be compiled without type-checked pointers.
|
---|
| 52 | interface
|
---|
| 53 |
|
---|
| 54 | uses Windows, ActiveX, Classes, Graphics, OleServer, OleCtrls, StdVCL;
|
---|
| 55 |
|
---|
| 56 | // *********************************************************************//
|
---|
| 57 | // GUIDS declared in the TypeLibrary. Following prefixes are used:
|
---|
| 58 | // Type Libraries : LIBID_xxxx
|
---|
| 59 | // CoClasses : CLASS_xxxx
|
---|
| 60 | // DISPInterfaces : DIID_xxxx
|
---|
| 61 | // Non-DISP interfaces: IID_xxxx
|
---|
| 62 | // *********************************************************************//
|
---|
| 63 | const
|
---|
| 64 | // TypeLibrary Major and minor versions
|
---|
| 65 | VERGENCECONTEXTORLibMajorVersion = 1;
|
---|
| 66 | VERGENCECONTEXTORLibMinorVersion = 0;
|
---|
| 67 |
|
---|
| 68 | LIBID_VERGENCECONTEXTORLib: TGUID = '{30AFBABD-5FD3-11D3-8727-0060B0B5E137}';
|
---|
| 69 |
|
---|
| 70 | DIID__IContextChangesSink: TGUID = '{6BED8971-B3DD-11D3-8736-0060B0B5E137}';
|
---|
| 71 | IID_IContextor: TGUID = '{8D879F5D-5FE6-11D3-8727-0060B0B5E137}';
|
---|
| 72 | IID_IContextParticipant: TGUID = '{3E3DD272-998E-11D0-808D-00A0240943E4}';
|
---|
| 73 | IID_IContextItemCollection: TGUID = '{AC4C0271-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 74 | IID_IContextItem: TGUID = '{AC4C0273-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 75 | IID_IResponseContextChange: TGUID = '{CBC6D968-9F6D-416A-8AA7-99172E588DF0}';
|
---|
| 76 | IID_IResponseDialogAccessor: TGUID = '{86592071-F3BA-11D3-8181-005004A0F801}';
|
---|
| 77 | IID_IContextChangesSink: TGUID = '{0B437E31-620E-11D3-84B6-0000861FDD4F}';
|
---|
| 78 | IID_IResponseDialog: TGUID = '{9D33ECF1-8277-11D3-8525-0000861FDD4F}';
|
---|
| 79 | CLASS_Contextor: TGUID = '{D5C9CC98-5FDB-11D3-8727-0060B0B5E137}';
|
---|
| 80 | CLASS_ContextorControl: TGUID = '{8778ACF7-5CA9-11D3-8727-0060B0B5E137}';
|
---|
| 81 | CLASS_ContextItemCollection: TGUID = '{AC4C0272-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 82 | CLASS_ContextItem: TGUID = '{AC4C0274-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 83 | CLASS_ResponseDialog: TGUID = '{9D33ECF2-8277-11D3-8525-0000861FDD4F}';
|
---|
| 84 | IID_ISetHook: TGUID = '{8D879FDD-5FE6-11D3-8727-0060B0B5E137}';
|
---|
| 85 | CLASS_ContextorParticipant: TGUID = '{4BA034A2-D0FA-11D3-818B-0050049598B2}';
|
---|
| 86 |
|
---|
| 87 | // *********************************************************************//
|
---|
| 88 | // Declaration of Enumerations defined in Type Library
|
---|
| 89 | // *********************************************************************//
|
---|
| 90 | // Constants for enum __MIDL___MIDL_itf_VergenceContextor_0000_0002
|
---|
| 91 | type
|
---|
| 92 | __MIDL___MIDL_itf_VergenceContextor_0000_0002 = TOleEnum;
|
---|
| 93 | const
|
---|
| 94 | CsNotRunning = $00000001;
|
---|
| 95 | CsParticipating = $00000002;
|
---|
| 96 | CsSuspended = $00000003;
|
---|
| 97 |
|
---|
| 98 | // Constants for enum __MIDL___MIDL_itf_VergenceContextor_0000_0001
|
---|
| 99 | type
|
---|
| 100 | __MIDL___MIDL_itf_VergenceContextor_0000_0001 = TOleEnum;
|
---|
| 101 | const
|
---|
| 102 | ApNone = $00000001;
|
---|
| 103 | ApGet = $00000002;
|
---|
| 104 | ApSet = $00000003;
|
---|
| 105 |
|
---|
| 106 | // Constants for enum __MIDL___MIDL_itf_VergenceContextor_0000_0003
|
---|
| 107 | type
|
---|
| 108 | __MIDL___MIDL_itf_VergenceContextor_0000_0003 = TOleEnum;
|
---|
| 109 | const
|
---|
| 110 | UrCommit = $00000001;
|
---|
| 111 | UrCancel = $00000002;
|
---|
| 112 | UrBreak = $00000003;
|
---|
| 113 |
|
---|
| 114 | type
|
---|
| 115 |
|
---|
| 116 | // *********************************************************************//
|
---|
| 117 | // Forward declaration of types defined in TypeLibrary
|
---|
| 118 | // *********************************************************************//
|
---|
| 119 | _IContextChangesSink = dispinterface;
|
---|
| 120 | IContextor = interface;
|
---|
| 121 | IContextorDisp = dispinterface;
|
---|
| 122 | IContextParticipant = interface;
|
---|
| 123 | IContextParticipantDisp = dispinterface;
|
---|
| 124 | IContextItemCollection = interface;
|
---|
| 125 | IContextItemCollectionDisp = dispinterface;
|
---|
| 126 | IContextItem = interface;
|
---|
| 127 | IContextItemDisp = dispinterface;
|
---|
| 128 | IResponseContextChange = interface;
|
---|
| 129 | IResponseContextChangeDisp = dispinterface;
|
---|
| 130 | IResponseDialogAccessor = interface;
|
---|
| 131 | IResponseDialogAccessorDisp = dispinterface;
|
---|
| 132 | IContextChangesSink = interface;
|
---|
| 133 | IContextChangesSinkDisp = dispinterface;
|
---|
| 134 | IResponseDialog = interface;
|
---|
| 135 | IResponseDialogDisp = dispinterface;
|
---|
| 136 | ISetHook = interface;
|
---|
| 137 | ISetHookDisp = dispinterface;
|
---|
| 138 |
|
---|
| 139 | // *********************************************************************//
|
---|
| 140 | // Declaration of CoClasses defined in Type Library
|
---|
| 141 | // (NOTE: Here we map each CoClass to its Default Interface)
|
---|
| 142 | // *********************************************************************//
|
---|
| 143 | Contextor = IContextor;
|
---|
| 144 | ContextorControl = IContextor;
|
---|
| 145 | ContextItemCollection = IContextItemCollection;
|
---|
| 146 | ContextItem = IContextItem;
|
---|
| 147 | ResponseDialog = IResponseDialog;
|
---|
| 148 | ContextorParticipant = IContextParticipant;
|
---|
| 149 |
|
---|
| 150 |
|
---|
| 151 | // *********************************************************************//
|
---|
| 152 | // Declaration of structures, unions and aliases.
|
---|
| 153 | // *********************************************************************//
|
---|
| 154 |
|
---|
| 155 | ContextorState = __MIDL___MIDL_itf_VergenceContextor_0000_0002;
|
---|
| 156 | AccessPrivilege = __MIDL___MIDL_itf_VergenceContextor_0000_0001;
|
---|
| 157 | UserResponse = __MIDL___MIDL_itf_VergenceContextor_0000_0003;
|
---|
| 158 |
|
---|
| 159 | // *********************************************************************//
|
---|
| 160 | // DispIntf: _IContextChangesSink
|
---|
| 161 | // Flags: (4096) Dispatchable
|
---|
| 162 | // GUID: {6BED8971-B3DD-11D3-8736-0060B0B5E137}
|
---|
| 163 | // *********************************************************************//
|
---|
| 164 | _IContextChangesSink = dispinterface
|
---|
| 165 | ['{6BED8971-B3DD-11D3-8736-0060B0B5E137}']
|
---|
| 166 | procedure Pending(const aContextItemCollection: IDispatch); dispid 1;
|
---|
| 167 | procedure Committed; dispid 2;
|
---|
| 168 | procedure Canceled; dispid 3;
|
---|
| 169 | end;
|
---|
| 170 |
|
---|
| 171 | // *********************************************************************//
|
---|
| 172 | // Interface: IContextor
|
---|
| 173 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 174 | // GUID: {8D879F5D-5FE6-11D3-8727-0060B0B5E137}
|
---|
| 175 | // *********************************************************************//
|
---|
| 176 | IContextor = interface(IDispatch)
|
---|
| 177 | ['{8D879F5D-5FE6-11D3-8727-0060B0B5E137}']
|
---|
| 178 | procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool;
|
---|
| 179 | const initialNotificationFilter: WideString); safecall;
|
---|
| 180 | procedure Suspend; safecall;
|
---|
| 181 | procedure Resume; safecall;
|
---|
| 182 | function Get_State: ContextorState; safecall;
|
---|
| 183 | function GetPrivilege(const subj: WideString): AccessPrivilege; safecall;
|
---|
| 184 | function Get_CurrentContext: IContextItemCollection; safecall;
|
---|
| 185 | procedure StartContextChange; safecall;
|
---|
| 186 | function EndContextChange(commit: WordBool;
|
---|
| 187 | const aContextItemCollection: IContextItemCollection): UserResponse; safecall;
|
---|
| 188 | procedure SetSurveyResponse(const reason: WideString); safecall;
|
---|
| 189 | function Get_NotificationFilter: WideString; safecall;
|
---|
| 190 | procedure Set_NotificationFilter(const filter: WideString); safecall;
|
---|
| 191 | function Get_Name: WideString; safecall;
|
---|
| 192 | property State: ContextorState read Get_State;
|
---|
| 193 | property CurrentContext: IContextItemCollection read Get_CurrentContext;
|
---|
| 194 | property NotificationFilter: WideString read Get_NotificationFilter write Set_NotificationFilter;
|
---|
| 195 | property Name: WideString read Get_Name;
|
---|
| 196 | end;
|
---|
| 197 |
|
---|
| 198 | // *********************************************************************//
|
---|
| 199 | // DispIntf: IContextorDisp
|
---|
| 200 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 201 | // GUID: {8D879F5D-5FE6-11D3-8727-0060B0B5E137}
|
---|
| 202 | // *********************************************************************//
|
---|
| 203 | IContextorDisp = dispinterface
|
---|
| 204 | ['{8D879F5D-5FE6-11D3-8727-0060B0B5E137}']
|
---|
| 205 | procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool;
|
---|
| 206 | const initialNotificationFilter: WideString); dispid 1;
|
---|
| 207 | procedure Suspend; dispid 2;
|
---|
| 208 | procedure Resume; dispid 3;
|
---|
| 209 | property State: ContextorState readonly dispid 4;
|
---|
| 210 | function GetPrivilege(const subj: WideString): AccessPrivilege; dispid 5;
|
---|
| 211 | property CurrentContext: IContextItemCollection readonly dispid 6;
|
---|
| 212 | procedure StartContextChange; dispid 7;
|
---|
| 213 | function EndContextChange(commit: WordBool;
|
---|
| 214 | const aContextItemCollection: IContextItemCollection): UserResponse; dispid 8;
|
---|
| 215 | procedure SetSurveyResponse(const reason: WideString); dispid 9;
|
---|
| 216 | property NotificationFilter: WideString dispid 10;
|
---|
| 217 | property Name: WideString readonly dispid 11;
|
---|
| 218 | end;
|
---|
| 219 |
|
---|
| 220 | // *********************************************************************//
|
---|
| 221 | // Interface: IContextParticipant
|
---|
| 222 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 223 | // GUID: {3E3DD272-998E-11D0-808D-00A0240943E4}
|
---|
| 224 | // *********************************************************************//
|
---|
| 225 | IContextParticipant = interface(IDispatch)
|
---|
| 226 | ['{3E3DD272-998E-11D0-808D-00A0240943E4}']
|
---|
| 227 | function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; safecall;
|
---|
| 228 | procedure ContextChangesAccepted(contextCoupon: Integer); safecall;
|
---|
| 229 | procedure ContextChangesCanceled(contextCoupon: Integer); safecall;
|
---|
| 230 | procedure CommonContextTerminated; safecall;
|
---|
| 231 | procedure Ping; safecall;
|
---|
| 232 | end;
|
---|
| 233 |
|
---|
| 234 | // *********************************************************************//
|
---|
| 235 | // DispIntf: IContextParticipantDisp
|
---|
| 236 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 237 | // GUID: {3E3DD272-998E-11D0-808D-00A0240943E4}
|
---|
| 238 | // *********************************************************************//
|
---|
| 239 | IContextParticipantDisp = dispinterface
|
---|
| 240 | ['{3E3DD272-998E-11D0-808D-00A0240943E4}']
|
---|
| 241 | function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString; dispid 1610743808;
|
---|
| 242 | procedure ContextChangesAccepted(contextCoupon: Integer); dispid 1610743809;
|
---|
| 243 | procedure ContextChangesCanceled(contextCoupon: Integer); dispid 1610743810;
|
---|
| 244 | procedure CommonContextTerminated; dispid 1610743811;
|
---|
| 245 | procedure Ping; dispid 1610743812;
|
---|
| 246 | end;
|
---|
| 247 |
|
---|
| 248 | // *********************************************************************//
|
---|
| 249 | // Interface: IContextItemCollection
|
---|
| 250 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 251 | // GUID: {AC4C0271-615A-11D3-84B5-0000861FDD4F}
|
---|
| 252 | // *********************************************************************//
|
---|
| 253 | IContextItemCollection = interface(IDispatch)
|
---|
| 254 | ['{AC4C0271-615A-11D3-84B5-0000861FDD4F}']
|
---|
| 255 | function Count: Integer; safecall;
|
---|
| 256 | procedure Add(const aContextItem: IContextItem); safecall;
|
---|
| 257 | procedure Remove(const contextItemName: WideString); safecall;
|
---|
| 258 | procedure RemoveAll; safecall;
|
---|
| 259 | function Present(key: OleVariant): IContextItem; safecall;
|
---|
| 260 | function Get__NewEnum: IUnknown; safecall;
|
---|
| 261 | function Item(key: OleVariant): IContextItem; safecall;
|
---|
| 262 | property _NewEnum: IUnknown read Get__NewEnum;
|
---|
| 263 | end;
|
---|
| 264 |
|
---|
| 265 | // *********************************************************************//
|
---|
| 266 | // DispIntf: IContextItemCollectionDisp
|
---|
| 267 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 268 | // GUID: {AC4C0271-615A-11D3-84B5-0000861FDD4F}
|
---|
| 269 | // *********************************************************************//
|
---|
| 270 | IContextItemCollectionDisp = dispinterface
|
---|
| 271 | ['{AC4C0271-615A-11D3-84B5-0000861FDD4F}']
|
---|
| 272 | function Count: Integer; dispid 1;
|
---|
| 273 | procedure Add(const aContextItem: IContextItem); dispid 2;
|
---|
| 274 | procedure Remove(const contextItemName: WideString); dispid 3;
|
---|
| 275 | procedure RemoveAll; dispid 4;
|
---|
| 276 | function Present(key: OleVariant): IContextItem; dispid 5;
|
---|
| 277 | property _NewEnum: IUnknown readonly dispid -4;
|
---|
| 278 | function Item(key: OleVariant): IContextItem; dispid 0;
|
---|
| 279 | end;
|
---|
| 280 |
|
---|
| 281 | // *********************************************************************//
|
---|
| 282 | // Interface: IContextItem
|
---|
| 283 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 284 | // GUID: {AC4C0273-615A-11D3-84B5-0000861FDD4F}
|
---|
| 285 | // *********************************************************************//
|
---|
| 286 | IContextItem = interface(IDispatch)
|
---|
| 287 | ['{AC4C0273-615A-11D3-84B5-0000861FDD4F}']
|
---|
| 288 | function Get_Subject: WideString; safecall;
|
---|
| 289 | procedure Set_Subject(const pVal: WideString); safecall;
|
---|
| 290 | function Get_Role: WideString; safecall;
|
---|
| 291 | procedure Set_Role(const pVal: WideString); safecall;
|
---|
| 292 | function Get_Prefix: WideString; safecall;
|
---|
| 293 | procedure Set_Prefix(const pVal: WideString); safecall;
|
---|
| 294 | function Get_Suffix: WideString; safecall;
|
---|
| 295 | procedure Set_Suffix(const pVal: WideString); safecall;
|
---|
| 296 | function Get_Name: WideString; safecall;
|
---|
| 297 | procedure Set_Name(const pVal: WideString); safecall;
|
---|
| 298 | function Get_Value: WideString; safecall;
|
---|
| 299 | procedure Set_Value(const pVal: WideString); safecall;
|
---|
| 300 | function Clone: IContextItem; safecall;
|
---|
| 301 | property Subject: WideString read Get_Subject write Set_Subject;
|
---|
| 302 | property Role: WideString read Get_Role write Set_Role;
|
---|
| 303 | property Prefix: WideString read Get_Prefix write Set_Prefix;
|
---|
| 304 | property Suffix: WideString read Get_Suffix write Set_Suffix;
|
---|
| 305 | property Name: WideString read Get_Name write Set_Name;
|
---|
| 306 | property Value: WideString read Get_Value write Set_Value;
|
---|
| 307 | end;
|
---|
| 308 |
|
---|
| 309 | // *********************************************************************//
|
---|
| 310 | // DispIntf: IContextItemDisp
|
---|
| 311 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 312 | // GUID: {AC4C0273-615A-11D3-84B5-0000861FDD4F}
|
---|
| 313 | // *********************************************************************//
|
---|
| 314 | IContextItemDisp = dispinterface
|
---|
| 315 | ['{AC4C0273-615A-11D3-84B5-0000861FDD4F}']
|
---|
| 316 | property Subject: WideString dispid 1;
|
---|
| 317 | property Role: WideString dispid 2;
|
---|
| 318 | property Prefix: WideString dispid 3;
|
---|
| 319 | property Suffix: WideString dispid 4;
|
---|
| 320 | property Name: WideString dispid 5;
|
---|
| 321 | property Value: WideString dispid 6;
|
---|
| 322 | function Clone: IContextItem; dispid 7;
|
---|
| 323 | end;
|
---|
| 324 |
|
---|
| 325 | // *********************************************************************//
|
---|
| 326 | // Interface: IResponseContextChange
|
---|
| 327 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 328 | // GUID: {CBC6D968-9F6D-416A-8AA7-99172E588DF0}
|
---|
| 329 | // *********************************************************************//
|
---|
| 330 | IResponseContextChange = interface(IDispatch)
|
---|
| 331 | ['{CBC6D968-9F6D-416A-8AA7-99172E588DF0}']
|
---|
| 332 | procedure StartResponseContextChange; safecall;
|
---|
| 333 | function EndResponseContextChange(commit: WordBool;
|
---|
| 334 | const aContextItemCollection: IContextItemCollection;
|
---|
| 335 | var noContinue: WordBool): OleVariant; safecall;
|
---|
| 336 | procedure CommitContextChange; safecall;
|
---|
| 337 | procedure CancelContextChange; safecall;
|
---|
| 338 | end;
|
---|
| 339 |
|
---|
| 340 | // *********************************************************************//
|
---|
| 341 | // DispIntf: IResponseContextChangeDisp
|
---|
| 342 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 343 | // GUID: {CBC6D968-9F6D-416A-8AA7-99172E588DF0}
|
---|
| 344 | // *********************************************************************//
|
---|
| 345 | IResponseContextChangeDisp = dispinterface
|
---|
| 346 | ['{CBC6D968-9F6D-416A-8AA7-99172E588DF0}']
|
---|
| 347 | procedure StartResponseContextChange; dispid 1;
|
---|
| 348 | function EndResponseContextChange(commit: WordBool;
|
---|
| 349 | const aContextItemCollection: IContextItemCollection;
|
---|
| 350 | var noContinue: WordBool): OleVariant; dispid 2;
|
---|
| 351 | procedure CommitContextChange; dispid 3;
|
---|
| 352 | procedure CancelContextChange; dispid 4;
|
---|
| 353 | end;
|
---|
| 354 |
|
---|
| 355 | // *********************************************************************//
|
---|
| 356 | // Interface: IResponseDialogAccessor
|
---|
| 357 | // Flags: (4432) Hidden Dual OleAutomation Dispatchable
|
---|
| 358 | // GUID: {86592071-F3BA-11D3-8181-005004A0F801}
|
---|
| 359 | // *********************************************************************//
|
---|
| 360 | IResponseDialogAccessor = interface(IDispatch)
|
---|
| 361 | ['{86592071-F3BA-11D3-8181-005004A0F801}']
|
---|
| 362 | procedure Reset; safecall;
|
---|
| 363 | procedure Set_(const aResponseDialog: IResponseDialog); safecall;
|
---|
| 364 | end;
|
---|
| 365 |
|
---|
| 366 | // *********************************************************************//
|
---|
| 367 | // DispIntf: IResponseDialogAccessorDisp
|
---|
| 368 | // Flags: (4432) Hidden Dual OleAutomation Dispatchable
|
---|
| 369 | // GUID: {86592071-F3BA-11D3-8181-005004A0F801}
|
---|
| 370 | // *********************************************************************//
|
---|
| 371 | IResponseDialogAccessorDisp = dispinterface
|
---|
| 372 | ['{86592071-F3BA-11D3-8181-005004A0F801}']
|
---|
| 373 | procedure Reset; dispid 1;
|
---|
| 374 | procedure Set_(const aResponseDialog: IResponseDialog); dispid 2;
|
---|
| 375 | end;
|
---|
| 376 |
|
---|
| 377 | // *********************************************************************//
|
---|
| 378 | // Interface: IContextChangesSink
|
---|
| 379 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 380 | // GUID: {0B437E31-620E-11D3-84B6-0000861FDD4F}
|
---|
| 381 | // *********************************************************************//
|
---|
| 382 | IContextChangesSink = interface(IDispatch)
|
---|
| 383 | ['{0B437E31-620E-11D3-84B6-0000861FDD4F}']
|
---|
| 384 | procedure Pending(const aContextItemCollection: IDispatch); safecall;
|
---|
| 385 | procedure Committed; safecall;
|
---|
| 386 | procedure Canceled; safecall;
|
---|
| 387 | end;
|
---|
| 388 |
|
---|
| 389 | // *********************************************************************//
|
---|
| 390 | // DispIntf: IContextChangesSinkDisp
|
---|
| 391 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 392 | // GUID: {0B437E31-620E-11D3-84B6-0000861FDD4F}
|
---|
| 393 | // *********************************************************************//
|
---|
| 394 | IContextChangesSinkDisp = dispinterface
|
---|
| 395 | ['{0B437E31-620E-11D3-84B6-0000861FDD4F}']
|
---|
| 396 | procedure Pending(const aContextItemCollection: IDispatch); dispid 1;
|
---|
| 397 | procedure Committed; dispid 2;
|
---|
| 398 | procedure Canceled; dispid 3;
|
---|
| 399 | end;
|
---|
| 400 |
|
---|
| 401 | // *********************************************************************//
|
---|
| 402 | // Interface: IResponseDialog
|
---|
| 403 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 404 | // GUID: {9D33ECF1-8277-11D3-8525-0000861FDD4F}
|
---|
| 405 | // *********************************************************************//
|
---|
| 406 | IResponseDialog = interface(IDispatch)
|
---|
| 407 | ['{9D33ECF1-8277-11D3-8525-0000861FDD4F}']
|
---|
| 408 | function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; safecall;
|
---|
| 409 | end;
|
---|
| 410 |
|
---|
| 411 | // *********************************************************************//
|
---|
| 412 | // DispIntf: IResponseDialogDisp
|
---|
| 413 | // Flags: (4416) Dual OleAutomation Dispatchable
|
---|
| 414 | // GUID: {9D33ECF1-8277-11D3-8525-0000861FDD4F}
|
---|
| 415 | // *********************************************************************//
|
---|
| 416 | IResponseDialogDisp = dispinterface
|
---|
| 417 | ['{9D33ECF1-8277-11D3-8525-0000861FDD4F}']
|
---|
| 418 | function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse; dispid 1;
|
---|
| 419 | end;
|
---|
| 420 |
|
---|
| 421 | // *********************************************************************//
|
---|
| 422 | // Interface: ISetHook
|
---|
| 423 | // Flags: (4432) Hidden Dual OleAutomation Dispatchable
|
---|
| 424 | // GUID: {8D879FDD-5FE6-11D3-8727-0060B0B5E137}
|
---|
| 425 | // *********************************************************************//
|
---|
| 426 | ISetHook = interface(IDispatch)
|
---|
| 427 | ['{8D879FDD-5FE6-11D3-8727-0060B0B5E137}']
|
---|
| 428 | procedure SetParticipant(const aContextParticipant: IContextParticipant); safecall;
|
---|
| 429 | end;
|
---|
| 430 |
|
---|
| 431 | // *********************************************************************//
|
---|
| 432 | // DispIntf: ISetHookDisp
|
---|
| 433 | // Flags: (4432) Hidden Dual OleAutomation Dispatchable
|
---|
| 434 | // GUID: {8D879FDD-5FE6-11D3-8727-0060B0B5E137}
|
---|
| 435 | // *********************************************************************//
|
---|
| 436 | ISetHookDisp = dispinterface
|
---|
| 437 | ['{8D879FDD-5FE6-11D3-8727-0060B0B5E137}']
|
---|
| 438 | procedure SetParticipant(const aContextParticipant: IContextParticipant); dispid 1;
|
---|
| 439 | end;
|
---|
| 440 |
|
---|
| 441 | // *********************************************************************//
|
---|
| 442 | // The Class CoContextor provides a Create and CreateRemote method to
|
---|
| 443 | // create instances of the default interface IContextor exposed by
|
---|
| 444 | // the CoClass Contextor. The functions are intended to be used by
|
---|
| 445 | // clients wishing to automate the CoClass objects exposed by the
|
---|
| 446 | // server of this typelibrary.
|
---|
| 447 | // *********************************************************************//
|
---|
| 448 | CoContextor = class
|
---|
| 449 | class function Create: IContextor;
|
---|
| 450 | class function CreateRemote(const MachineName: string): IContextor;
|
---|
| 451 | end;
|
---|
| 452 |
|
---|
| 453 | TContextorPending = procedure(Sender: TObject; var aContextItemCollection: OleVariant) of object;
|
---|
| 454 |
|
---|
| 455 |
|
---|
| 456 | // *********************************************************************//
|
---|
| 457 | // OLE Server Proxy class declaration
|
---|
| 458 | // Server Object : TContextor
|
---|
| 459 | // Help String : Vergence Contextor
|
---|
| 460 | // Default Interface: IContextor
|
---|
| 461 | // Def. Intf. DISP? : No
|
---|
| 462 | // Event Interface: _IContextChangesSink
|
---|
| 463 | // TypeFlags : (2) CanCreate
|
---|
| 464 | // *********************************************************************//
|
---|
| 465 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 466 | TContextorProperties= class;
|
---|
| 467 | {$ENDIF}
|
---|
| 468 | TContextor = class(TOleServer)
|
---|
| 469 | private
|
---|
| 470 | FOnPending: TContextorPending;
|
---|
| 471 | FOnCommitted: TNotifyEvent;
|
---|
| 472 | FOnCanceled: TNotifyEvent;
|
---|
| 473 | FIntf: IContextor;
|
---|
| 474 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 475 | FProps: TContextorProperties;
|
---|
| 476 | function GetServerProperties: TContextorProperties;
|
---|
| 477 | {$ENDIF}
|
---|
| 478 | function GetDefaultInterface: IContextor;
|
---|
| 479 | protected
|
---|
| 480 | procedure InitServerData; override;
|
---|
| 481 | procedure InvokeEvent(DispID: TDispID; var Params: TVariantArray); override;
|
---|
| 482 | function Get_State: ContextorState;
|
---|
| 483 | function Get_CurrentContext: IContextItemCollection;
|
---|
| 484 | function Get_NotificationFilter: WideString;
|
---|
| 485 | procedure Set_NotificationFilter(const filter: WideString);
|
---|
| 486 | function Get_Name: WideString;
|
---|
| 487 | public
|
---|
| 488 | constructor Create(AOwner: TComponent); override;
|
---|
| 489 | destructor Destroy; override;
|
---|
| 490 | procedure Connect; override;
|
---|
| 491 | procedure ConnectTo(svrIntf: IContextor);
|
---|
| 492 | procedure Disconnect; override;
|
---|
| 493 | procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool;
|
---|
| 494 | const initialNotificationFilter: WideString);
|
---|
| 495 | procedure Suspend;
|
---|
| 496 | procedure Resume;
|
---|
| 497 | function GetPrivilege(const subj: WideString): AccessPrivilege;
|
---|
| 498 | procedure StartContextChange;
|
---|
| 499 | function EndContextChange(commit: WordBool;
|
---|
| 500 | const aContextItemCollection: IContextItemCollection): UserResponse;
|
---|
| 501 | procedure SetSurveyResponse(const reason: WideString);
|
---|
| 502 | property DefaultInterface: IContextor read GetDefaultInterface;
|
---|
| 503 | property State: ContextorState read Get_State;
|
---|
| 504 | property CurrentContext: IContextItemCollection read Get_CurrentContext;
|
---|
| 505 | property Name: WideString read Get_Name;
|
---|
| 506 | property NotificationFilter: WideString read Get_NotificationFilter write Set_NotificationFilter;
|
---|
| 507 | published
|
---|
| 508 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 509 | property Server: TContextorProperties read GetServerProperties;
|
---|
| 510 | {$ENDIF}
|
---|
| 511 | property OnPending: TContextorPending read FOnPending write FOnPending;
|
---|
| 512 | property OnCommitted: TNotifyEvent read FOnCommitted write FOnCommitted;
|
---|
| 513 | property OnCanceled: TNotifyEvent read FOnCanceled write FOnCanceled;
|
---|
| 514 | end;
|
---|
| 515 |
|
---|
| 516 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 517 | // *********************************************************************//
|
---|
| 518 | // OLE Server Properties Proxy Class
|
---|
| 519 | // Server Object : TContextor
|
---|
| 520 | // (This object is used by the IDE's Property Inspector to allow editing
|
---|
| 521 | // of the properties of this server)
|
---|
| 522 | // *********************************************************************//
|
---|
| 523 | TContextorProperties = class(TPersistent)
|
---|
| 524 | private
|
---|
| 525 | FServer: TContextor;
|
---|
| 526 | function GetDefaultInterface: IContextor;
|
---|
| 527 | constructor Create(AServer: TContextor);
|
---|
| 528 | protected
|
---|
| 529 | function Get_State: ContextorState;
|
---|
| 530 | function Get_CurrentContext: IContextItemCollection;
|
---|
| 531 | function Get_NotificationFilter: WideString;
|
---|
| 532 | procedure Set_NotificationFilter(const filter: WideString);
|
---|
| 533 | function Get_Name: WideString;
|
---|
| 534 | public
|
---|
| 535 | property DefaultInterface: IContextor read GetDefaultInterface;
|
---|
| 536 | published
|
---|
| 537 | property NotificationFilter: WideString read Get_NotificationFilter write Set_NotificationFilter;
|
---|
| 538 | end;
|
---|
| 539 | {$ENDIF}
|
---|
| 540 |
|
---|
| 541 |
|
---|
| 542 |
|
---|
| 543 | // *********************************************************************//
|
---|
| 544 | // OLE Control Proxy class declaration
|
---|
| 545 | // Control Name : TContextorControl
|
---|
| 546 | // Help String : Vergence ContextorControl
|
---|
| 547 | // Default Interface: IContextor
|
---|
| 548 | // Def. Intf. DISP? : No
|
---|
| 549 | // Event Interface: _IContextChangesSink
|
---|
| 550 | // TypeFlags : (2) CanCreate
|
---|
| 551 | // *********************************************************************//
|
---|
| 552 | TContextorControlPending = procedure(Sender: TObject; const aContextItemCollection: IDispatch) of object;
|
---|
| 553 |
|
---|
| 554 | TContextorControl = class(TOleControl)
|
---|
| 555 | private
|
---|
| 556 | FOnPending: TContextorControlPending;
|
---|
| 557 | FOnCommitted: TNotifyEvent;
|
---|
| 558 | FOnCanceled: TNotifyEvent;
|
---|
| 559 | FIntf: IContextor;
|
---|
| 560 | function GetControlInterface: IContextor;
|
---|
| 561 | protected
|
---|
| 562 | procedure CreateControl;
|
---|
| 563 | procedure InitControlData; override;
|
---|
| 564 | function Get_CurrentContext: IContextItemCollection;
|
---|
| 565 | public
|
---|
| 566 | procedure Run(const applicationLabel: WideString; const passcode: WideString; survey: WordBool;
|
---|
| 567 | const initialNotificationFilter: WideString);
|
---|
| 568 | procedure Suspend;
|
---|
| 569 | procedure Resume;
|
---|
| 570 | function GetPrivilege(const subj: WideString): AccessPrivilege;
|
---|
| 571 | procedure StartContextChange;
|
---|
| 572 | function EndContextChange(commit: WordBool;
|
---|
| 573 | const aContextItemCollection: IContextItemCollection): UserResponse;
|
---|
| 574 | procedure SetSurveyResponse(const reason: WideString);
|
---|
| 575 | property ControlInterface: IContextor read GetControlInterface;
|
---|
| 576 | property DefaultInterface: IContextor read GetControlInterface;
|
---|
| 577 | property State: TOleEnum index 4 read GetTOleEnumProp;
|
---|
| 578 | property CurrentContext: IContextItemCollection read Get_CurrentContext;
|
---|
| 579 | property Name: WideString index 11 read GetWideStringProp;
|
---|
| 580 | published
|
---|
| 581 | property NotificationFilter: WideString index 10 read GetWideStringProp write SetWideStringProp stored False;
|
---|
| 582 | property OnPending: TContextorControlPending read FOnPending write FOnPending;
|
---|
| 583 | property OnCommitted: TNotifyEvent read FOnCommitted write FOnCommitted;
|
---|
| 584 | property OnCanceled: TNotifyEvent read FOnCanceled write FOnCanceled;
|
---|
| 585 | end;
|
---|
| 586 |
|
---|
| 587 | // *********************************************************************//
|
---|
| 588 | // The Class CoContextItemCollection provides a Create and CreateRemote method to
|
---|
| 589 | // create instances of the default interface IContextItemCollection exposed by
|
---|
| 590 | // the CoClass ContextItemCollection. The functions are intended to be used by
|
---|
| 591 | // clients wishing to automate the CoClass objects exposed by the
|
---|
| 592 | // server of this typelibrary.
|
---|
| 593 | // *********************************************************************//
|
---|
| 594 | CoContextItemCollection = class
|
---|
| 595 | class function Create: IContextItemCollection;
|
---|
| 596 | class function CreateRemote(const MachineName: string): IContextItemCollection;
|
---|
| 597 | end;
|
---|
| 598 |
|
---|
| 599 |
|
---|
| 600 | // *********************************************************************//
|
---|
| 601 | // OLE Server Proxy class declaration
|
---|
| 602 | // Server Object : TContextItemCollection
|
---|
| 603 | // Help String : Vergence ContextItemCollection
|
---|
| 604 | // Default Interface: IContextItemCollection
|
---|
| 605 | // Def. Intf. DISP? : No
|
---|
| 606 | // Event Interface:
|
---|
| 607 | // TypeFlags : (2) CanCreate
|
---|
| 608 | // *********************************************************************//
|
---|
| 609 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 610 | TContextItemCollectionProperties= class;
|
---|
| 611 | {$ENDIF}
|
---|
| 612 | TContextItemCollection = class(TOleServer)
|
---|
| 613 | private
|
---|
| 614 | FIntf: IContextItemCollection;
|
---|
| 615 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 616 | FProps: TContextItemCollectionProperties;
|
---|
| 617 | function GetServerProperties: TContextItemCollectionProperties;
|
---|
| 618 | {$ENDIF}
|
---|
| 619 | function GetDefaultInterface: IContextItemCollection;
|
---|
| 620 | protected
|
---|
| 621 | procedure InitServerData; override;
|
---|
| 622 | function Get__NewEnum: IUnknown;
|
---|
| 623 | public
|
---|
| 624 | constructor Create(AOwner: TComponent); override;
|
---|
| 625 | destructor Destroy; override;
|
---|
| 626 | procedure Connect; override;
|
---|
| 627 | procedure ConnectTo(svrIntf: IContextItemCollection);
|
---|
| 628 | procedure Disconnect; override;
|
---|
| 629 | function Count: Integer;
|
---|
| 630 | procedure Add(const aContextItem: IContextItem);
|
---|
| 631 | procedure Remove(const contextItemName: WideString);
|
---|
| 632 | procedure RemoveAll;
|
---|
| 633 | function Present(key: OleVariant): IContextItem;
|
---|
| 634 | function Item(key: OleVariant): IContextItem;
|
---|
| 635 | property DefaultInterface: IContextItemCollection read GetDefaultInterface;
|
---|
| 636 | property _NewEnum: IUnknown read Get__NewEnum;
|
---|
| 637 | published
|
---|
| 638 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 639 | property Server: TContextItemCollectionProperties read GetServerProperties;
|
---|
| 640 | {$ENDIF}
|
---|
| 641 | end;
|
---|
| 642 |
|
---|
| 643 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 644 | // *********************************************************************//
|
---|
| 645 | // OLE Server Properties Proxy Class
|
---|
| 646 | // Server Object : TContextItemCollection
|
---|
| 647 | // (This object is used by the IDE's Property Inspector to allow editing
|
---|
| 648 | // of the properties of this server)
|
---|
| 649 | // *********************************************************************//
|
---|
| 650 | TContextItemCollectionProperties = class(TPersistent)
|
---|
| 651 | private
|
---|
| 652 | FServer: TContextItemCollection;
|
---|
| 653 | function GetDefaultInterface: IContextItemCollection;
|
---|
| 654 | constructor Create(AServer: TContextItemCollection);
|
---|
| 655 | protected
|
---|
| 656 | function Get__NewEnum: IUnknown;
|
---|
| 657 | public
|
---|
| 658 | property DefaultInterface: IContextItemCollection read GetDefaultInterface;
|
---|
| 659 | published
|
---|
| 660 | end;
|
---|
| 661 | {$ENDIF}
|
---|
| 662 |
|
---|
| 663 |
|
---|
| 664 | // *********************************************************************//
|
---|
| 665 | // The Class CoContextItem provides a Create and CreateRemote method to
|
---|
| 666 | // create instances of the default interface IContextItem exposed by
|
---|
| 667 | // the CoClass ContextItem. The functions are intended to be used by
|
---|
| 668 | // clients wishing to automate the CoClass objects exposed by the
|
---|
| 669 | // server of this typelibrary.
|
---|
| 670 | // *********************************************************************//
|
---|
| 671 | CoContextItem = class
|
---|
| 672 | class function Create: IContextItem;
|
---|
| 673 | class function CreateRemote(const MachineName: string): IContextItem;
|
---|
| 674 | end;
|
---|
| 675 |
|
---|
| 676 |
|
---|
| 677 | // *********************************************************************//
|
---|
| 678 | // OLE Server Proxy class declaration
|
---|
| 679 | // Server Object : TContextItem
|
---|
| 680 | // Help String : Vergence ContextItem
|
---|
| 681 | // Default Interface: IContextItem
|
---|
| 682 | // Def. Intf. DISP? : No
|
---|
| 683 | // Event Interface:
|
---|
| 684 | // TypeFlags : (2) CanCreate
|
---|
| 685 | // *********************************************************************//
|
---|
| 686 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 687 | TContextItemProperties= class;
|
---|
| 688 | {$ENDIF}
|
---|
| 689 | TContextItem = class(TOleServer)
|
---|
| 690 | private
|
---|
| 691 | FIntf: IContextItem;
|
---|
| 692 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 693 | FProps: TContextItemProperties;
|
---|
| 694 | function GetServerProperties: TContextItemProperties;
|
---|
| 695 | {$ENDIF}
|
---|
| 696 | function GetDefaultInterface: IContextItem;
|
---|
| 697 | protected
|
---|
| 698 | procedure InitServerData; override;
|
---|
| 699 | function Get_Subject: WideString;
|
---|
| 700 | procedure Set_Subject(const pVal: WideString);
|
---|
| 701 | function Get_Role: WideString;
|
---|
| 702 | procedure Set_Role(const pVal: WideString);
|
---|
| 703 | function Get_Prefix: WideString;
|
---|
| 704 | procedure Set_Prefix(const pVal: WideString);
|
---|
| 705 | function Get_Suffix: WideString;
|
---|
| 706 | procedure Set_Suffix(const pVal: WideString);
|
---|
| 707 | function Get_Name: WideString;
|
---|
| 708 | procedure Set_Name(const pVal: WideString);
|
---|
| 709 | function Get_Value: WideString;
|
---|
| 710 | procedure Set_Value(const pVal: WideString);
|
---|
| 711 | public
|
---|
| 712 | constructor Create(AOwner: TComponent); override;
|
---|
| 713 | destructor Destroy; override;
|
---|
| 714 | procedure Connect; override;
|
---|
| 715 | procedure ConnectTo(svrIntf: IContextItem);
|
---|
| 716 | procedure Disconnect; override;
|
---|
| 717 | function Clone: IContextItem;
|
---|
| 718 | property DefaultInterface: IContextItem read GetDefaultInterface;
|
---|
| 719 | property Subject: WideString read Get_Subject write Set_Subject;
|
---|
| 720 | property Role: WideString read Get_Role write Set_Role;
|
---|
| 721 | property Prefix: WideString read Get_Prefix write Set_Prefix;
|
---|
| 722 | property Suffix: WideString read Get_Suffix write Set_Suffix;
|
---|
| 723 | property Name: WideString read Get_Name write Set_Name;
|
---|
| 724 | property Value: WideString read Get_Value write Set_Value;
|
---|
| 725 | published
|
---|
| 726 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 727 | property Server: TContextItemProperties read GetServerProperties;
|
---|
| 728 | {$ENDIF}
|
---|
| 729 | end;
|
---|
| 730 |
|
---|
| 731 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 732 | // *********************************************************************//
|
---|
| 733 | // OLE Server Properties Proxy Class
|
---|
| 734 | // Server Object : TContextItem
|
---|
| 735 | // (This object is used by the IDE's Property Inspector to allow editing
|
---|
| 736 | // of the properties of this server)
|
---|
| 737 | // *********************************************************************//
|
---|
| 738 | TContextItemProperties = class(TPersistent)
|
---|
| 739 | private
|
---|
| 740 | FServer: TContextItem;
|
---|
| 741 | function GetDefaultInterface: IContextItem;
|
---|
| 742 | constructor Create(AServer: TContextItem);
|
---|
| 743 | protected
|
---|
| 744 | function Get_Subject: WideString;
|
---|
| 745 | procedure Set_Subject(const pVal: WideString);
|
---|
| 746 | function Get_Role: WideString;
|
---|
| 747 | procedure Set_Role(const pVal: WideString);
|
---|
| 748 | function Get_Prefix: WideString;
|
---|
| 749 | procedure Set_Prefix(const pVal: WideString);
|
---|
| 750 | function Get_Suffix: WideString;
|
---|
| 751 | procedure Set_Suffix(const pVal: WideString);
|
---|
| 752 | function Get_Name: WideString;
|
---|
| 753 | procedure Set_Name(const pVal: WideString);
|
---|
| 754 | function Get_Value: WideString;
|
---|
| 755 | procedure Set_Value(const pVal: WideString);
|
---|
| 756 | public
|
---|
| 757 | property DefaultInterface: IContextItem read GetDefaultInterface;
|
---|
| 758 | published
|
---|
| 759 | property Subject: WideString read Get_Subject write Set_Subject;
|
---|
| 760 | property Role: WideString read Get_Role write Set_Role;
|
---|
| 761 | property Prefix: WideString read Get_Prefix write Set_Prefix;
|
---|
| 762 | property Suffix: WideString read Get_Suffix write Set_Suffix;
|
---|
| 763 | property Name: WideString read Get_Name write Set_Name;
|
---|
| 764 | property Value: WideString read Get_Value write Set_Value;
|
---|
| 765 | end;
|
---|
| 766 | {$ENDIF}
|
---|
| 767 |
|
---|
| 768 |
|
---|
| 769 | // *********************************************************************//
|
---|
| 770 | // The Class CoResponseDialog provides a Create and CreateRemote method to
|
---|
| 771 | // create instances of the default interface IResponseDialog exposed by
|
---|
| 772 | // the CoClass ResponseDialog. The functions are intended to be used by
|
---|
| 773 | // clients wishing to automate the CoClass objects exposed by the
|
---|
| 774 | // server of this typelibrary.
|
---|
| 775 | // *********************************************************************//
|
---|
| 776 | CoResponseDialog = class
|
---|
| 777 | class function Create: IResponseDialog;
|
---|
| 778 | class function CreateRemote(const MachineName: string): IResponseDialog;
|
---|
| 779 | end;
|
---|
| 780 |
|
---|
| 781 |
|
---|
| 782 | // *********************************************************************//
|
---|
| 783 | // OLE Server Proxy class declaration
|
---|
| 784 | // Server Object : TResponseDialog
|
---|
| 785 | // Help String : Vergence ResponseDialog
|
---|
| 786 | // Default Interface: IResponseDialog
|
---|
| 787 | // Def. Intf. DISP? : No
|
---|
| 788 | // Event Interface:
|
---|
| 789 | // TypeFlags : (2) CanCreate
|
---|
| 790 | // *********************************************************************//
|
---|
| 791 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 792 | TResponseDialogProperties= class;
|
---|
| 793 | {$ENDIF}
|
---|
| 794 | TResponseDialog = class(TOleServer)
|
---|
| 795 | private
|
---|
| 796 | FIntf: IResponseDialog;
|
---|
| 797 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 798 | FProps: TResponseDialogProperties;
|
---|
| 799 | function GetServerProperties: TResponseDialogProperties;
|
---|
| 800 | {$ENDIF}
|
---|
| 801 | function GetDefaultInterface: IResponseDialog;
|
---|
| 802 | protected
|
---|
| 803 | procedure InitServerData; override;
|
---|
| 804 | public
|
---|
| 805 | constructor Create(AOwner: TComponent); override;
|
---|
| 806 | destructor Destroy; override;
|
---|
| 807 | procedure Connect; override;
|
---|
| 808 | procedure ConnectTo(svrIntf: IResponseDialog);
|
---|
| 809 | procedure Disconnect; override;
|
---|
| 810 | function ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse;
|
---|
| 811 | property DefaultInterface: IResponseDialog read GetDefaultInterface;
|
---|
| 812 | published
|
---|
| 813 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 814 | property Server: TResponseDialogProperties read GetServerProperties;
|
---|
| 815 | {$ENDIF}
|
---|
| 816 | end;
|
---|
| 817 |
|
---|
| 818 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 819 | // *********************************************************************//
|
---|
| 820 | // OLE Server Properties Proxy Class
|
---|
| 821 | // Server Object : TResponseDialog
|
---|
| 822 | // (This object is used by the IDE's Property Inspector to allow editing
|
---|
| 823 | // of the properties of this server)
|
---|
| 824 | // *********************************************************************//
|
---|
| 825 | TResponseDialogProperties = class(TPersistent)
|
---|
| 826 | private
|
---|
| 827 | FServer: TResponseDialog;
|
---|
| 828 | function GetDefaultInterface: IResponseDialog;
|
---|
| 829 | constructor Create(AServer: TResponseDialog);
|
---|
| 830 | protected
|
---|
| 831 | public
|
---|
| 832 | property DefaultInterface: IResponseDialog read GetDefaultInterface;
|
---|
| 833 | published
|
---|
| 834 | end;
|
---|
| 835 | {$ENDIF}
|
---|
| 836 |
|
---|
| 837 |
|
---|
| 838 | // *********************************************************************//
|
---|
| 839 | // The Class CoContextorParticipant provides a Create and CreateRemote method to
|
---|
| 840 | // create instances of the default interface IContextParticipant exposed by
|
---|
| 841 | // the CoClass ContextorParticipant. The functions are intended to be used by
|
---|
| 842 | // clients wishing to automate the CoClass objects exposed by the
|
---|
| 843 | // server of this typelibrary.
|
---|
| 844 | // *********************************************************************//
|
---|
| 845 | CoContextorParticipant = class
|
---|
| 846 | class function Create: IContextParticipant;
|
---|
| 847 | class function CreateRemote(const MachineName: string): IContextParticipant;
|
---|
| 848 | end;
|
---|
| 849 |
|
---|
| 850 |
|
---|
| 851 | // *********************************************************************//
|
---|
| 852 | // OLE Server Proxy class declaration
|
---|
| 853 | // Server Object : TContextorParticipant
|
---|
| 854 | // Help String : ContextorParticipant Class
|
---|
| 855 | // Default Interface: IContextParticipant
|
---|
| 856 | // Def. Intf. DISP? : No
|
---|
| 857 | // Event Interface:
|
---|
| 858 | // TypeFlags : (2) CanCreate
|
---|
| 859 | // *********************************************************************//
|
---|
| 860 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 861 | TContextorParticipantProperties= class;
|
---|
| 862 | {$ENDIF}
|
---|
| 863 | TContextorParticipant = class(TOleServer)
|
---|
| 864 | private
|
---|
| 865 | FIntf: IContextParticipant;
|
---|
| 866 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 867 | FProps: TContextorParticipantProperties;
|
---|
| 868 | function GetServerProperties: TContextorParticipantProperties;
|
---|
| 869 | {$ENDIF}
|
---|
| 870 | function GetDefaultInterface: IContextParticipant;
|
---|
| 871 | protected
|
---|
| 872 | procedure InitServerData; override;
|
---|
| 873 | public
|
---|
| 874 | constructor Create(AOwner: TComponent); override;
|
---|
| 875 | destructor Destroy; override;
|
---|
| 876 | procedure Connect; override;
|
---|
| 877 | procedure ConnectTo(svrIntf: IContextParticipant);
|
---|
| 878 | procedure Disconnect; override;
|
---|
| 879 | function ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString;
|
---|
| 880 | procedure ContextChangesAccepted(contextCoupon: Integer);
|
---|
| 881 | procedure ContextChangesCanceled(contextCoupon: Integer);
|
---|
| 882 | procedure CommonContextTerminated;
|
---|
| 883 | procedure Ping;
|
---|
| 884 | property DefaultInterface: IContextParticipant read GetDefaultInterface;
|
---|
| 885 | published
|
---|
| 886 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 887 | property Server: TContextorParticipantProperties read GetServerProperties;
|
---|
| 888 | {$ENDIF}
|
---|
| 889 | end;
|
---|
| 890 |
|
---|
| 891 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 892 | // *********************************************************************//
|
---|
| 893 | // OLE Server Properties Proxy Class
|
---|
| 894 | // Server Object : TContextorParticipant
|
---|
| 895 | // (This object is used by the IDE's Property Inspector to allow editing
|
---|
| 896 | // of the properties of this server)
|
---|
| 897 | // *********************************************************************//
|
---|
| 898 | TContextorParticipantProperties = class(TPersistent)
|
---|
| 899 | private
|
---|
| 900 | FServer: TContextorParticipant;
|
---|
| 901 | function GetDefaultInterface: IContextParticipant;
|
---|
| 902 | constructor Create(AServer: TContextorParticipant);
|
---|
| 903 | protected
|
---|
| 904 | public
|
---|
| 905 | property DefaultInterface: IContextParticipant read GetDefaultInterface;
|
---|
| 906 | published
|
---|
| 907 | end;
|
---|
| 908 | {$ENDIF}
|
---|
| 909 |
|
---|
| 910 | {
|
---|
| 911 | procedure Register;
|
---|
| 912 | }
|
---|
| 913 | implementation
|
---|
| 914 |
|
---|
| 915 | uses ComObj;
|
---|
| 916 |
|
---|
| 917 | class function CoContextor.Create: IContextor;
|
---|
| 918 | begin
|
---|
| 919 | Result := CreateComObject(CLASS_Contextor) as IContextor;
|
---|
| 920 | end;
|
---|
| 921 |
|
---|
| 922 | class function CoContextor.CreateRemote(const MachineName: string): IContextor;
|
---|
| 923 | begin
|
---|
| 924 | Result := CreateRemoteComObject(MachineName, CLASS_Contextor) as IContextor;
|
---|
| 925 | end;
|
---|
| 926 |
|
---|
| 927 | procedure TContextor.InitServerData;
|
---|
| 928 | const
|
---|
| 929 | CServerData: TServerData = (
|
---|
| 930 | ClassID: '{D5C9CC98-5FDB-11D3-8727-0060B0B5E137}';
|
---|
| 931 | IntfIID: '{8D879F5D-5FE6-11D3-8727-0060B0B5E137}';
|
---|
| 932 | EventIID: '{6BED8971-B3DD-11D3-8736-0060B0B5E137}';
|
---|
| 933 | LicenseKey: nil;
|
---|
| 934 | Version: 500);
|
---|
| 935 | begin
|
---|
| 936 | ServerData := @CServerData;
|
---|
| 937 | end;
|
---|
| 938 |
|
---|
| 939 | procedure TContextor.Connect;
|
---|
| 940 | var
|
---|
| 941 | punk: IUnknown;
|
---|
| 942 | begin
|
---|
| 943 | if FIntf = nil then
|
---|
| 944 | begin
|
---|
| 945 | punk := GetServer;
|
---|
| 946 | ConnectEvents(punk);
|
---|
| 947 | Fintf:= punk as IContextor;
|
---|
| 948 | end;
|
---|
| 949 | end;
|
---|
| 950 |
|
---|
| 951 | procedure TContextor.ConnectTo(svrIntf: IContextor);
|
---|
| 952 | begin
|
---|
| 953 | Disconnect;
|
---|
| 954 | FIntf := svrIntf;
|
---|
| 955 | ConnectEvents(FIntf);
|
---|
| 956 | end;
|
---|
| 957 |
|
---|
| 958 | procedure TContextor.DisConnect;
|
---|
| 959 | begin
|
---|
| 960 | if Fintf <> nil then
|
---|
| 961 | begin
|
---|
| 962 | DisconnectEvents(FIntf);
|
---|
| 963 | FIntf := nil;
|
---|
| 964 | end;
|
---|
| 965 | end;
|
---|
| 966 |
|
---|
| 967 | function TContextor.GetDefaultInterface: IContextor;
|
---|
| 968 | begin
|
---|
| 969 | if FIntf = nil then
|
---|
| 970 | Connect;
|
---|
| 971 | Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
|
---|
| 972 | Result := FIntf;
|
---|
| 973 | end;
|
---|
| 974 |
|
---|
| 975 | constructor TContextor.Create(AOwner: TComponent);
|
---|
| 976 | begin
|
---|
| 977 | inherited Create(AOwner);
|
---|
| 978 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 979 | FProps := TContextorProperties.Create(Self);
|
---|
| 980 | {$ENDIF}
|
---|
| 981 | end;
|
---|
| 982 |
|
---|
| 983 | destructor TContextor.Destroy;
|
---|
| 984 | begin
|
---|
| 985 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 986 | FProps.Free;
|
---|
| 987 | {$ENDIF}
|
---|
| 988 | inherited Destroy;
|
---|
| 989 | end;
|
---|
| 990 |
|
---|
| 991 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 992 | function TContextor.GetServerProperties: TContextorProperties;
|
---|
| 993 | begin
|
---|
| 994 | Result := FProps;
|
---|
| 995 | end;
|
---|
| 996 | {$ENDIF}
|
---|
| 997 |
|
---|
| 998 | procedure TContextor.InvokeEvent(DispID: TDispID; var Params: TVariantArray);
|
---|
| 999 | begin
|
---|
| 1000 | case DispID of
|
---|
| 1001 | -1: Exit; // DISPID_UNKNOWN
|
---|
| 1002 | 1: if Assigned(FOnPending) then
|
---|
| 1003 | FOnPending(Self, Params[0] {const IDispatch});
|
---|
| 1004 | 2: if Assigned(FOnCommitted) then
|
---|
| 1005 | FOnCommitted(Self);
|
---|
| 1006 | 3: if Assigned(FOnCanceled) then
|
---|
| 1007 | FOnCanceled(Self);
|
---|
| 1008 | end; {case DispID}
|
---|
| 1009 | end;
|
---|
| 1010 |
|
---|
| 1011 | function TContextor.Get_State: ContextorState;
|
---|
| 1012 | begin
|
---|
| 1013 | Result := DefaultInterface.Get_State;
|
---|
| 1014 | end;
|
---|
| 1015 |
|
---|
| 1016 | function TContextor.Get_CurrentContext: IContextItemCollection;
|
---|
| 1017 | begin
|
---|
| 1018 | Result := DefaultInterface.Get_CurrentContext;
|
---|
| 1019 | end;
|
---|
| 1020 |
|
---|
| 1021 | function TContextor.Get_NotificationFilter: WideString;
|
---|
| 1022 | begin
|
---|
| 1023 | Result := DefaultInterface.Get_NotificationFilter;
|
---|
| 1024 | end;
|
---|
| 1025 |
|
---|
| 1026 | procedure TContextor.Set_NotificationFilter(const filter: WideString);
|
---|
| 1027 | begin
|
---|
| 1028 | DefaultInterface.Set_NotificationFilter(filter);
|
---|
| 1029 | end;
|
---|
| 1030 |
|
---|
| 1031 | function TContextor.Get_Name: WideString;
|
---|
| 1032 | begin
|
---|
| 1033 | Result := DefaultInterface.Get_Name;
|
---|
| 1034 | end;
|
---|
| 1035 |
|
---|
| 1036 | procedure TContextor.Run(const applicationLabel: WideString; const passcode: WideString;
|
---|
| 1037 | survey: WordBool; const initialNotificationFilter: WideString);
|
---|
| 1038 | begin
|
---|
| 1039 | DefaultInterface.Run(applicationLabel, passcode, survey, initialNotificationFilter);
|
---|
| 1040 | end;
|
---|
| 1041 |
|
---|
| 1042 | procedure TContextor.Suspend;
|
---|
| 1043 | begin
|
---|
| 1044 | DefaultInterface.Suspend;
|
---|
| 1045 | end;
|
---|
| 1046 |
|
---|
| 1047 | procedure TContextor.Resume;
|
---|
| 1048 | begin
|
---|
| 1049 | DefaultInterface.Resume;
|
---|
| 1050 | end;
|
---|
| 1051 |
|
---|
| 1052 | function TContextor.GetPrivilege(const subj: WideString): AccessPrivilege;
|
---|
| 1053 | begin
|
---|
| 1054 | Result := DefaultInterface.GetPrivilege(subj);
|
---|
| 1055 | end;
|
---|
| 1056 |
|
---|
| 1057 | procedure TContextor.StartContextChange;
|
---|
| 1058 | begin
|
---|
| 1059 | DefaultInterface.StartContextChange;
|
---|
| 1060 | end;
|
---|
| 1061 |
|
---|
| 1062 | function TContextor.EndContextChange(commit: WordBool;
|
---|
| 1063 | const aContextItemCollection: IContextItemCollection): UserResponse;
|
---|
| 1064 | begin
|
---|
| 1065 | Result := DefaultInterface.EndContextChange(commit, aContextItemCollection);
|
---|
| 1066 | end;
|
---|
| 1067 |
|
---|
| 1068 | procedure TContextor.SetSurveyResponse(const reason: WideString);
|
---|
| 1069 | begin
|
---|
| 1070 | DefaultInterface.SetSurveyResponse(reason);
|
---|
| 1071 | end;
|
---|
| 1072 |
|
---|
| 1073 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1074 | constructor TContextorProperties.Create(AServer: TContextor);
|
---|
| 1075 | begin
|
---|
| 1076 | inherited Create;
|
---|
| 1077 | FServer := AServer;
|
---|
| 1078 | end;
|
---|
| 1079 |
|
---|
| 1080 | function TContextorProperties.GetDefaultInterface: IContextor;
|
---|
| 1081 | begin
|
---|
| 1082 | Result := FServer.DefaultInterface;
|
---|
| 1083 | end;
|
---|
| 1084 |
|
---|
| 1085 | function TContextorProperties.Get_State: ContextorState;
|
---|
| 1086 | begin
|
---|
| 1087 | Result := DefaultInterface.Get_State;
|
---|
| 1088 | end;
|
---|
| 1089 |
|
---|
| 1090 | function TContextorProperties.Get_CurrentContext: IContextItemCollection;
|
---|
| 1091 | begin
|
---|
| 1092 | Result := DefaultInterface.Get_CurrentContext;
|
---|
| 1093 | end;
|
---|
| 1094 |
|
---|
| 1095 | function TContextorProperties.Get_NotificationFilter: WideString;
|
---|
| 1096 | begin
|
---|
| 1097 | Result := DefaultInterface.Get_NotificationFilter;
|
---|
| 1098 | end;
|
---|
| 1099 |
|
---|
| 1100 | procedure TContextorProperties.Set_NotificationFilter(const filter: WideString);
|
---|
| 1101 | begin
|
---|
| 1102 | DefaultInterface.Set_NotificationFilter(filter);
|
---|
| 1103 | end;
|
---|
| 1104 |
|
---|
| 1105 | function TContextorProperties.Get_Name: WideString;
|
---|
| 1106 | begin
|
---|
| 1107 | Result := DefaultInterface.Get_Name;
|
---|
| 1108 | end;
|
---|
| 1109 |
|
---|
| 1110 | {$ENDIF}
|
---|
| 1111 |
|
---|
| 1112 | procedure TContextorControl.InitControlData;
|
---|
| 1113 | const
|
---|
| 1114 | CEventDispIDs: array [0..2] of DWORD = (
|
---|
| 1115 | $00000001, $00000002, $00000003);
|
---|
| 1116 | CControlData: TControlData2 = (
|
---|
| 1117 | ClassID: '{8778ACF7-5CA9-11D3-8727-0060B0B5E137}';
|
---|
| 1118 | EventIID: '{6BED8971-B3DD-11D3-8736-0060B0B5E137}';
|
---|
| 1119 | EventCount: 3;
|
---|
| 1120 | EventDispIDs: @CEventDispIDs;
|
---|
| 1121 | LicenseKey: nil (*HR:$80004002*);
|
---|
| 1122 | Flags: $00000000;
|
---|
| 1123 | Version: 401);
|
---|
| 1124 | begin
|
---|
| 1125 | ControlData := @CControlData;
|
---|
| 1126 | // TControlData2(CControlData).FirstEventOfs := Cardinal(@@FOnPending) - Cardinal(Self);
|
---|
| 1127 | end;
|
---|
| 1128 |
|
---|
| 1129 | procedure TContextorControl.CreateControl;
|
---|
| 1130 |
|
---|
| 1131 | procedure DoCreate;
|
---|
| 1132 | begin
|
---|
| 1133 | FIntf := IUnknown(OleObject) as IContextor;
|
---|
| 1134 | end;
|
---|
| 1135 |
|
---|
| 1136 | begin
|
---|
| 1137 | if FIntf = nil then DoCreate;
|
---|
| 1138 | end;
|
---|
| 1139 |
|
---|
| 1140 | function TContextorControl.GetControlInterface: IContextor;
|
---|
| 1141 | begin
|
---|
| 1142 | CreateControl;
|
---|
| 1143 | Result := FIntf;
|
---|
| 1144 | end;
|
---|
| 1145 |
|
---|
| 1146 | function TContextorControl.Get_CurrentContext: IContextItemCollection;
|
---|
| 1147 | begin
|
---|
| 1148 | Result := DefaultInterface.Get_CurrentContext;
|
---|
| 1149 | end;
|
---|
| 1150 |
|
---|
| 1151 | procedure TContextorControl.Run(const applicationLabel: WideString; const passcode: WideString;
|
---|
| 1152 | survey: WordBool; const initialNotificationFilter: WideString);
|
---|
| 1153 | begin
|
---|
| 1154 | DefaultInterface.Run(applicationLabel, passcode, survey, initialNotificationFilter);
|
---|
| 1155 | end;
|
---|
| 1156 |
|
---|
| 1157 | procedure TContextorControl.Suspend;
|
---|
| 1158 | begin
|
---|
| 1159 | DefaultInterface.Suspend;
|
---|
| 1160 | end;
|
---|
| 1161 |
|
---|
| 1162 | procedure TContextorControl.Resume;
|
---|
| 1163 | begin
|
---|
| 1164 | DefaultInterface.Resume;
|
---|
| 1165 | end;
|
---|
| 1166 |
|
---|
| 1167 | function TContextorControl.GetPrivilege(const subj: WideString): AccessPrivilege;
|
---|
| 1168 | begin
|
---|
| 1169 | Result := DefaultInterface.GetPrivilege(subj);
|
---|
| 1170 | end;
|
---|
| 1171 |
|
---|
| 1172 | procedure TContextorControl.StartContextChange;
|
---|
| 1173 | begin
|
---|
| 1174 | DefaultInterface.StartContextChange;
|
---|
| 1175 | end;
|
---|
| 1176 |
|
---|
| 1177 | function TContextorControl.EndContextChange(commit: WordBool;
|
---|
| 1178 | const aContextItemCollection: IContextItemCollection): UserResponse;
|
---|
| 1179 | begin
|
---|
| 1180 | Result := DefaultInterface.EndContextChange(commit, aContextItemCollection);
|
---|
| 1181 | end;
|
---|
| 1182 |
|
---|
| 1183 | procedure TContextorControl.SetSurveyResponse(const reason: WideString);
|
---|
| 1184 | begin
|
---|
| 1185 | DefaultInterface.SetSurveyResponse(reason);
|
---|
| 1186 | end;
|
---|
| 1187 |
|
---|
| 1188 | class function CoContextItemCollection.Create: IContextItemCollection;
|
---|
| 1189 | begin
|
---|
| 1190 | Result := CreateComObject(CLASS_ContextItemCollection) as IContextItemCollection;
|
---|
| 1191 | end;
|
---|
| 1192 |
|
---|
| 1193 | class function CoContextItemCollection.CreateRemote(const MachineName: string): IContextItemCollection;
|
---|
| 1194 | begin
|
---|
| 1195 | Result := CreateRemoteComObject(MachineName, CLASS_ContextItemCollection) as IContextItemCollection;
|
---|
| 1196 | end;
|
---|
| 1197 |
|
---|
| 1198 | procedure TContextItemCollection.InitServerData;
|
---|
| 1199 | const
|
---|
| 1200 | CServerData: TServerData = (
|
---|
| 1201 | ClassID: '{AC4C0272-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 1202 | IntfIID: '{AC4C0271-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 1203 | EventIID: '';
|
---|
| 1204 | LicenseKey: nil;
|
---|
| 1205 | Version: 500);
|
---|
| 1206 | begin
|
---|
| 1207 | ServerData := @CServerData;
|
---|
| 1208 | end;
|
---|
| 1209 |
|
---|
| 1210 | procedure TContextItemCollection.Connect;
|
---|
| 1211 | var
|
---|
| 1212 | punk: IUnknown;
|
---|
| 1213 | begin
|
---|
| 1214 | if FIntf = nil then
|
---|
| 1215 | begin
|
---|
| 1216 | punk := GetServer;
|
---|
| 1217 | Fintf:= punk as IContextItemCollection;
|
---|
| 1218 | end;
|
---|
| 1219 | end;
|
---|
| 1220 |
|
---|
| 1221 | procedure TContextItemCollection.ConnectTo(svrIntf: IContextItemCollection);
|
---|
| 1222 | begin
|
---|
| 1223 | Disconnect;
|
---|
| 1224 | FIntf := svrIntf;
|
---|
| 1225 | end;
|
---|
| 1226 |
|
---|
| 1227 | procedure TContextItemCollection.DisConnect;
|
---|
| 1228 | begin
|
---|
| 1229 | if Fintf <> nil then
|
---|
| 1230 | begin
|
---|
| 1231 | FIntf := nil;
|
---|
| 1232 | end;
|
---|
| 1233 | end;
|
---|
| 1234 |
|
---|
| 1235 | function TContextItemCollection.GetDefaultInterface: IContextItemCollection;
|
---|
| 1236 | begin
|
---|
| 1237 | if FIntf = nil then
|
---|
| 1238 | Connect;
|
---|
| 1239 | Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
|
---|
| 1240 | Result := FIntf;
|
---|
| 1241 | end;
|
---|
| 1242 |
|
---|
| 1243 | constructor TContextItemCollection.Create(AOwner: TComponent);
|
---|
| 1244 | begin
|
---|
| 1245 | inherited Create(AOwner);
|
---|
| 1246 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1247 | FProps := TContextItemCollectionProperties.Create(Self);
|
---|
| 1248 | {$ENDIF}
|
---|
| 1249 | end;
|
---|
| 1250 |
|
---|
| 1251 | destructor TContextItemCollection.Destroy;
|
---|
| 1252 | begin
|
---|
| 1253 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1254 | FProps.Free;
|
---|
| 1255 | {$ENDIF}
|
---|
| 1256 | inherited Destroy;
|
---|
| 1257 | end;
|
---|
| 1258 |
|
---|
| 1259 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1260 | function TContextItemCollection.GetServerProperties: TContextItemCollectionProperties;
|
---|
| 1261 | begin
|
---|
| 1262 | Result := FProps;
|
---|
| 1263 | end;
|
---|
| 1264 | {$ENDIF}
|
---|
| 1265 |
|
---|
| 1266 | function TContextItemCollection.Get__NewEnum: IUnknown;
|
---|
| 1267 | begin
|
---|
| 1268 | Result := DefaultInterface.Get__NewEnum;
|
---|
| 1269 | end;
|
---|
| 1270 |
|
---|
| 1271 | function TContextItemCollection.Count: Integer;
|
---|
| 1272 | begin
|
---|
| 1273 | Result := DefaultInterface.Count;
|
---|
| 1274 | end;
|
---|
| 1275 |
|
---|
| 1276 | procedure TContextItemCollection.Add(const aContextItem: IContextItem);
|
---|
| 1277 | begin
|
---|
| 1278 | DefaultInterface.Add(aContextItem);
|
---|
| 1279 | end;
|
---|
| 1280 |
|
---|
| 1281 | procedure TContextItemCollection.Remove(const contextItemName: WideString);
|
---|
| 1282 | begin
|
---|
| 1283 | DefaultInterface.Remove(contextItemName);
|
---|
| 1284 | end;
|
---|
| 1285 |
|
---|
| 1286 | procedure TContextItemCollection.RemoveAll;
|
---|
| 1287 | begin
|
---|
| 1288 | DefaultInterface.RemoveAll;
|
---|
| 1289 | end;
|
---|
| 1290 |
|
---|
| 1291 | function TContextItemCollection.Present(key: OleVariant): IContextItem;
|
---|
| 1292 | begin
|
---|
| 1293 | Result := DefaultInterface.Present(key);
|
---|
| 1294 | end;
|
---|
| 1295 |
|
---|
| 1296 | function TContextItemCollection.Item(key: OleVariant): IContextItem;
|
---|
| 1297 | begin
|
---|
| 1298 | Result := DefaultInterface.Item(key);
|
---|
| 1299 | end;
|
---|
| 1300 |
|
---|
| 1301 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1302 | constructor TContextItemCollectionProperties.Create(AServer: TContextItemCollection);
|
---|
| 1303 | begin
|
---|
| 1304 | inherited Create;
|
---|
| 1305 | FServer := AServer;
|
---|
| 1306 | end;
|
---|
| 1307 |
|
---|
| 1308 | function TContextItemCollectionProperties.GetDefaultInterface: IContextItemCollection;
|
---|
| 1309 | begin
|
---|
| 1310 | Result := FServer.DefaultInterface;
|
---|
| 1311 | end;
|
---|
| 1312 |
|
---|
| 1313 | function TContextItemCollectionProperties.Get__NewEnum: IUnknown;
|
---|
| 1314 | begin
|
---|
| 1315 | Result := DefaultInterface.Get__NewEnum;
|
---|
| 1316 | end;
|
---|
| 1317 |
|
---|
| 1318 | {$ENDIF}
|
---|
| 1319 |
|
---|
| 1320 | class function CoContextItem.Create: IContextItem;
|
---|
| 1321 | begin
|
---|
| 1322 | Result := CreateComObject(CLASS_ContextItem) as IContextItem;
|
---|
| 1323 | end;
|
---|
| 1324 |
|
---|
| 1325 | class function CoContextItem.CreateRemote(const MachineName: string): IContextItem;
|
---|
| 1326 | begin
|
---|
| 1327 | Result := CreateRemoteComObject(MachineName, CLASS_ContextItem) as IContextItem;
|
---|
| 1328 | end;
|
---|
| 1329 |
|
---|
| 1330 | procedure TContextItem.InitServerData;
|
---|
| 1331 | const
|
---|
| 1332 | CServerData: TServerData = (
|
---|
| 1333 | ClassID: '{AC4C0274-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 1334 | IntfIID: '{AC4C0273-615A-11D3-84B5-0000861FDD4F}';
|
---|
| 1335 | EventIID: '';
|
---|
| 1336 | LicenseKey: nil;
|
---|
| 1337 | Version: 500);
|
---|
| 1338 | begin
|
---|
| 1339 | ServerData := @CServerData;
|
---|
| 1340 | end;
|
---|
| 1341 |
|
---|
| 1342 | procedure TContextItem.Connect;
|
---|
| 1343 | var
|
---|
| 1344 | punk: IUnknown;
|
---|
| 1345 | begin
|
---|
| 1346 | if FIntf = nil then
|
---|
| 1347 | begin
|
---|
| 1348 | punk := GetServer;
|
---|
| 1349 | Fintf:= punk as IContextItem;
|
---|
| 1350 | end;
|
---|
| 1351 | end;
|
---|
| 1352 |
|
---|
| 1353 | procedure TContextItem.ConnectTo(svrIntf: IContextItem);
|
---|
| 1354 | begin
|
---|
| 1355 | Disconnect;
|
---|
| 1356 | FIntf := svrIntf;
|
---|
| 1357 | end;
|
---|
| 1358 |
|
---|
| 1359 | procedure TContextItem.DisConnect;
|
---|
| 1360 | begin
|
---|
| 1361 | if Fintf <> nil then
|
---|
| 1362 | begin
|
---|
| 1363 | FIntf := nil;
|
---|
| 1364 | end;
|
---|
| 1365 | end;
|
---|
| 1366 |
|
---|
| 1367 | function TContextItem.GetDefaultInterface: IContextItem;
|
---|
| 1368 | begin
|
---|
| 1369 | if FIntf = nil then
|
---|
| 1370 | Connect;
|
---|
| 1371 | Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
|
---|
| 1372 | Result := FIntf;
|
---|
| 1373 | end;
|
---|
| 1374 |
|
---|
| 1375 | constructor TContextItem.Create(AOwner: TComponent);
|
---|
| 1376 | begin
|
---|
| 1377 | inherited Create(AOwner);
|
---|
| 1378 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1379 | FProps := TContextItemProperties.Create(Self);
|
---|
| 1380 | {$ENDIF}
|
---|
| 1381 | end;
|
---|
| 1382 |
|
---|
| 1383 | destructor TContextItem.Destroy;
|
---|
| 1384 | begin
|
---|
| 1385 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1386 | FProps.Free;
|
---|
| 1387 | {$ENDIF}
|
---|
| 1388 | inherited Destroy;
|
---|
| 1389 | end;
|
---|
| 1390 |
|
---|
| 1391 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1392 | function TContextItem.GetServerProperties: TContextItemProperties;
|
---|
| 1393 | begin
|
---|
| 1394 | Result := FProps;
|
---|
| 1395 | end;
|
---|
| 1396 | {$ENDIF}
|
---|
| 1397 |
|
---|
| 1398 | function TContextItem.Get_Subject: WideString;
|
---|
| 1399 | begin
|
---|
| 1400 | Result := DefaultInterface.Get_Subject;
|
---|
| 1401 | end;
|
---|
| 1402 |
|
---|
| 1403 | procedure TContextItem.Set_Subject(const pVal: WideString);
|
---|
| 1404 | begin
|
---|
| 1405 | DefaultInterface.Set_Subject(pVal);
|
---|
| 1406 | end;
|
---|
| 1407 |
|
---|
| 1408 | function TContextItem.Get_Role: WideString;
|
---|
| 1409 | begin
|
---|
| 1410 | Result := DefaultInterface.Get_Role;
|
---|
| 1411 | end;
|
---|
| 1412 |
|
---|
| 1413 | procedure TContextItem.Set_Role(const pVal: WideString);
|
---|
| 1414 | begin
|
---|
| 1415 | DefaultInterface.Set_Role(pVal);
|
---|
| 1416 | end;
|
---|
| 1417 |
|
---|
| 1418 | function TContextItem.Get_Prefix: WideString;
|
---|
| 1419 | begin
|
---|
| 1420 | Result := DefaultInterface.Get_Prefix;
|
---|
| 1421 | end;
|
---|
| 1422 |
|
---|
| 1423 | procedure TContextItem.Set_Prefix(const pVal: WideString);
|
---|
| 1424 | begin
|
---|
| 1425 | DefaultInterface.Set_Prefix(pVal);
|
---|
| 1426 | end;
|
---|
| 1427 |
|
---|
| 1428 | function TContextItem.Get_Suffix: WideString;
|
---|
| 1429 | begin
|
---|
| 1430 | Result := DefaultInterface.Get_Suffix;
|
---|
| 1431 | end;
|
---|
| 1432 |
|
---|
| 1433 | procedure TContextItem.Set_Suffix(const pVal: WideString);
|
---|
| 1434 | begin
|
---|
| 1435 | DefaultInterface.Set_Suffix(pVal);
|
---|
| 1436 | end;
|
---|
| 1437 |
|
---|
| 1438 | function TContextItem.Get_Name: WideString;
|
---|
| 1439 | begin
|
---|
| 1440 | Result := DefaultInterface.Get_Name;
|
---|
| 1441 | end;
|
---|
| 1442 |
|
---|
| 1443 | procedure TContextItem.Set_Name(const pVal: WideString);
|
---|
| 1444 | begin
|
---|
| 1445 | DefaultInterface.Set_Name(pVal);
|
---|
| 1446 | end;
|
---|
| 1447 |
|
---|
| 1448 | function TContextItem.Get_Value: WideString;
|
---|
| 1449 | begin
|
---|
| 1450 | Result := DefaultInterface.Get_Value;
|
---|
| 1451 | end;
|
---|
| 1452 |
|
---|
| 1453 | procedure TContextItem.Set_Value(const pVal: WideString);
|
---|
| 1454 | begin
|
---|
| 1455 | DefaultInterface.Set_Value(pVal);
|
---|
| 1456 | end;
|
---|
| 1457 |
|
---|
| 1458 | function TContextItem.Clone: IContextItem;
|
---|
| 1459 | begin
|
---|
| 1460 | Result := DefaultInterface.Clone;
|
---|
| 1461 | end;
|
---|
| 1462 |
|
---|
| 1463 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1464 | constructor TContextItemProperties.Create(AServer: TContextItem);
|
---|
| 1465 | begin
|
---|
| 1466 | inherited Create;
|
---|
| 1467 | FServer := AServer;
|
---|
| 1468 | end;
|
---|
| 1469 |
|
---|
| 1470 | function TContextItemProperties.GetDefaultInterface: IContextItem;
|
---|
| 1471 | begin
|
---|
| 1472 | Result := FServer.DefaultInterface;
|
---|
| 1473 | end;
|
---|
| 1474 |
|
---|
| 1475 | function TContextItemProperties.Get_Subject: WideString;
|
---|
| 1476 | begin
|
---|
| 1477 | Result := DefaultInterface.Get_Subject;
|
---|
| 1478 | end;
|
---|
| 1479 |
|
---|
| 1480 | procedure TContextItemProperties.Set_Subject(const pVal: WideString);
|
---|
| 1481 | begin
|
---|
| 1482 | DefaultInterface.Set_Subject(pVal);
|
---|
| 1483 | end;
|
---|
| 1484 |
|
---|
| 1485 | function TContextItemProperties.Get_Role: WideString;
|
---|
| 1486 | begin
|
---|
| 1487 | Result := DefaultInterface.Get_Role;
|
---|
| 1488 | end;
|
---|
| 1489 |
|
---|
| 1490 | procedure TContextItemProperties.Set_Role(const pVal: WideString);
|
---|
| 1491 | begin
|
---|
| 1492 | DefaultInterface.Set_Role(pVal);
|
---|
| 1493 | end;
|
---|
| 1494 |
|
---|
| 1495 | function TContextItemProperties.Get_Prefix: WideString;
|
---|
| 1496 | begin
|
---|
| 1497 | Result := DefaultInterface.Get_Prefix;
|
---|
| 1498 | end;
|
---|
| 1499 |
|
---|
| 1500 | procedure TContextItemProperties.Set_Prefix(const pVal: WideString);
|
---|
| 1501 | begin
|
---|
| 1502 | DefaultInterface.Set_Prefix(pVal);
|
---|
| 1503 | end;
|
---|
| 1504 |
|
---|
| 1505 | function TContextItemProperties.Get_Suffix: WideString;
|
---|
| 1506 | begin
|
---|
| 1507 | Result := DefaultInterface.Get_Suffix;
|
---|
| 1508 | end;
|
---|
| 1509 |
|
---|
| 1510 | procedure TContextItemProperties.Set_Suffix(const pVal: WideString);
|
---|
| 1511 | begin
|
---|
| 1512 | DefaultInterface.Set_Suffix(pVal);
|
---|
| 1513 | end;
|
---|
| 1514 |
|
---|
| 1515 | function TContextItemProperties.Get_Name: WideString;
|
---|
| 1516 | begin
|
---|
| 1517 | Result := DefaultInterface.Get_Name;
|
---|
| 1518 | end;
|
---|
| 1519 |
|
---|
| 1520 | procedure TContextItemProperties.Set_Name(const pVal: WideString);
|
---|
| 1521 | begin
|
---|
| 1522 | DefaultInterface.Set_Name(pVal);
|
---|
| 1523 | end;
|
---|
| 1524 |
|
---|
| 1525 | function TContextItemProperties.Get_Value: WideString;
|
---|
| 1526 | begin
|
---|
| 1527 | Result := DefaultInterface.Get_Value;
|
---|
| 1528 | end;
|
---|
| 1529 |
|
---|
| 1530 | procedure TContextItemProperties.Set_Value(const pVal: WideString);
|
---|
| 1531 | begin
|
---|
| 1532 | DefaultInterface.Set_Value(pVal);
|
---|
| 1533 | end;
|
---|
| 1534 |
|
---|
| 1535 | {$ENDIF}
|
---|
| 1536 |
|
---|
| 1537 | class function CoResponseDialog.Create: IResponseDialog;
|
---|
| 1538 | begin
|
---|
| 1539 | Result := CreateComObject(CLASS_ResponseDialog) as IResponseDialog;
|
---|
| 1540 | end;
|
---|
| 1541 |
|
---|
| 1542 | class function CoResponseDialog.CreateRemote(const MachineName: string): IResponseDialog;
|
---|
| 1543 | begin
|
---|
| 1544 | Result := CreateRemoteComObject(MachineName, CLASS_ResponseDialog) as IResponseDialog;
|
---|
| 1545 | end;
|
---|
| 1546 |
|
---|
| 1547 | procedure TResponseDialog.InitServerData;
|
---|
| 1548 | const
|
---|
| 1549 | CServerData: TServerData = (
|
---|
| 1550 | ClassID: '{9D33ECF2-8277-11D3-8525-0000861FDD4F}';
|
---|
| 1551 | IntfIID: '{9D33ECF1-8277-11D3-8525-0000861FDD4F}';
|
---|
| 1552 | EventIID: '';
|
---|
| 1553 | LicenseKey: nil;
|
---|
| 1554 | Version: 500);
|
---|
| 1555 | begin
|
---|
| 1556 | ServerData := @CServerData;
|
---|
| 1557 | end;
|
---|
| 1558 |
|
---|
| 1559 | procedure TResponseDialog.Connect;
|
---|
| 1560 | var
|
---|
| 1561 | punk: IUnknown;
|
---|
| 1562 | begin
|
---|
| 1563 | if FIntf = nil then
|
---|
| 1564 | begin
|
---|
| 1565 | punk := GetServer;
|
---|
| 1566 | Fintf:= punk as IResponseDialog;
|
---|
| 1567 | end;
|
---|
| 1568 | end;
|
---|
| 1569 |
|
---|
| 1570 | procedure TResponseDialog.ConnectTo(svrIntf: IResponseDialog);
|
---|
| 1571 | begin
|
---|
| 1572 | Disconnect;
|
---|
| 1573 | FIntf := svrIntf;
|
---|
| 1574 | end;
|
---|
| 1575 |
|
---|
| 1576 | procedure TResponseDialog.DisConnect;
|
---|
| 1577 | begin
|
---|
| 1578 | if Fintf <> nil then
|
---|
| 1579 | begin
|
---|
| 1580 | FIntf := nil;
|
---|
| 1581 | end;
|
---|
| 1582 | end;
|
---|
| 1583 |
|
---|
| 1584 | function TResponseDialog.GetDefaultInterface: IResponseDialog;
|
---|
| 1585 | begin
|
---|
| 1586 | if FIntf = nil then
|
---|
| 1587 | Connect;
|
---|
| 1588 | Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
|
---|
| 1589 | Result := FIntf;
|
---|
| 1590 | end;
|
---|
| 1591 |
|
---|
| 1592 | constructor TResponseDialog.Create(AOwner: TComponent);
|
---|
| 1593 | begin
|
---|
| 1594 | inherited Create(AOwner);
|
---|
| 1595 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1596 | FProps := TResponseDialogProperties.Create(Self);
|
---|
| 1597 | {$ENDIF}
|
---|
| 1598 | end;
|
---|
| 1599 |
|
---|
| 1600 | destructor TResponseDialog.Destroy;
|
---|
| 1601 | begin
|
---|
| 1602 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1603 | FProps.Free;
|
---|
| 1604 | {$ENDIF}
|
---|
| 1605 | inherited Destroy;
|
---|
| 1606 | end;
|
---|
| 1607 |
|
---|
| 1608 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1609 | function TResponseDialog.GetServerProperties: TResponseDialogProperties;
|
---|
| 1610 | begin
|
---|
| 1611 | Result := FProps;
|
---|
| 1612 | end;
|
---|
| 1613 | {$ENDIF}
|
---|
| 1614 |
|
---|
| 1615 | function TResponseDialog.ProcessSurveyResults(responses: OleVariant; noContinue: WordBool): UserResponse;
|
---|
| 1616 | begin
|
---|
| 1617 | Result := DefaultInterface.ProcessSurveyResults(responses, noContinue);
|
---|
| 1618 | end;
|
---|
| 1619 |
|
---|
| 1620 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1621 | constructor TResponseDialogProperties.Create(AServer: TResponseDialog);
|
---|
| 1622 | begin
|
---|
| 1623 | inherited Create;
|
---|
| 1624 | FServer := AServer;
|
---|
| 1625 | end;
|
---|
| 1626 |
|
---|
| 1627 | function TResponseDialogProperties.GetDefaultInterface: IResponseDialog;
|
---|
| 1628 | begin
|
---|
| 1629 | Result := FServer.DefaultInterface;
|
---|
| 1630 | end;
|
---|
| 1631 |
|
---|
| 1632 | {$ENDIF}
|
---|
| 1633 |
|
---|
| 1634 | class function CoContextorParticipant.Create: IContextParticipant;
|
---|
| 1635 | begin
|
---|
| 1636 | Result := CreateComObject(CLASS_ContextorParticipant) as IContextParticipant;
|
---|
| 1637 | end;
|
---|
| 1638 |
|
---|
| 1639 | class function CoContextorParticipant.CreateRemote(const MachineName: string): IContextParticipant;
|
---|
| 1640 | begin
|
---|
| 1641 | Result := CreateRemoteComObject(MachineName, CLASS_ContextorParticipant) as IContextParticipant;
|
---|
| 1642 | end;
|
---|
| 1643 |
|
---|
| 1644 | procedure TContextorParticipant.InitServerData;
|
---|
| 1645 | const
|
---|
| 1646 | CServerData: TServerData = (
|
---|
| 1647 | ClassID: '{4BA034A2-D0FA-11D3-818B-0050049598B2}';
|
---|
| 1648 | IntfIID: '{3E3DD272-998E-11D0-808D-00A0240943E4}';
|
---|
| 1649 | EventIID: '';
|
---|
| 1650 | LicenseKey: nil;
|
---|
| 1651 | Version: 500);
|
---|
| 1652 | begin
|
---|
| 1653 | ServerData := @CServerData;
|
---|
| 1654 | end;
|
---|
| 1655 |
|
---|
| 1656 | procedure TContextorParticipant.Connect;
|
---|
| 1657 | var
|
---|
| 1658 | punk: IUnknown;
|
---|
| 1659 | begin
|
---|
| 1660 | if FIntf = nil then
|
---|
| 1661 | begin
|
---|
| 1662 | punk := GetServer;
|
---|
| 1663 | Fintf:= punk as IContextParticipant;
|
---|
| 1664 | end;
|
---|
| 1665 | end;
|
---|
| 1666 |
|
---|
| 1667 | procedure TContextorParticipant.ConnectTo(svrIntf: IContextParticipant);
|
---|
| 1668 | begin
|
---|
| 1669 | Disconnect;
|
---|
| 1670 | FIntf := svrIntf;
|
---|
| 1671 | end;
|
---|
| 1672 |
|
---|
| 1673 | procedure TContextorParticipant.DisConnect;
|
---|
| 1674 | begin
|
---|
| 1675 | if Fintf <> nil then
|
---|
| 1676 | begin
|
---|
| 1677 | FIntf := nil;
|
---|
| 1678 | end;
|
---|
| 1679 | end;
|
---|
| 1680 |
|
---|
| 1681 | function TContextorParticipant.GetDefaultInterface: IContextParticipant;
|
---|
| 1682 | begin
|
---|
| 1683 | if FIntf = nil then
|
---|
| 1684 | Connect;
|
---|
| 1685 | Assert(FIntf <> nil, 'DefaultInterface is NULL. Component is not connected to Server. You must call ''Connect'' or ''ConnectTo'' before this operation');
|
---|
| 1686 | Result := FIntf;
|
---|
| 1687 | end;
|
---|
| 1688 |
|
---|
| 1689 | constructor TContextorParticipant.Create(AOwner: TComponent);
|
---|
| 1690 | begin
|
---|
| 1691 | inherited Create(AOwner);
|
---|
| 1692 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1693 | FProps := TContextorParticipantProperties.Create(Self);
|
---|
| 1694 | {$ENDIF}
|
---|
| 1695 | end;
|
---|
| 1696 |
|
---|
| 1697 | destructor TContextorParticipant.Destroy;
|
---|
| 1698 | begin
|
---|
| 1699 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1700 | FProps.Free;
|
---|
| 1701 | {$ENDIF}
|
---|
| 1702 | inherited Destroy;
|
---|
| 1703 | end;
|
---|
| 1704 |
|
---|
| 1705 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1706 | function TContextorParticipant.GetServerProperties: TContextorParticipantProperties;
|
---|
| 1707 | begin
|
---|
| 1708 | Result := FProps;
|
---|
| 1709 | end;
|
---|
| 1710 | {$ENDIF}
|
---|
| 1711 |
|
---|
| 1712 | function TContextorParticipant.ContextChangesPending(contextCoupon: Integer; var reason: WideString): WideString;
|
---|
| 1713 | begin
|
---|
| 1714 | Result := DefaultInterface.ContextChangesPending(contextCoupon, reason);
|
---|
| 1715 | end;
|
---|
| 1716 |
|
---|
| 1717 | procedure TContextorParticipant.ContextChangesAccepted(contextCoupon: Integer);
|
---|
| 1718 | begin
|
---|
| 1719 | DefaultInterface.ContextChangesAccepted(contextCoupon);
|
---|
| 1720 | end;
|
---|
| 1721 |
|
---|
| 1722 | procedure TContextorParticipant.ContextChangesCanceled(contextCoupon: Integer);
|
---|
| 1723 | begin
|
---|
| 1724 | DefaultInterface.ContextChangesCanceled(contextCoupon);
|
---|
| 1725 | end;
|
---|
| 1726 |
|
---|
| 1727 | procedure TContextorParticipant.CommonContextTerminated;
|
---|
| 1728 | begin
|
---|
| 1729 | DefaultInterface.CommonContextTerminated;
|
---|
| 1730 | end;
|
---|
| 1731 |
|
---|
| 1732 | procedure TContextorParticipant.Ping;
|
---|
| 1733 | begin
|
---|
| 1734 | DefaultInterface.Ping;
|
---|
| 1735 | end;
|
---|
| 1736 |
|
---|
| 1737 | {$IFDEF LIVE_SERVER_AT_DESIGN_TIME}
|
---|
| 1738 | constructor TContextorParticipantProperties.Create(AServer: TContextorParticipant);
|
---|
| 1739 | begin
|
---|
| 1740 | inherited Create;
|
---|
| 1741 | FServer := AServer;
|
---|
| 1742 | end;
|
---|
| 1743 |
|
---|
| 1744 | function TContextorParticipantProperties.GetDefaultInterface: IContextParticipant;
|
---|
| 1745 | begin
|
---|
| 1746 | Result := FServer.DefaultInterface;
|
---|
| 1747 | end;
|
---|
| 1748 |
|
---|
| 1749 | {$ENDIF}
|
---|
| 1750 | {
|
---|
| 1751 | procedure Register;
|
---|
| 1752 | begin
|
---|
| 1753 | RegisterComponents('Kernel',[TContextorControl]);
|
---|
| 1754 | RegisterComponents('Kernel',[TContextor, TContextItemCollection, TContextItem, TResponseDialog,
|
---|
| 1755 | TContextorParticipant]);
|
---|
| 1756 | end;
|
---|
| 1757 | }
|
---|
| 1758 | end.
|
---|