TwclRfCommServerConnection Class

The base class for all WCL Bluetooth RFCOMM based server connections.

Namespace: wclBluetooth
type
 TwclRfCommServerConnection = class(TwclServerDataConnection)
 end;

The TwclRfCommServerConnection type exposes the following members.

Show:
 NameDescription
Create(TwclBluetoothRadio)

Create new Classis Bluetooth server connection.

Top
Show:
 NameDescription
AssignedChannel

Gets the assigned RFCOMM channel number.

Authentication

Gets the authentication value.

Channel

Gets the service RFCOMM channel number. 0 to auto detection.

ClientsCount

Gets the number of connected clients. (Inherited from TwclServerConnection.)

Clients[Integer]

Gets a connected client by its index. (Inherited from TwclServerConnection.)

Encryption

Gets the encryption state of the connection.

OnListen

The event fires when the serve ris ready to accept incomming connections (is in listening state). (Inherited from TwclServerConnection.)

Radio

Gets the connection owner.

Receiver

Gets the connection message receiver object. (Inherited from TwclCustomConnection.)

Service

Gets the Bluetooth service UUID used for connection.

ServiceName

Gets the service name.

State

Gets the connection state. (Inherited from TwclServerConnection.)

ThreadId

Gets the connection's thread ID. (Inherited from TwclCustomConnection.)

Top
Show:
 NameDescription
Close

The method disconnects all connected clients and closes the server. (Inherited from TwclServerConnection.)

CreateNewClientConnection(Pointer,Cardinal)

Sends a notification to the main thread to create and init new client connection. (Inherited from TwclServerConnection.)

DoClosed(Integer)

Fires the OnClosed event. (Inherited from TwclServerConnection.)

DoConnect(TwclServerClientConnection,Integer)

Fires the OnConnect event. (Inherited from TwclServerConnection.)

DoData(TwclServerClientDataConnection,Pointer,Cardinal)

Fires the OnData event. (Inherited from TwclServerDataConnection.)

DoDisconnect(TwclServerClientConnection,Integer)

Fires the OnDisconnect event. (Inherited from TwclServerConnection.)

DoGetSdpAttributes(TwclBluetoothSdpProtocols,TwclBluetoothSdpProfiles,TwclBluetoothSdpFormats,Cardinal)

Fires the GetSdpAttributes event.

DoListen

Fires the OnListen event. (Inherited from TwclServerConnection.)

Enter

Enters the connection's critical section. (Inherited from TwclCustomConnection.)

HalClose

Implements a hardware-dependent method to stop listening. (Inherited from TwclServerConnection.)

HalCreateClient

The method crteates a hardware and transport-dependent client connection. (Inherited from TwclServerConnection.)

HalListen(THandle)

Implements a hardware-dependent method for listening the client connections. (Inherited from TwclServerConnection.)

HalPrepare

Implements a hardware-dependent code that prepares for listening. (Inherited from TwclServerConnection.)

InternalClose(Integer)

Closes the server. (Inherited from TwclServerConnection.)

Leave

Exists *leaves) the connection's critical section. (Inherited from TwclCustomConnection.)

Listen(TGUID,string,Byte,Boolean,Boolean)

The method starts listening for client connections.

MessageReceived(TwclMessage)

The method called when a new notification message received. (Overrides TwclServerConnection.MessageReceived(TwclMessage).)

SetAssignedChannel(Byte)

Sets the assigned RFCOMM channel number.

SetClientEvents(TwclServerClientConnection)

The method sets the client's event handlers. (Overrides TwclServerConnection.SetClientEvents(TwclServerClientConnection).)

Top
Show:
 NameDescription
GetSdpAttributes

The event fires when the server builds SDP record for the service it runs. If an application needs to provide additinal attributes it should handle the event. By default no additional attributes is added for the SDP record.

OnClosed

The event fires when the server is closed. (Inherited from TwclServerConnection.)

OnConnect

The event fires when a remote client is connected to the server. (Inherited from TwclServerConnection.)

OnData

The event fires when new data is received from the connected remote device. (Inherited from TwclServerDataConnection.)

OnDisconnect

The event fires when a remote client has disconnected from the server. (Inherited from TwclServerConnection.)

Top

An application must never create instances of this class directly. Instead of that an application must use related methods from the TwclBluetoothRadio object.