OLD | NEW |
1 # Copyright 2013 The Chromium Authors. All rights reserved. | 1 # Copyright 2013 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 from copy import deepcopy | 5 from copy import deepcopy |
6 import json | 6 import json |
7 | 7 |
8 from data_source import DataSource | 8 from data_source import DataSource |
9 from future import Future | 9 from future import Future |
10 from manifest_features import ConvertDottedKeysToNested | 10 from manifest_features import ConvertDottedKeysToNested |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
131 def _GetCachedManifestData(self): | 131 def _GetCachedManifestData(self): |
132 data = self._object_store.Get('manifest_data').Get() | 132 data = self._object_store.Get('manifest_data').Get() |
133 if data is None: | 133 if data is None: |
134 data = self._CreateManifestData().Get() | 134 data = self._CreateManifestData().Get() |
135 self._object_store.Set('manifest_data', data) | 135 self._object_store.Set('manifest_data', data) |
136 return data | 136 return data |
137 | 137 |
138 def get(self, key): | 138 def get(self, key): |
139 return self._GetCachedManifestData().get(key) | 139 return self._GetCachedManifestData().get(key) |
140 | 140 |
141 def Refresh(self, path): | 141 def Refresh(self): |
142 return self._CreateManifestData() | 142 return self._CreateManifestData() |
OLD | NEW |