Upstream version 11.39.244.0
[platform/framework/web/crosswalk.git] / src / xwalk / application / tools / tizen / xwalk_rds_delta_parser.h
1 // Copyright (c) 2014 Samsung Electronics Co., Ltd All Rights Reserved
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #ifndef XWALK_APPLICATION_TOOLS_TIZEN_XWALK_RDS_DELTA_PARSER_H_
6 #define XWALK_APPLICATION_TOOLS_TIZEN_XWALK_RDS_DELTA_PARSER_H_
7
8 #include <map>
9 #include <string>
10
11 #include "base/files/file_path.h"
12
13 class RDSDeltaParser {
14  public:
15   RDSDeltaParser(const base::FilePath& app_path, const std::string& pkgid);
16   bool Parse();
17   bool ApplyParsedData();
18
19  private:
20   base::FilePath app_dir_;
21   base::FilePath rds_dir_;
22   std::multimap<std::string, std::string> parsed_data_;
23
24   bool AddFile(const std::string& file_name);
25   bool DeleteFile(const std::string& file_name);
26   bool ModifyFile(const std::string& file_name);
27 };
28
29 #endif  // XWALK_APPLICATION_TOOLS_TIZEN_XWALK_RDS_DELTA_PARSER_H_