Flutter Engine
The Flutter Engine
Loading...
Searching...
No Matches
Public Member Functions | List of all members
dart::DisableIdleTimerScope Class Reference

#include <isolate.h>

Inheritance diagram for dart::DisableIdleTimerScope:
dart::ValueObject

Public Member Functions

 DisableIdleTimerScope (IdleTimeHandler *handler)
 
 ~DisableIdleTimerScope ()
 
- Public Member Functions inherited from dart::ValueObject
 ValueObject ()
 
 ~ValueObject ()
 

Detailed Description

Definition at line 242 of file isolate.h.

Constructor & Destructor Documentation

◆ DisableIdleTimerScope()

dart::DisableIdleTimerScope::DisableIdleTimerScope ( IdleTimeHandler handler)
explicit

Definition at line 245 of file isolate.cc.

246 : handler_(handler) {
247 if (handler_ != nullptr) {
248 MutexLocker ml(&handler_->mutex_);
249 ++handler_->disabled_counter_;
250 handler_->idle_start_time_ = 0;
251 }
252}

◆ ~DisableIdleTimerScope()

dart::DisableIdleTimerScope::~DisableIdleTimerScope ( )

Definition at line 254 of file isolate.cc.

254 {
255 if (handler_ != nullptr) {
256 MutexLocker ml(&handler_->mutex_);
257 --handler_->disabled_counter_;
258 ASSERT(handler_->disabled_counter_ >= 0);
259 }
260}
#define ASSERT(E)

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