foobar2000 SDK  2015-08-03
Public Member Functions | Private Member Functions | Private Attributes
service_enum_t< t_interface >

#include <service.h>

Public Member Functions

 service_enum_t ()
 
template<typename t_query >
bool first (service_ptr_t< t_query > &p_out)
 
template<typename t_query >
bool next (service_ptr_t< t_query > &p_out)
 
void reset ()
 

Private Member Functions

bool __next (service_ptr_t< t_interface > &p_out)
 

Private Attributes

service_class_helper_t< t_interface > m_helper
 
unsigned m_index
 

Detailed Description

template<typename t_interface>
class service_enum_t< t_interface >

Definition at line 573 of file service.h.

Constructor & Destructor Documentation

template<typename t_interface>
service_enum_t< t_interface >::service_enum_t ( )
inline

Member Function Documentation

template<typename t_interface>
bool service_enum_t< t_interface >::__next ( service_ptr_t< t_interface > &  p_out)
inlineprivate

Definition at line 601 of file service.h.

601  {
602  return m_helper.create(p_out,m_index++);
603  }
service_class_helper_t< t_interface > m_helper
Definition: service.h:605
unsigned m_index
Definition: service.h:604
bool create(service_ptr_t< T > &p_out, t_size p_index) const
Definition: service.h:476
template<typename t_interface>
template<typename t_query >
bool service_enum_t< t_interface >::first ( service_ptr_t< t_query > &  p_out)
inline

Definition at line 581 of file service.h.

581  {
582  reset();
583  return next(p_out);
584  }
void reset()
Definition: service.h:578
bool next(service_ptr_t< t_query > &p_out)
Definition: service.h:587
template<typename t_interface>
template<typename t_query >
bool service_enum_t< t_interface >::next ( service_ptr_t< t_query > &  p_out)
inline

Definition at line 587 of file service.h.

587  {
590  return __next(reinterpret_cast<service_ptr_t<t_interface>&>(p_out));
591  } else {
593  while(__next(temp)) {
594  if (temp->service_query_t(p_out)) return true;
595  }
596  return false;
597  }
598  }
bool __next(service_ptr_t< t_interface > &p_out)
Definition: service.h:601
Autopointer class to be used with all services. Manages reference counter calls behind-the-scenes.
Definition: service.h:55
template<typename t_interface>
void service_enum_t< t_interface >::reset ( )
inline

Definition at line 578 of file service.h.

578 {m_index = 0;}
unsigned m_index
Definition: service.h:604

Field Documentation

template<typename t_interface>
service_class_helper_t<t_interface> service_enum_t< t_interface >::m_helper
private

Definition at line 605 of file service.h.

template<typename t_interface>
unsigned service_enum_t< t_interface >::m_index
private

Definition at line 604 of file service.h.


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