| OLD | NEW |
| 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. | 1 // Copyright 2006-2008 the V8 project authors. All rights reserved. |
| 2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
| 3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
| 4 // met: | 4 // met: |
| 5 // | 5 // |
| 6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
| 7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
| 8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
| 9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
| 10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
| (...skipping 419 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 430 // Server initialization. | 430 // Server initialization. |
| 431 virtual bool Bind(const int port) = 0; | 431 virtual bool Bind(const int port) = 0; |
| 432 virtual bool Listen(int backlog) const = 0; | 432 virtual bool Listen(int backlog) const = 0; |
| 433 virtual Socket* Accept() const = 0; | 433 virtual Socket* Accept() const = 0; |
| 434 | 434 |
| 435 // Client initialization. | 435 // Client initialization. |
| 436 virtual bool Connect(const char* host, const char* port) = 0; | 436 virtual bool Connect(const char* host, const char* port) = 0; |
| 437 | 437 |
| 438 // Data Transimission | 438 // Data Transimission |
| 439 virtual int Send(const char* data, int len) const = 0; | 439 virtual int Send(const char* data, int len) const = 0; |
| 440 virtual bool SendAll(const char* data, int len) const = 0; | |
| 441 virtual int Receive(char* data, int len) const = 0; | 440 virtual int Receive(char* data, int len) const = 0; |
| 442 | 441 |
| 443 virtual bool IsValid() const = 0; | 442 virtual bool IsValid() const = 0; |
| 444 | 443 |
| 445 static bool Setup(); | 444 static bool Setup(); |
| 446 static int LastError(); | 445 static int LastError(); |
| 447 static uint16_t HToN(uint16_t value); | 446 static uint16_t HToN(uint16_t value); |
| 448 static uint16_t NToH(uint16_t value); | 447 static uint16_t NToH(uint16_t value); |
| 449 static uint32_t HToN(uint32_t value); | 448 static uint32_t HToN(uint32_t value); |
| 450 static uint32_t NToH(uint32_t value); | 449 static uint32_t NToH(uint32_t value); |
| (...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 516 bool active_; | 515 bool active_; |
| 517 PlatformData* data_; // Platform specific data. | 516 PlatformData* data_; // Platform specific data. |
| 518 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); | 517 DISALLOW_IMPLICIT_CONSTRUCTORS(Sampler); |
| 519 }; | 518 }; |
| 520 | 519 |
| 521 #endif // ENABLE_LOGGING_AND_PROFILING | 520 #endif // ENABLE_LOGGING_AND_PROFILING |
| 522 | 521 |
| 523 } } // namespace v8::internal | 522 } } // namespace v8::internal |
| 524 | 523 |
| 525 #endif // V8_PLATFORM_H_ | 524 #endif // V8_PLATFORM_H_ |
| OLD | NEW |