Chromium Code Reviews| Index: chrome/browser/media_galleries/fileapi/scanning_file_validator.h |
| diff --git a/chrome/browser/media_galleries/fileapi/scanning_file_validator.h b/chrome/browser/media_galleries/fileapi/scanning_file_validator.h |
| new file mode 100644 |
| index 0000000000000000000000000000000000000000..b6dca15d3abd6d96f3c4afd8643a095734614793 |
| --- /dev/null |
| +++ b/chrome/browser/media_galleries/fileapi/scanning_file_validator.h |
| @@ -0,0 +1,38 @@ |
| +// Copyright 2013 The Chromium Authors. All rights reserved. |
| +// Use of this source code is governed by a BSD-style license that can be |
| +// found in the LICENSE file. |
| + |
| +#ifndef CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_SCANNING_FILE_VALIDATOR_H_ |
| +#define CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_SCANNING_FILE_VALIDATOR_H_ |
| + |
| +#include "base/basictypes.h" |
| +#include "base/files/file_path.h" |
|
Lei Zhang
2013/08/07 01:03:05
nit: forward-decl
Greg Billock
2013/08/07 17:00:56
Done.
|
| +#include "base/memory/scoped_ptr.h" |
|
Lei Zhang
2013/08/07 01:03:05
nit: remove
Greg Billock
2013/08/07 17:00:56
Done.
|
| +#include "webkit/browser/fileapi/copy_or_move_file_validator.h" |
| + |
| +namespace chrome { |
| + |
| +// This class supports AV scanning on post write validation. |
| +class ScanningFileValidator : public fileapi::CopyOrMoveFileValidator { |
|
vandebo (ex-Chrome)
2013/08/07 16:13:14
nit: AVScanningFileValidator ?
vandebo (ex-Chrome)
2013/08/07 17:11:11
Comment missed.
Greg Billock
2013/08/07 17:42:56
Looks good, but not done yet -- that'll mean rerun
|
| + public: |
| + virtual ~ScanningFileValidator(); |
| + |
| + virtual void StartPreWriteValidation( |
|
vandebo (ex-Chrome)
2013/08/07 16:13:14
You don't need this, remove.
Greg Billock
2013/08/07 17:00:56
Done.
|
| + const ResultCallback& result_callback) = 0; |
| + |
| + // Runs AV checks on the resulting file (Windows-only). |
| + // Subclasses will not typically override this method. |
| + virtual void StartPostWriteValidation( |
| + const base::FilePath& dest_platform_path, |
| + const ResultCallback& result_callback) OVERRIDE; |
| + |
| + protected: |
| + explicit ScanningFileValidator(); |
|
Lei Zhang
2013/08/07 01:03:05
nit: not explicit
Greg Billock
2013/08/07 17:00:56
Done.
|
| + |
| + private: |
| + DISALLOW_COPY_AND_ASSIGN(ScanningFileValidator); |
| +}; |
| + |
| +} // namespace chrome |
| + |
| +#endif // CHROME_BROWSER_MEDIA_GALLERIES_FILEAPI_SCANNING_FILE_VALIDATOR_H_ |