| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 #ifndef SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 5 #ifndef SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| 6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 6 #define SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 350 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 361 // the default is false. | 361 // the default is false. |
| 362 // |blocking_task_runner| is a TaskRunner to be used for tasks that | 362 // |blocking_task_runner| is a TaskRunner to be used for tasks that |
| 363 // may block on disk I/O. | 363 // may block on disk I/O. |
| 364 // |post_factory| will be owned internally and used to create | 364 // |post_factory| will be owned internally and used to create |
| 365 // instances of an HttpPostProvider. | 365 // instances of an HttpPostProvider. |
| 366 // |model_safe_worker| ownership is given to the SyncManager. | 366 // |model_safe_worker| ownership is given to the SyncManager. |
| 367 // |user_agent| is a 7-bit ASCII string suitable for use as the User-Agent | 367 // |user_agent| is a 7-bit ASCII string suitable for use as the User-Agent |
| 368 // HTTP header. Used internally when collecting stats to classify clients. | 368 // HTTP header. Used internally when collecting stats to classify clients. |
| 369 // |sync_notifier| is owned and used to listen for notifications. | 369 // |sync_notifier| is owned and used to listen for notifications. |
| 370 // |report_unrecoverable_error_function| may be NULL. | 370 // |report_unrecoverable_error_function| may be NULL. |
| 371 // |
| 372 // TODO(akalin): Replace the |post_factory| parameter with a |
| 373 // URLFetcher parameter. |
| 371 bool Init(const FilePath& database_location, | 374 bool Init(const FilePath& database_location, |
| 372 const csync::WeakHandle<csync::JsEventHandler>& | 375 const csync::WeakHandle<csync::JsEventHandler>& |
| 373 event_handler, | 376 event_handler, |
| 374 const std::string& sync_server_and_path, | 377 const std::string& sync_server_and_path, |
| 375 int sync_server_port, | 378 int sync_server_port, |
| 376 bool use_ssl, | 379 bool use_ssl, |
| 377 const scoped_refptr<base::TaskRunner>& blocking_task_runner, | 380 const scoped_refptr<base::TaskRunner>& blocking_task_runner, |
| 378 HttpPostProviderFactory* post_factory, | 381 HttpPostProviderFactory* post_factory, |
| 379 const csync::ModelSafeRoutingInfo& model_safe_routing_info, | 382 const csync::ModelSafeRoutingInfo& model_safe_routing_info, |
| 380 const std::vector<csync::ModelSafeWorker*>& workers, | 383 const std::vector<csync::ModelSafeWorker*>& workers, |
| 381 csync::ExtensionsActivityMonitor* | 384 csync::ExtensionsActivityMonitor* |
| 382 extensions_activity_monitor, | 385 extensions_activity_monitor, |
| 383 ChangeDelegate* change_delegate, | 386 ChangeDelegate* change_delegate, |
| 384 const std::string& user_agent, | |
| 385 const SyncCredentials& credentials, | 387 const SyncCredentials& credentials, |
| 386 csync::SyncNotifier* sync_notifier, | 388 csync::SyncNotifier* sync_notifier, |
| 387 const std::string& restored_key_for_bootstrapping, | 389 const std::string& restored_key_for_bootstrapping, |
| 388 TestingMode testing_mode, | 390 TestingMode testing_mode, |
| 389 csync::Encryptor* encryptor, | 391 csync::Encryptor* encryptor, |
| 390 csync::UnrecoverableErrorHandler* | 392 csync::UnrecoverableErrorHandler* |
| 391 unrecoverable_error_handler, | 393 unrecoverable_error_handler, |
| 392 csync::ReportUnrecoverableErrorFunction | 394 csync::ReportUnrecoverableErrorFunction |
| 393 report_unrecoverable_error_function); | 395 report_unrecoverable_error_function); |
| 394 | 396 |
| (...skipping 161 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 556 csync::UserShare* share); | 558 csync::UserShare* share); |
| 557 | 559 |
| 558 const char* ConnectionStatusToString(ConnectionStatus status); | 560 const char* ConnectionStatusToString(ConnectionStatus status); |
| 559 | 561 |
| 560 // Returns the string representation of a PassphraseRequiredReason value. | 562 // Returns the string representation of a PassphraseRequiredReason value. |
| 561 const char* PassphraseRequiredReasonToString(PassphraseRequiredReason reason); | 563 const char* PassphraseRequiredReasonToString(PassphraseRequiredReason reason); |
| 562 | 564 |
| 563 } // namespace csync | 565 } // namespace csync |
| 564 | 566 |
| 565 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ | 567 #endif // SYNC_INTERNAL_API_PUBLIC_SYNC_MANAGER_H_ |
| OLD | NEW |