Glossary
Contents
A
B
C
D
E
F
G
H
I
J
K
L
Line Mode
Line mode specify how TWSocket component has to handle incomming data packets to produce OnDataAvailable event. When line mode is off (the default), TWSocket will trigger an OnDataAvailable event for each data packet incomming. When line mode is on (Set LineMode property to TRUE), then TWSocket will buffer incomming data packet and scan for an end of line delimiter (Property LineEnd which default to CR/LF pair). If no end of line delimiter is found, then the packet is kept in the internal buffer and no OnDataAvailable event is triggered. When the next data packet is received, again a check is done to find the first end of line. When one if found, the component triggers the OnDataAvailable event. When the Receive method is called from the OnDataAvailable event, it will return data up to and including the first end of line found. If a second one is received, another OnDataAvailable will be triggered immediately. The net effect is that the user see data comming line by line. Component user doesn't have to worry about packet fragmentation.