LocalPort Property
The TCP port in the local host where the class listens.
Syntax
ANSI (Cross Platform) int GetLocalPort();
int SetLocalPort(int iLocalPort); Unicode (Windows) INT GetLocalPort();
INT SetLocalPort(INT iLocalPort);
@property (nonatomic,readwrite,assign,getter=localPort,setter=setLocalPort:) int localPort; - (int)localPort; - (void)setLocalPort:(int)newLocalPort;
#define PID_WEBSOCKETSERVER_LOCALPORT 22 IPWORKSWS_EXTERNAL void* IPWORKSWS_CALL IPWorksWS_WebSocketServer_Get(void *lpObj, int propid, int arridx, int *lpcbVal, int64 *lpllVal); IPWORKSWS_EXTERNAL int IPWORKSWS_CALL IPWorksWS_WebSocketServer_Set(void *lpObj, int propid, int arridx, const void *val, int cbVal);
Default Value
0
Remarks
This property must be set before the class can start listening. If its value is 0, then the TCP/IP subsystem picks a port number at random. The port number can be found by checking the value of this property after the class is listening (ie. after successfully assigning True to the Listening property).
The service port is not shared among servers so two classs cannot be listening on the same port at the same time.
Data Type
Integer