| OLD | NEW | 
|---|
| 1 // Copyright (c) 2011, the Dart project authors.  Please see the AUTHORS file | 1 // Copyright (c) 2011, the Dart project authors.  Please see the AUTHORS file | 
| 2 // for details. All rights reserved. Use of this source code is governed by a | 2 // for details. All rights reserved. Use of this source code is governed by a | 
| 3 // BSD-style license that can be found in the LICENSE file. | 3 // BSD-style license that can be found in the LICENSE file. | 
| 4 | 4 | 
| 5 #ifndef VM_MESSAGE_HANDLER_H_ | 5 #ifndef VM_MESSAGE_HANDLER_H_ | 
| 6 #define VM_MESSAGE_HANDLER_H_ | 6 #define VM_MESSAGE_HANDLER_H_ | 
| 7 | 7 | 
| 8 #include "vm/isolate.h" | 8 #include "vm/isolate.h" | 
| 9 #include "vm/lockers.h" | 9 #include "vm/lockers.h" | 
| 10 #include "vm/message.h" | 10 #include "vm/message.h" | 
| (...skipping 63 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 74   // handler. | 74   // handler. | 
| 75   bool HasOOBMessages(); | 75   bool HasOOBMessages(); | 
| 76 | 76 | 
| 77   // A message handler tracks how many live ports it has. | 77   // A message handler tracks how many live ports it has. | 
| 78   bool HasLivePorts() const { return live_ports_ > 0; } | 78   bool HasLivePorts() const { return live_ports_ > 0; } | 
| 79 | 79 | 
| 80   intptr_t live_ports() const { | 80   intptr_t live_ports() const { | 
| 81     return live_ports_; | 81     return live_ports_; | 
| 82   } | 82   } | 
| 83 | 83 | 
|  | 84   void DebugDump(); | 
|  | 85 | 
| 84   bool paused() const { return paused_ > 0; } | 86   bool paused() const { return paused_ > 0; } | 
| 85 | 87 | 
| 86   void increment_paused() { paused_++; } | 88   void increment_paused() { paused_++; } | 
| 87   void decrement_paused() { ASSERT(paused_ > 0); paused_--; } | 89   void decrement_paused() { ASSERT(paused_ > 0); paused_--; } | 
| 88 | 90 | 
| 89   bool ShouldPauseOnStart(MessageStatus status) const; | 91   bool ShouldPauseOnStart(MessageStatus status) const; | 
| 90   bool should_pause_on_start() const { | 92   bool should_pause_on_start() const { | 
| 91     return should_pause_on_start_; | 93     return should_pause_on_start_; | 
| 92   } | 94   } | 
| 93 | 95 | 
| (...skipping 151 matching lines...) Expand 10 before | Expand all | Expand 10 after  Loading... | 
| 245   StartCallback start_callback_; | 247   StartCallback start_callback_; | 
| 246   EndCallback end_callback_; | 248   EndCallback end_callback_; | 
| 247   CallbackData callback_data_; | 249   CallbackData callback_data_; | 
| 248 | 250 | 
| 249   DISALLOW_COPY_AND_ASSIGN(MessageHandler); | 251   DISALLOW_COPY_AND_ASSIGN(MessageHandler); | 
| 250 }; | 252 }; | 
| 251 | 253 | 
| 252 }  // namespace dart | 254 }  // namespace dart | 
| 253 | 255 | 
| 254 #endif  // VM_MESSAGE_HANDLER_H_ | 256 #endif  // VM_MESSAGE_HANDLER_H_ | 
| OLD | NEW | 
|---|