swift
Public Types | Public Slots | Signals | Public Member Functions | List of all members
swift::simplugin::fs9::CFs9Host Class Reference

Class encapsulating a FS9 host. More...

Inheritance diagram for swift::simplugin::fs9::CFs9Host:
[legend]

Public Types

enum  HostStatus { Hosting , Terminated }
 Connection status.
 

Public Slots

void sendTextMessage (const QString &textMessage)
 Send new text message.
 
- Public Slots inherited from swift::simplugin::fs9::CDirectPlayPeer
HRESULT sendMessage (const QByteArray &data)
 Send a custom DirectPlay message. More...
 
void reset ()
 Reset peer.
 

Signals

void statusChanged (swift::simplugin::fs9::CFs9Host::HostStatus)
 Hosting status changed.
 
- Signals inherited from swift::simplugin::fs9::CDirectPlayPeer
void customPacketReceived (const QByteArray &data)
 Received custom FS9 packet.
 
void connectionComplete ()
 Async operatione complete.
 

Public Member Functions

 CFs9Host (QObject *parent=nullptr)
 Constructor.
 
virtual ~CFs9Host ()
 Destructor.
 
bool isConnected () const
 Returns true if the users simulator is connected.
 
QString getHostAddress ()
 Get DirectPlay host url.
 
- Public Member Functions inherited from swift::simplugin::fs9::CDirectPlayPeer
 CDirectPlayPeer (const swift::misc::aviation::CCallsign &callsign, QObject *parent=nullptr)
 Constructor.
 
virtual ~CDirectPlayPeer ()
 Destructor.
 
DPNID getPlayerUserId () const
 Returns users DirectPlay ID.
 
void setPlayerUserId (DPNID id)
 Sets users DirectPlay ID.
 

Additional Inherited Members

- Static Public Member Functions inherited from swift::simplugin::fs9::CDirectPlayPeer
static const QStringList & getLogCategories ()
 Log categories.
 
- Protected Types inherited from swift::simplugin::fs9::CDirectPlayPeer
using TCallbackWrapper = CallbackWrapper< CDirectPlayPeer, HRESULT, DWORD, void * >
 DirectPlay peer message handler wrapper.
 
- Protected Member Functions inherited from swift::simplugin::fs9::CDirectPlayPeer
HRESULT directPlayMessageHandler (DWORD messageId, void *msgBuffer)
 DirectPlay message handler.
 
HRESULT initDirectPlay ()
 Initialize DirectPlay.
 
bool isServiceProviderValid (const GUID *pGuidSP)
 Returns true of the service provider is a valid on this machine.
 
HRESULT createDeviceAddress ()
 Creates a new DirectPlay device address.
 
HRESULT createHostAddress ()
 Creates a new DirectPlay device address.
 
- Protected Attributes inherited from swift::simplugin::fs9::CDirectPlayPeer
const swift::misc::aviation::CCallsign m_callsign
 Peer callsign.
 
IDirectPlay8Peer * m_directPlayPeer = nullptr
 DirectPlay peer address.
 
IDirectPlay8Address * m_deviceAddress = nullptr
 DirectPlay device address.
 
QList< CHostNodem_hostNodeList
 List of enumerated hosts.
 
quint32 m_packetIndex = 0
 Multiplayer packet index.
 
std::atomic< DPNID > m_playerLocal = { 0 }
 Local player Id.
 
std::atomic< DPNID > m_playerUser = { 0 }
 User player Id.
 
TCallbackWrapper m_callbackWrapper
 Callback wrapper.
 

Detailed Description

Class encapsulating a FS9 host.

Definition at line 14 of file fs9host.h.


The documentation for this class was generated from the following files: