Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(618)

Side by Side Diff: chrome/tools/convert_dict/aff_reader.h

Issue 2929002: Convert some tools to use FilePaths for file names. (Closed)
Patch Set: ok Created 10 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « base/file_path.h ('k') | chrome/tools/convert_dict/aff_reader.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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 CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__ 5 #ifndef CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__
6 #define CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__ 6 #define CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__
7 7
8 #include <map> 8 #include <map>
9 #include <stdio.h> 9 #include <stdio.h>
10 #include <string> 10 #include <string>
11 #include <vector> 11 #include <vector>
12 12
13 class FilePath;
14
13 namespace convert_dict { 15 namespace convert_dict {
14 16
15 class AffReader { 17 class AffReader {
16 public: 18 public:
17 explicit AffReader(const std::string& filename); 19 explicit AffReader(const FilePath& path);
18 ~AffReader(); 20 ~AffReader();
19 21
20 bool Read(); 22 bool Read();
21 23
22 // Returns whether this file uses indexed affixes, or, on false, whether the 24 // Returns whether this file uses indexed affixes, or, on false, whether the
23 // rule string will be specified literally in the .dic file. This must be 25 // rule string will be specified literally in the .dic file. This must be
24 // called after Read(). 26 // called after Read().
25 bool has_indexed_affixes() const { return has_indexed_affixes_; } 27 bool has_indexed_affixes() const { return has_indexed_affixes_; }
26 28
27 // Returns a string representing the encoding of the dictionary. This will 29 // Returns a string representing the encoding of the dictionary. This will
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
97 // is the replacment. 99 // is the replacment.
98 std::vector< std::pair<std::string, std::string> > replacements_; 100 std::vector< std::pair<std::string, std::string> > replacements_;
99 101
100 // All other commands. 102 // All other commands.
101 std::vector<std::string> other_commands_; 103 std::vector<std::string> other_commands_;
102 }; 104 };
103 105
104 } // namespace convert_dict 106 } // namespace convert_dict
105 107
106 #endif // CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__ 108 #endif // CHROME_TOOLS_CONVERT_DICT_AFF_READER_H__
OLDNEW
« no previous file with comments | « base/file_path.h ('k') | chrome/tools/convert_dict/aff_reader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698