www.pudn.com > BluetoothChat.rar > BluetoothAdvertiser.h
#ifndef BLUETOOTHADVERTISER_H_ #define BLUETOOTHADVERTISER_H_ #include// CLASS DECLARATION class CBluetoothAdvertiser : public CBase { public: // Constructors static CBluetoothAdvertiser* NewL(); static CBluetoothAdvertiser* NewLC(); ~CBluetoothAdvertiser(); private: // Constructors - Symbian 2nd Stage CBluetoothAdvertiser(); void ConstructL(); public: // Functionaility void StartAdvertisingL(TInt aPort); void StopAdvertisingL(); public: // Getters & Setters inline TBool IsAdvertising(); void UpdateAvailabilityL(TBool aAvailability); private: void BuildProtocolDescriptionL(CSdpAttrValueDES* aProtocolDescriptor, TInt aPort); void ConnectL(); private: // Data RSdp iSdpSession; RSdpDatabase iSdpDatabase; TSdpServRecordHandle iRecord; TInt iRecordState; TBool iIsConnected; }; // Inline function definition inline TBool CBluetoothAdvertiser::IsAdvertising() { return iRecord != 0; } #endif /*BLUETOOTHADVERTISER_H_*/