| Index: sync/internal_api/public/attachments/attachment_uploader_impl.h
|
| diff --git a/sync/internal_api/public/attachments/attachment_uploader_impl.h b/sync/internal_api/public/attachments/attachment_uploader_impl.h
|
| index 8604415e03e8990d15b644beeac9812c3b1fd2c9..25394fc54b8d881999540194bc3cad06e71bf87a 100644
|
| --- a/sync/internal_api/public/attachments/attachment_uploader_impl.h
|
| +++ b/sync/internal_api/public/attachments/attachment_uploader_impl.h
|
| @@ -23,8 +23,7 @@ namespace syncer {
|
| class SYNC_EXPORT AttachmentUploaderImpl : public AttachmentUploader,
|
| public base::NonThreadSafe {
|
| public:
|
| - // |url_prefix| is the URL prefix (including trailing slash) to be used when
|
| - // uploading attachments.
|
| + // |sync_service_url| is the URL of the sync service.
|
| //
|
| // |url_request_context_getter| provides a URLRequestContext.
|
| //
|
| @@ -34,7 +33,7 @@ class SYNC_EXPORT AttachmentUploaderImpl : public AttachmentUploader,
|
| //
|
| // |token_service_provider| provides an OAuth2 token service.
|
| AttachmentUploaderImpl(
|
| - const std::string& url_prefix,
|
| + const GURL& sync_service_url,
|
| const scoped_refptr<net::URLRequestContextGetter>&
|
| url_request_context_getter,
|
| const std::string& account_id,
|
| @@ -47,15 +46,18 @@ class SYNC_EXPORT AttachmentUploaderImpl : public AttachmentUploader,
|
| virtual void UploadAttachment(const Attachment& attachment,
|
| const UploadCallback& callback) OVERRIDE;
|
|
|
| + // Return the URL for the given |sync_service_url| and |attachment_id|.
|
| + static GURL GetURLForAttachmentId(const GURL& sync_service_url,
|
| + const AttachmentId& attachment_id);
|
| +
|
| private:
|
| class UploadState;
|
| typedef std::string UniqueId;
|
| typedef base::ScopedPtrHashMap<UniqueId, UploadState> StateMap;
|
|
|
| - GURL GetUploadURLForAttachmentId(const AttachmentId& attachment_id) const;
|
| void DeleteUploadStateFor(const UniqueId& unique_id);
|
|
|
| - std::string url_prefix_;
|
| + GURL sync_service_url_;
|
| scoped_refptr<net::URLRequestContextGetter> url_request_context_getter_;
|
| std::string account_id_;
|
| OAuth2TokenService::ScopeSet scopes_;
|
|
|