OLD | NEW |
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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 BIN_EVENTHANDLER_WIN_H_ | 5 #ifndef BIN_EVENTHANDLER_WIN_H_ |
6 #define BIN_EVENTHANDLER_WIN_H_ | 6 #define BIN_EVENTHANDLER_WIN_H_ |
7 | 7 |
8 #if !defined(BIN_EVENTHANDLER_H_) | 8 #if !defined(BIN_EVENTHANDLER_H_) |
9 #error Do not include eventhandler_win.h directly; use eventhandler.h instead. | 9 #error Do not include eventhandler_win.h directly; use eventhandler.h instead. |
10 #endif | 10 #endif |
(...skipping 451 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
462 virtual bool IsClosed(); | 462 virtual bool IsClosed(); |
463 | 463 |
464 ClientSocket* next() { return next_; } | 464 ClientSocket* next() { return next_; } |
465 void set_next(ClientSocket* next) { next_ = next; } | 465 void set_next(ClientSocket* next) { next_ = next; } |
466 | 466 |
467 void mark_connected() { | 467 void mark_connected() { |
468 connected_ = true; | 468 connected_ = true; |
469 } | 469 } |
470 bool is_connected() const { return connected_; } | 470 bool is_connected() const { return connected_; } |
471 | 471 |
| 472 void mark_closed() { |
| 473 closed_ = true; |
| 474 } |
| 475 |
472 private: | 476 private: |
473 bool LoadDisconnectEx(); | 477 bool LoadDisconnectEx(); |
474 | 478 |
475 LPFN_DISCONNECTEX DisconnectEx_; | 479 LPFN_DISCONNECTEX DisconnectEx_; |
476 ClientSocket* next_; | 480 ClientSocket* next_; |
477 bool connected_; | 481 bool connected_; |
478 bool closed_; | 482 bool closed_; |
479 }; | 483 }; |
480 | 484 |
481 | 485 |
(...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
534 | 538 |
535 TimeoutQueue timeout_queue_; // Time for next timeout. | 539 TimeoutQueue timeout_queue_; // Time for next timeout. |
536 bool shutdown_; | 540 bool shutdown_; |
537 HANDLE completion_port_; | 541 HANDLE completion_port_; |
538 }; | 542 }; |
539 | 543 |
540 } // namespace bin | 544 } // namespace bin |
541 } // namespace dart | 545 } // namespace dart |
542 | 546 |
543 #endif // BIN_EVENTHANDLER_WIN_H_ | 547 #endif // BIN_EVENTHANDLER_WIN_H_ |
OLD | NEW |