| OLD | NEW |
| 1 // -*- c++ -*- | 1 // -*- c++ -*- |
| 2 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 2 // Copyright (c) 2011 The Chromium Authors. All rights reserved. |
| 3 // Use of this source code is governed by a BSD-style license that can be | 3 // Use of this source code is governed by a BSD-style license that can be |
| 4 // found in the LICENSE file. | 4 // found in the LICENSE file. |
| 5 | 5 |
| 6 // The portable representation of an instance and root scriptable object. | 6 // The portable representation of an instance and root scriptable object. |
| 7 // The PPAPI version of the plugin instantiates a subclass of this class. | 7 // The PPAPI version of the plugin instantiates a subclass of this class. |
| 8 | 8 |
| 9 #ifndef NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 9 #ifndef NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
| 10 #define NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 10 #define NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
| (...skipping 425 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 436 // Determines the URL of the program module appropriate for the NaCl sandbox | 436 // Determines the URL of the program module appropriate for the NaCl sandbox |
| 437 // implemented by the installed sel_ldr. The URL is determined from the | 437 // implemented by the installed sel_ldr. The URL is determined from the |
| 438 // Manifest in |manifest_|. On success, |true| is returned and |result| is | 438 // Manifest in |manifest_|. On success, |true| is returned and |result| is |
| 439 // set to the URL to use for the program, and |is_portable| is set to | 439 // set to the URL to use for the program, and |is_portable| is set to |
| 440 // |true| if the program is portable bitcode. | 440 // |true| if the program is portable bitcode. |
| 441 // On failure, |false| is returned. | 441 // On failure, |false| is returned. |
| 442 bool SelectProgramURLFromManifest(nacl::string* result, | 442 bool SelectProgramURLFromManifest(nacl::string* result, |
| 443 ErrorInfo* error_info, | 443 ErrorInfo* error_info, |
| 444 bool* is_portable); | 444 bool* is_portable); |
| 445 | 445 |
| 446 // TODO(jvoung): get rid of these once we find a better way to store / install | |
| 447 // the pnacl translator nexes. | |
| 448 bool SelectLLCURLFromManifest(nacl::string* result, | |
| 449 ErrorInfo* error_info); | |
| 450 bool SelectLDURLFromManifest(nacl::string* result, | |
| 451 ErrorInfo* error_info); | |
| 452 | |
| 453 // Logs timing information to a UMA histogram, and also logs the same timing | 446 // Logs timing information to a UMA histogram, and also logs the same timing |
| 454 // information divided by the size of the nexe to another histogram. | 447 // information divided by the size of the nexe to another histogram. |
| 455 void HistogramStartupTimeSmall(const std::string& name, float dt); | 448 void HistogramStartupTimeSmall(const std::string& name, float dt); |
| 456 void HistogramStartupTimeMedium(const std::string& name, float dt); | 449 void HistogramStartupTimeMedium(const std::string& name, float dt); |
| 457 | 450 |
| 458 // Determines the appropriate nexe for the sandbox and requests a load. | 451 // Determines the appropriate nexe for the sandbox and requests a load. |
| 459 void RequestNexeLoad(); | 452 void RequestNexeLoad(); |
| 460 | 453 |
| 461 // Callback used when loading a URL for SRPC-based StreamAsFile(). | 454 // Callback used when loading a URL for SRPC-based StreamAsFile(). |
| 462 void UrlDidOpenForStreamAsFile(int32_t pp_error, | 455 void UrlDidOpenForStreamAsFile(int32_t pp_error, |
| (...skipping 104 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 567 // in UpdateDownloadProgress to map a url loader back to the URL being | 560 // in UpdateDownloadProgress to map a url loader back to the URL being |
| 568 // downloaded. | 561 // downloaded. |
| 569 const FileDownloader* FindFileDownloader(PP_Resource url_loader) const; | 562 const FileDownloader* FindFileDownloader(PP_Resource url_loader) const; |
| 570 | 563 |
| 571 int64_t last_event_bytes_received_; | 564 int64_t last_event_bytes_received_; |
| 572 }; | 565 }; |
| 573 | 566 |
| 574 } // namespace plugin | 567 } // namespace plugin |
| 575 | 568 |
| 576 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ | 569 #endif // NATIVE_CLIENT_SRC_TRUSTED_PLUGIN_PLUGIN_H_ |
| OLD | NEW |