class %CSP.WebLink
extends %CSP.Page
Provide a weblink compatability layer in CSP
Notes for using this class
1. The WebLink URL
The conventional URL to a WebLink application is:
/scripts/mgwms32.dll?MGWLPN=[server]
The URL to this compatibility layer is:
/[application_path]/%CSP.WebLink.cls
The 'application_path' should be defined within the CSP Gateway
such that it routes requests to the appropriate Cache server.
On the Cache side the path should be configured such that the
requests are processed in the NameSpace containing the WebLink
application.
This change of URL should not pose too much of a problem provided
links within applications are properly constructed using the
%KEY("MGWLIB") variable and not hard-coded as '/scripts/mgwms32.dll'.
2. State-aware mode
State aware mode is supported (i.e. session.Preserve = 1).
However, the WebLink state-aware SEND method is not supported.
The SEND method essentially inverts the WebLink request processing
protocol such that the mechanics of reading and responding to a
request can be embedded deep inside a legacy MUMPS application.
3. Event Broker
The WebLink equivalent of CSP's hyperevents.
Event Broker requests are supported provided they are configured
to run over HTTP (modes 10 or 11) and not over the dedicated
TCP port(mode 0).
4. PDQWeb compatibility mode
Not supported
Parameters
|
Properties
|
Methods
|
Queries
|
Indices
|
ForeignKeys
|
Triggers
|
|
|
3
|
|
|
|
|
classmethod OnHTTPHeader(ByRef OutputBody As %Boolean)
as %Status
Event handler for PAGE event: this is invoked in order to
send HTTP headers. The default action is to invoke the WriteHTTPHeader()
of the %CSP.Response which generates HTTP 1.0 standard
headers. Set OutputBody to 0 to prevent prevent OnPage
from being called, leave it unchanged otherwise. Returns a %Status code.
classmethod OnPage()
as %Status
Event handler for PAGE event: this is invoked in order to
generate the content of a csp page.
classmethod OnPreHTTP()
as %Boolean
Event handler for PreHTTP event: this is invoked before
the HTTP headers for a CSP page have been sent. All changes to the
%CSP.Response class, such as adding cookies, HTTP headers,
setting the content type etc. must be made from within the OnPreHTTP() method.
Also changes to the state of the CSP application such as changing
%session.EndSession or %session.AppTimeout must be made within the OnPreHTTP() method.
It is prefered that changes to %session.Preserve are also made in the OnPreHTTP() method
as this is more efficient, although it is supported in any section of the page.
Return 0 to prevent OnPage from being called.