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 414 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
425 bool Stop(); | 425 bool Stop(); |
426 | 426 |
427 %feature("docstring", "Get FilePath to the document root") document_root; | 427 %feature("docstring", "Get FilePath to the document root") document_root; |
428 const FilePath& document_root() const; | 428 const FilePath& document_root() const; |
429 | 429 |
430 std::string GetScheme() const; | 430 std::string GetScheme() const; |
431 | 431 |
432 %feature("docstring", "Get URL for a file path") GetURL; | 432 %feature("docstring", "Get URL for a file path") GetURL; |
433 GURL GetURL(const std::string& path) const; | 433 GURL GetURL(const std::string& path) const; |
434 }; | 434 }; |
| 435 |
| 436 %extend TestServer { |
| 437 %feature("docstring", "Get port number.") GetPort; |
| 438 int GetPort() const { |
| 439 int val = 0; |
| 440 $self->server_data().GetInteger("port", &val); |
| 441 return val; |
| 442 } |
| 443 |
| 444 %feature("docstring", "Get xmpp port number in case of sync server.") |
| 445 GetSyncXmppPort; |
| 446 int GetSyncXmppPort() const { |
| 447 int val = 0; |
| 448 $self->server_data().GetInteger("xmpp_port", &val); |
| 449 return val; |
| 450 } |
| 451 }; |
| 452 |
435 } | 453 } |
436 | 454 |
OLD | NEW |