PicoScenes API Docs
 
Loading...
Searching...
No Matches
FrontEndFactory Class Reference

Factory class for creating and managing front-end instances. More...

#include <FrontEndFactory.hxx>

Static Public Member Functions

static std::shared_ptr< AbstractFrontEndgetFrontEndInstance (const std::string &referredInterfaceName)
 Get a front-end instance for the specified interface.
 
template<typename FrontEndT , class = typename std::enable_if<std::is_base_of<AbstractFrontEnd, FrontEndT>::value>::type>
static std::shared_ptr< FrontEndT > getTypedFrontEndInstance (const std::string &referredInterfaceName)
 Get a typed front-end instance for the specified interface.
 

Detailed Description

Factory class for creating and managing front-end instances.

This factory class provides static methods to create and retrieve instances of various front-end types including:

  • MAC80211 based NICs (QCA9300, IWL5300, IWLMVM)
  • USRP devices
  • SoapySDR devices
  • Virtual SDR devices

The factory implements a singleton pattern for each front-end instance, ensuring only one instance exists per interface name.

Definition at line 23 of file FrontEndFactory.hxx.

Member Function Documentation

◆ getFrontEndInstance()

static std::shared_ptr< AbstractFrontEnd > FrontEndFactory::getFrontEndInstance ( const std::string &  referredInterfaceName)
static

Get a front-end instance for the specified interface.

Parameters
referredInterfaceNameName or identifier of the interface
Returns
Shared pointer to AbstractFrontEnd instance
Exceptions
std::invalid_argumentIf the interface type is unsupported

Referenced by getTypedFrontEndInstance().

◆ getTypedFrontEndInstance()

template<typename FrontEndT , class = typename std::enable_if<std::is_base_of<AbstractFrontEnd, FrontEndT>::value>::type>
static std::shared_ptr< FrontEndT > FrontEndFactory::getTypedFrontEndInstance ( const std::string &  referredInterfaceName)
inlinestatic

Get a typed front-end instance for the specified interface.

Template Parameters
FrontEndTType of front-end to create (must inherit from AbstractFrontEnd)
Parameters
referredInterfaceNameName or identifier of the interface
Returns
Shared pointer to the specified front-end type
Note
Uses SFINAE to ensure FrontEndT derives from AbstractFrontEnd

Definition at line 43 of file FrontEndFactory.hxx.

References getFrontEndInstance(), and getTypedFrontEndInstance().

Referenced by AbstractNIC::getTypedFrontEnd(), and getTypedFrontEndInstance().


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