TTMSFNCWebPushServer Class
Web push application server component that exposes the endpoints clients use to obtain the public application server key and to register, update, remove, and (de)activate push subscriptions.
API unit family: TMS.TMSFNCWebPushServer
Inherits from: TTMSFNCCustomWebPushServer
Syntax
TTMSFNCWebPushServer = class(TTMSFNCCustomWebPushServer)
Remarks
This is the published descendant intended for design-time placement; it surfaces the configuration properties and events declared by its base class.
Properties
| Name | Description |
|---|---|
| Active | Controls whether the server is listening for connections. Set to True to start listening on the configured bindings and False to stop. (inherited from TTMSFNCCustomWebPushServer) |
| Bindings | Collection of socket bindings (addresses and ports) the server listens on. Assigning a value replaces the current bindings. (inherited from TTMSFNCCustomWebPushServer) |
| DefaultHTTPPort | Plain (non-secure) port the server listens on. (inherited from TTMSFNCCustomWebPushServer) |
| DefaultHTTPSPort | Secure port the server listens on for encrypted connections. (inherited from TTMSFNCCustomWebPushServer) |
| PushDB | Database component that stores and retrieves push subscriptions. (inherited from TTMSFNCCustomWebPushServer) |
| PushRequestPath | URL path segments the server uses for each subscription and user state endpoint. (inherited from TTMSFNCCustomWebPushServer) |
| SSLCertPath | File paths to the SSL certificate, private key, and root certificate used for secure connections. (inherited from TTMSFNCCustomWebPushServer) |
| VapidSettings | Application server (VAPID) key settings used to identify the server to push services and to generate the public key returned to clients. (inherited from TTMSFNCCustomWebPushServer) |
Events
| Name | Description |
|---|---|
| OnCreateIOHandler | Occurs while the server is created, allowing a custom secure connection handler to be supplied instead of the default one. (inherited from TTMSFNCCustomWebPushServer) |
| OnHTTPRequest | Occurs for each incoming HTTP request, allowing the request to be handled before the built-in endpoint routing runs. (inherited from TTMSFNCCustomWebPushServer) |
| OnQuerySSLPort | Occurs to decide whether a listening port serves secure connections. (inherited from TTMSFNCCustomWebPushServer) |
| OnRegisterSubscription | Occurs when a request to register a new subscription arrives, allowing custom processing of the payload. (inherited from TTMSFNCCustomWebPushServer) |
| OnRequestVapidKey | Occurs when a client requests the public application server key. (inherited from TTMSFNCCustomWebPushServer) |
| OnUnregisterSubscription | Occurs when a request to remove a subscription arrives, allowing custom processing of the payload. (inherited from TTMSFNCCustomWebPushServer) |
| OnUpdateSubscription | Occurs when a request to replace an existing subscription with a renewed one arrives, allowing custom processing of the payload. (inherited from TTMSFNCCustomWebPushServer) |
| OnUserActiveStateChange | Occurs when a request changes whether a user is active or inactive, allowing custom processing of the payload. (inherited from TTMSFNCCustomWebPushServer) |