Kodi Documentation 22.0
Kodi is an open source media player and entertainment hub.
Loading...
Searching...
No Matches
CUPowerSyscall Class Reference

#include <UPowerSyscall.h>

Inheritance diagram for CUPowerSyscall:
CAbstractPowerSyscall IPowerSyscall CConsoleUPowerSyscall

Public Member Functions

 CUPowerSyscall ()
 
bool Powerdown () override
 
bool Suspend () override
 
bool Hibernate () override
 
bool Reboot () override
 
bool CanPowerdown () override
 
bool CanSuspend () override
 
bool CanHibernate () override
 
bool CanReboot () override
 
int BatteryLevel () override
 
bool PumpPowerEvents (IPowerEventsCallback *callback) override
 Pump power related events back to xbmc.
 
- Public Member Functions inherited from CAbstractPowerSyscall
int CountPowerFeatures () override
 
- Public Member Functions inherited from IPowerSyscall
virtual ~IPowerSyscall ()=default
 

Static Public Member Functions

static bool HasUPower ()
 
- Static Public Member Functions inherited from IPowerSyscall
static IPowerSyscallCreateInstance ()
 Called by power manager to create platform power system adapter.
 
static void RegisterPowerSyscall (CreatePowerSyscallFunc createFunc)
 

Protected Member Functions

void UpdateCapabilities ()
 

Protected Attributes

bool m_CanPowerdown
 
bool m_CanSuspend
 
bool m_CanHibernate
 
bool m_CanReboot
 

Additional Inherited Members

- Static Public Attributes inherited from IPowerSyscall
static const int MAX_COUNT_POWER_FEATURES = 4
 

Constructor & Destructor Documentation

◆ CUPowerSyscall()

CUPowerSyscall::CUPowerSyscall ( )
Todo
do not use dbus_connection_pop_message() that requires the use of a private connection

Member Function Documentation

◆ BatteryLevel()

int CUPowerSyscall::BatteryLevel ( void )
overridevirtual

Implements IPowerSyscall.

◆ CanHibernate()

bool CUPowerSyscall::CanHibernate ( void )
overridevirtual

Implements IPowerSyscall.

◆ CanPowerdown()

bool CUPowerSyscall::CanPowerdown ( void )
overridevirtual

Implements IPowerSyscall.

◆ CanReboot()

bool CUPowerSyscall::CanReboot ( void )
overridevirtual

Implements IPowerSyscall.

◆ CanSuspend()

bool CUPowerSyscall::CanSuspend ( void )
overridevirtual

Implements IPowerSyscall.

◆ HasUPower()

bool CUPowerSyscall::HasUPower ( )
static

◆ Hibernate()

bool CUPowerSyscall::Hibernate ( void )
overridevirtual

Implements IPowerSyscall.

◆ Powerdown()

bool CUPowerSyscall::Powerdown ( void )
overridevirtual

Implements IPowerSyscall.

◆ PumpPowerEvents()

bool CUPowerSyscall::PumpPowerEvents ( IPowerEventsCallback * callback)
overridevirtual

Pump power related events back to xbmc.

PumpPowerEvents is called from Application Thread and the platform implementation may signal power related events back to xbmc through the callback.

return true if an event occurred and false if not.

Parameters
callbackthe callback to signal to

Implements IPowerSyscall.

◆ Reboot()

bool CUPowerSyscall::Reboot ( void )
overridevirtual

Implements IPowerSyscall.

◆ Suspend()

bool CUPowerSyscall::Suspend ( void )
overridevirtual

Implements IPowerSyscall.

◆ UpdateCapabilities()

void CUPowerSyscall::UpdateCapabilities ( )
protected

Member Data Documentation

◆ m_CanHibernate

bool CUPowerSyscall::m_CanHibernate
protected

◆ m_CanPowerdown

bool CUPowerSyscall::m_CanPowerdown
protected

◆ m_CanReboot

bool CUPowerSyscall::m_CanReboot
protected

◆ m_CanSuspend

bool CUPowerSyscall::m_CanSuspend
protected

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