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

Side by Side Diff: components/omnibox/browser/in_memory_url_index_types.h

Issue 2337953002: Optimizing HQP using vectors manually. This is just a CL to be able (Closed)
Patch Set: Created 4 years, 3 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 | « no previous file | components/omnibox/browser/url_index_private_data.h » ('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) 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 COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_ 5 #ifndef COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_
6 #define COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_ 6 #define COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_
7 7
8 #include <stddef.h> 8 #include <stddef.h>
9 9
10 #include <map> 10 #include <map>
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after
125 // Support for InMemoryURLIndex Private Data ----------------------------------- 125 // Support for InMemoryURLIndex Private Data -----------------------------------
126 126
127 // An index into a list of all of the words we have indexed. 127 // An index into a list of all of the words we have indexed.
128 typedef size_t WordID; 128 typedef size_t WordID;
129 129
130 // A map allowing a WordID to be determined given a word. 130 // A map allowing a WordID to be determined given a word.
131 typedef std::map<base::string16, WordID> WordMap; 131 typedef std::map<base::string16, WordID> WordMap;
132 132
133 // A map from character to the word_ids of words containing that character. 133 // A map from character to the word_ids of words containing that character.
134 typedef std::set<WordID> WordIDSet; // An index into the WordList. 134 typedef std::set<WordID> WordIDSet; // An index into the WordList.
135 typedef std::vector<WordID> WordIDVector;
135 typedef std::map<base::char16, WordIDSet> CharWordIDMap; 136 typedef std::map<base::char16, WordIDSet> CharWordIDMap;
136 137
137 // A map from word (by word_id) to history items containing that word. 138 // A map from word (by word_id) to history items containing that word.
138 typedef history::URLID HistoryID; 139 typedef history::URLID HistoryID;
139 typedef std::set<HistoryID> HistoryIDSet; 140 typedef std::set<HistoryID> HistoryIDSet;
140 typedef std::vector<HistoryID> HistoryIDVector; 141 typedef std::vector<HistoryID> HistoryIDVector;
141 typedef std::map<WordID, HistoryIDSet> WordIDHistoryMap; 142 typedef std::map<WordID, HistoryIDSet> WordIDHistoryMap;
142 typedef std::map<HistoryID, WordIDSet> HistoryIDWordMap; 143 typedef std::map<HistoryID, WordIDSet> HistoryIDWordMap;
143 144
144 145
(...skipping 25 matching lines...) Expand all
170 171
171 // Clears both url_word_starts_ and title_word_starts_. 172 // Clears both url_word_starts_ and title_word_starts_.
172 void Clear(); 173 void Clear();
173 174
174 WordStarts url_word_starts_; 175 WordStarts url_word_starts_;
175 WordStarts title_word_starts_; 176 WordStarts title_word_starts_;
176 }; 177 };
177 typedef std::map<HistoryID, RowWordStarts> WordStartsMap; 178 typedef std::map<HistoryID, RowWordStarts> WordStartsMap;
178 179
179 #endif // COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_ 180 #endif // COMPONENTS_OMNIBOX_BROWSER_IN_MEMORY_URL_INDEX_TYPES_H_
OLDNEW
« no previous file with comments | « no previous file | components/omnibox/browser/url_index_private_data.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698