* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
Author: François PIETTE
Description: ClientWSocket component. It handle the client connection for
the application server for F. Piette's middleware (MidWare).
Do not confuse TClientWSocket with TAppSrvClient which is the
client application side. TClientWSocket is used on the server
side to handle client connections, TAppSrvClient is used on the
client side to connect to the application server. Both components
are talking to each other.
EMail: francois.piette@pophost.eunet.be francois.piette@ping.be
francois.piette@rtfm.be http://www.rtfm.be/fpiette
Creation: February 17, 1998
Version: 1.05
Support: Use the mailing list midware@rtfm.be See website for details.
Legal issues: Copyright (C) 1997, 1998 by François PIETTE
Rue de Grady 24, 4053 Embourg, Belgium. Fax: +32-4-365.74.56
This software is provided 'as-is', without any express or
implied warranty. In no event will the author be held liable
for any damages arising from the use of this software.
Permission is granted to anyone to use this software and or any
derived or altered versions for any purpose, excluding commercial
applications. You can use this software for personal or internal
use only. You may distribute it freely untouched.
The following restrictions applies:
1. The origin of this software must not be misrepresented, you
must not claim that you wrote the original software.
2. If you use this software in a product, an acknowledgment in
the product documentation and displayed on screen is required.
The text must be: "This product is based on MidWare. Freeware
source code is available at http://www.rtfm.be/fpiette."
3. Altered source versions must be plainly marked as such, and
must not be misrepresented as being the original software.
4. This notice may not be removed or altered from any source
distribution and must be added to the product documentation.
Updates:
Mar 27, 1998 V1.01 Added a ConnectedSince and LastCommand properties
Added a Banner property, must be a single line
Apr 10, 1998 V1.01 Removed aSocket from StartConnection.
May 18, 1998 V1.03 Implemented command timeout to disconnect an inactive
user after a period of inactivity (30 minutes by default).
The CheckCommandTimeOut has to be called to make this feature
work. It's the server component who do it. Using a TTimer here
would consume too much resources.
Jun 01, 1998 V1.04 Removed beta status. Changed "legal stuff" to prohibe
commercial applications whithout an agreement.
Jun 07, 1998 V1.05 Added ReplyHeader, ReplyHeaderLen, ReplyBody, ReplyBodyLen,
and SendReply to allow easy encryption and compression
implementation.
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * TClientWSocket - :TClientWSocket is a specialized TWSocket which handle a single client
connected to the application server.
TCommandEvent
TDisplayEvent
TTimeoutEvent
ApSrvCliVersion
DefaultRcvSize
TCommandEvent = procedure (Sender : TObject; CmdBuf : PChar; CmdLen : Integer) of object
TDisplayEvent = procedure (Sender : TObject; Msg : String) of object
TTimeoutEvent = procedure (Sender : TObject; var CanClose : Boolean) of object
ApSrvCliVersion = 105
Enable partial boolean evaluation } {$T-} { Untyped pointers } {$J+} { Allow typed constant to be modified
DefaultRcvSize = 64536