Description Starts accepting packets.
Return Type
A Long value.
Syntax
object.Start (Type, Port)
The Start Method syntax has these parts:
|
object | An expression evaluating to an object of type VPNMediator. | Type | Required. A SearchEnum enumeration, as described in settings. | Port | Required. A Long value.
UDP port where will mediator listen for incoming search requests. |
Settings The settings for Type are:
| SrchUDPSingle | 0 | Search using single UDP request. |
| SrchUDPDouble | 1 | Search using double UDP request. |
| SrchNetInfo | 2 | Search using provided remote details. |
Remarks Start method will start your mediator on
predefined port, and will wait for incoming packets. When new packet
arrives, MediatorConnected event will fire with details on peer that
searches for other peer. Once both peers connect,
MediatorExchangeData
event is fired notifying you that packet is sent back to the peer that
searched for them. When peer stops sending packets to the mediator,
MediatorDisconnected event will be fired. -
Please note that currently mediator only works with UDP packets. When
peers search for other peers, they send packet after packet (in
predefined interval, for predefined time) until they receive response -
or until peer's timeouts expire.
|