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

Side by Side Diff: third_party/WebKit/Source/web/WebIDBKey.cpp

Issue 2676403003: IndexedDB: Add histograms for key type (Closed)
Patch Set: Created 3 years, 10 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
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 121 matching lines...) Expand 10 before | Expand all | Expand 10 after
132 break; 132 break;
133 case IDBKey::DateType: 133 case IDBKey::DateType:
134 keys[i] = WebIDBKey::createDate(key->date()); 134 keys[i] = WebIDBKey::createDate(key->date());
135 break; 135 break;
136 case IDBKey::NumberType: 136 case IDBKey::NumberType:
137 keys[i] = WebIDBKey::createNumber(key->number()); 137 keys[i] = WebIDBKey::createNumber(key->number());
138 break; 138 break;
139 case IDBKey::InvalidType: 139 case IDBKey::InvalidType:
140 keys[i] = WebIDBKey::createInvalid(); 140 keys[i] = WebIDBKey::createInvalid();
141 break; 141 break;
142 case IDBKey::MinType:
143 NOTREACHED();
144 break;
145 } 142 }
146 } 143 }
147 result.swap(keys); 144 result.swap(keys);
148 } 145 }
149 146
150 void WebIDBKey::assignArray(const WebVector<WebIDBKey>& array) { 147 void WebIDBKey::assignArray(const WebVector<WebIDBKey>& array) {
151 m_private = convertFromWebIDBKeyArray(array); 148 m_private = convertFromWebIDBKeyArray(array);
152 } 149 }
153 150
154 void WebIDBKey::assignBinary(const WebData& binary) { 151 void WebIDBKey::assignBinary(const WebData& binary) {
(...skipping 48 matching lines...) Expand 10 before | Expand all | Expand 10 after
203 200
204 double WebIDBKey::date() const { 201 double WebIDBKey::date() const {
205 return m_private->date(); 202 return m_private->date();
206 } 203 }
207 204
208 double WebIDBKey::number() const { 205 double WebIDBKey::number() const {
209 return m_private->number(); 206 return m_private->number();
210 } 207 }
211 208
212 } // namespace blink 209 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698