AlexaClientSDK  3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Public Member Functions | Protected Attributes | List of all members
alexaClientSDK::visualTimeoutManager::test::MockTimerFactory Class Reference

#include <MockTimerFactory.h>

Inheritance diagram for alexaClientSDK::visualTimeoutManager::test::MockTimerFactory:
Inheritance graph
[legend]
Collaboration diagram for alexaClientSDK::visualTimeoutManager::test::MockTimerFactory:
Collaboration graph
[legend]

Public Member Functions

WarpTimergetTimer ()
 
TimerDelegateFactoryInterface Functions
bool supportsLowPowerMode () override
 
std::unique_ptr< alexaClientSDK::avsCommon::sdkInterfaces::timing::TimerDelegateInterfacegetTimerDelegate () override
 
- Public Member Functions inherited from alexaClientSDK::avsCommon::sdkInterfaces::timing::TimerDelegateFactoryInterface
virtual ~TimerDelegateFactoryInterface ()=default
 Destructor. More...
 

Protected Attributes

WarpTimerm_timer {nullptr}
 

Detailed Description

MockTimerFactory to return a single instance of WarpTimer

Member Function Documentation

◆ getTimer()

WarpTimer* alexaClientSDK::visualTimeoutManager::test::MockTimerFactory::getTimer ( )
inline

Gets the timer which was created by the last call to getTimerDelegate()

Note
This function must be used with great care, the lifetime of the timer is controlled by the unique_ptr which was returned by getTimerDelegate()
Returns
pointer to the timer instance

◆ getTimerDelegate()

std::unique_ptr<alexaClientSDK::avsCommon::sdkInterfaces::timing::TimerDelegateInterface> alexaClientSDK::visualTimeoutManager::test::MockTimerFactory::getTimerDelegate ( )
inlineoverridevirtual

Create an instance of a TimerDelegateInterface. This must be non-null.

Returns
A ptr to a TimerDelegateInterface.

Implements alexaClientSDK::avsCommon::sdkInterfaces::timing::TimerDelegateFactoryInterface.

◆ supportsLowPowerMode()

bool alexaClientSDK::visualTimeoutManager::test::MockTimerFactory::supportsLowPowerMode ( )
inlineoverridevirtual

Whether or not this TimerDelegateInterface can operate when the system is running in a reduced power mode. Examples of this include an implementation which uses a Real Time Clock.

Returns
A boolean whether this is supported.

Implements alexaClientSDK::avsCommon::sdkInterfaces::timing::TimerDelegateFactoryInterface.

Member Data Documentation

◆ m_timer

WarpTimer* alexaClientSDK::visualTimeoutManager::test::MockTimerFactory::m_timer {nullptr}
protected

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

AlexaClientSDK 3.0.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0