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

Side by Side Diff: client/dom/generated/src/frog/Storage.dart

Issue 9663027: Remove generated directories with 100s of files. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 8 years, 9 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 | Annotate | Revision Log
OLDNEW
(Empty)
1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file.
4
5 class _StorageJs extends _DOMTypeJs implements Storage native "*Storage" {
6
7 final int length;
8
9 void clear() native;
10
11 String getItem(String key) native;
12
13 String key(int index) native;
14
15 void removeItem(String key) native;
16
17 void setItem(String key, String data) native;
18
19
20 // Storage needs a special implementation of dartObjectLocalStorage since it
21 // captures what would normally be an expando and places property in the
22 // storage, stringifying the assigned value.
23
24 get dartObjectLocalStorage() native """
25 if (this === window.localStorage)
26 return window._dartLocalStorageLocalStorage;
27 else if (this === window.sessionStorage)
28 return window._dartSessionStorageLocalStorage;
29 else
30 throw new UnsupportedOperationException('Cannot dartObjectLocalStorage for unknown Storage object.');
31 """ { throw new UnsupportedOperationException(''); }
32
33 void set dartObjectLocalStorage(var value) native """
34 if (this === window.localStorage)
35 window._dartLocalStorageLocalStorage = value;
36 else if (this === window.sessionStorage)
37 window._dartSessionStorageLocalStorage = value;
38 else
39 throw new UnsupportedOperationException('Cannot dartObjectLocalStorage for unknown Storage object.');
40 """ { throw new UnsupportedOperationException(''); }
41 }
OLDNEW
« no previous file with comments | « client/dom/generated/src/frog/SpeechInputResultList.dart ('k') | client/dom/generated/src/frog/StorageEvent.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698