OLD | NEW |
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 // | 4 // |
5 // Swig Interface for PyAuto. | 5 // Swig Interface for PyAuto. |
6 // PyAuto makes the Automation Proxy interface available in Python | 6 // PyAuto makes the Automation Proxy interface available in Python |
7 // | 7 // |
8 // Running swig as: | 8 // Running swig as: |
9 // swig -python -c++ chrome/test/pyautolib/pyautolib.i | 9 // swig -python -c++ chrome/test/pyautolib/pyautolib.i |
10 // would generate pyautolib.py, pyautolib_wrap.cxx | 10 // would generate pyautolib.py, pyautolib_wrap.cxx |
(...skipping 400 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
411 TestServer; | 411 TestServer; |
412 class TestServer { | 412 class TestServer { |
413 public: | 413 public: |
414 enum Type { | 414 enum Type { |
415 TYPE_FTP, | 415 TYPE_FTP, |
416 TYPE_HTTP, | 416 TYPE_HTTP, |
417 TYPE_HTTPS, | 417 TYPE_HTTPS, |
418 TYPE_SYNC, | 418 TYPE_SYNC, |
419 }; | 419 }; |
420 | 420 |
421 TestServer(Type type, const FilePath& document_root); | 421 // Initialize a TestServer listening on the specified host (IP or hostname). |
| 422 TestServer(Type type, const std::string& host, const FilePath& document_root); |
422 // Initialize a HTTPS TestServer with a specific set of HTTPSOptions. | 423 // Initialize a HTTPS TestServer with a specific set of HTTPSOptions. |
423 TestServer(const HTTPSOptions& https_options, | 424 TestServer(const HTTPSOptions& https_options, |
424 const FilePath& document_root); | 425 const FilePath& document_root); |
425 | 426 |
426 %feature("docstring", "Start TestServer over an ephemeral port") Start; | 427 %feature("docstring", "Start TestServer over an ephemeral port") Start; |
427 bool Start(); | 428 bool Start(); |
428 | 429 |
429 %feature("docstring", "Stop TestServer") Stop; | 430 %feature("docstring", "Stop TestServer") Stop; |
430 bool Stop(); | 431 bool Stop(); |
431 | 432 |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
467 CERT_EXPIRED, | 468 CERT_EXPIRED, |
468 }; | 469 }; |
469 | 470 |
470 // Initialize a new HTTPSOptions that will use the specified certificate. | 471 // Initialize a new HTTPSOptions that will use the specified certificate. |
471 explicit HTTPSOptions(ServerCertificate cert); | 472 explicit HTTPSOptions(ServerCertificate cert); |
472 }; | 473 }; |
473 | 474 |
474 %{ | 475 %{ |
475 typedef net::TestServer::HTTPSOptions HTTPSOptions; | 476 typedef net::TestServer::HTTPSOptions HTTPSOptions; |
476 %} | 477 %} |
OLD | NEW |