OLD | NEW |
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file |
2 // for details. All rights reserved. Use of this source code is governed by a | 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. | 3 // BSD-style license that can be found in the LICENSE file. |
4 | 4 |
5 part of service; | 5 part of service; |
6 | 6 |
7 // Some value smaller than the object ring, so requesting a large array | 7 // Some value smaller than the object ring, so requesting a large array |
8 // doesn't result in an expired ref because the elements lapped it in the | 8 // doesn't result in an expired ref because the elements lapped it in the |
9 // object ring. | 9 // object ring. |
10 const int kDefaultFieldLimit = 100; | 10 const int kDefaultFieldLimit = 100; |
(...skipping 1182 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1193 Future<Class> getClassHierarchy() { | 1193 Future<Class> getClassHierarchy() { |
1194 return invokeRpc('getClassList', {}) | 1194 return invokeRpc('getClassList', {}) |
1195 .then(_loadClasses) | 1195 .then(_loadClasses) |
1196 .then(_buildClassHierarchy); | 1196 .then(_buildClassHierarchy); |
1197 } | 1197 } |
1198 | 1198 |
1199 Future<ServiceObject> getPorts() { | 1199 Future<ServiceObject> getPorts() { |
1200 return invokeRpc('_getPorts', {}); | 1200 return invokeRpc('_getPorts', {}); |
1201 } | 1201 } |
1202 | 1202 |
| 1203 Future<ServiceObject> getPersistentHandles() { |
| 1204 return invokeRpc('_getPersistentHandles', {}); |
| 1205 } |
| 1206 |
1203 Future<List<Class>> getClassRefs() async { | 1207 Future<List<Class>> getClassRefs() async { |
1204 ServiceMap classList = await invokeRpc('getClassList', {}); | 1208 ServiceMap classList = await invokeRpc('getClassList', {}); |
1205 assert(classList.type == 'ClassList'); | 1209 assert(classList.type == 'ClassList'); |
1206 var classRefs = []; | 1210 var classRefs = []; |
1207 for (var cls in classList['classes']) { | 1211 for (var cls in classList['classes']) { |
1208 // Skip over non-class classes. | 1212 // Skip over non-class classes. |
1209 if (cls is Class) { | 1213 if (cls is Class) { |
1210 _classesByCid[cls.vmCid] = cls; | 1214 _classesByCid[cls.vmCid] = cls; |
1211 classRefs.add(cls); | 1215 classRefs.add(cls); |
1212 } | 1216 } |
(...skipping 2794 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4007 var v = list[i]; | 4011 var v = list[i]; |
4008 if ((v is ObservableMap) && _isServiceMap(v)) { | 4012 if ((v is ObservableMap) && _isServiceMap(v)) { |
4009 list[i] = owner.getFromMap(v); | 4013 list[i] = owner.getFromMap(v); |
4010 } else if (v is ObservableList) { | 4014 } else if (v is ObservableList) { |
4011 _upgradeObservableList(v, owner); | 4015 _upgradeObservableList(v, owner); |
4012 } else if (v is ObservableMap) { | 4016 } else if (v is ObservableMap) { |
4013 _upgradeObservableMap(v, owner); | 4017 _upgradeObservableMap(v, owner); |
4014 } | 4018 } |
4015 } | 4019 } |
4016 } | 4020 } |
OLD | NEW |