OLD | NEW |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 library authentication_mojom; | 5 library authentication_mojom; |
6 | 6 |
7 import 'dart:async'; | 7 import 'dart:async'; |
8 | 8 |
9 import 'package:mojo/bindings.dart' as bindings; | 9 import 'package:mojo/bindings.dart' as bindings; |
10 import 'package:mojo/core.dart' as core; | 10 import 'package:mojo/core.dart' as core; |
(...skipping 429 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
440 | 440 |
441 | 441 |
442 | 442 |
443 const int _AuthenticationService_selectAccountName = 0; | 443 const int _AuthenticationService_selectAccountName = 0; |
444 const int _AuthenticationService_getOAuth2TokenName = 1; | 444 const int _AuthenticationService_getOAuth2TokenName = 1; |
445 const int _AuthenticationService_clearOAuth2TokenName = 2; | 445 const int _AuthenticationService_clearOAuth2TokenName = 2; |
446 | 446 |
447 | 447 |
448 | 448 |
449 class _AuthenticationServiceServiceDescription implements service_describer.Serv
iceDescription { | 449 class _AuthenticationServiceServiceDescription implements service_describer.Serv
iceDescription { |
450 dynamic getTopLevelInterface([Function responseFactory]) => null; | 450 dynamic getTopLevelInterface([Function responseFactory]) => |
| 451 responseFactory(null); |
451 | 452 |
452 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => null; | 453 dynamic getTypeDefinition(String typeKey, [Function responseFactory]) => |
| 454 responseFactory(null); |
453 | 455 |
454 dynamic getAllTypeDefinitions([Function responseFactory]) => null; | 456 dynamic getAllTypeDefinitions([Function responseFactory]) => |
| 457 responseFactory(null); |
455 } | 458 } |
456 | 459 |
457 abstract class AuthenticationService { | 460 abstract class AuthenticationService { |
458 static const String serviceName = "authentication::AuthenticationService"; | 461 static const String serviceName = "authentication::AuthenticationService"; |
459 dynamic selectAccount(bool returnLastSelected,[Function responseFactory = null
]); | 462 dynamic selectAccount(bool returnLastSelected,[Function responseFactory = null
]); |
460 dynamic getOAuth2Token(String username,List<String> scopes,[Function responseF
actory = null]); | 463 dynamic getOAuth2Token(String username,List<String> scopes,[Function responseF
actory = null]); |
461 void clearOAuth2Token(String token); | 464 void clearOAuth2Token(String token); |
462 } | 465 } |
463 | 466 |
464 | 467 |
(...skipping 267 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
732 _impl = d; | 735 _impl = d; |
733 } | 736 } |
734 | 737 |
735 String toString() { | 738 String toString() { |
736 var superString = super.toString(); | 739 var superString = super.toString(); |
737 return "AuthenticationServiceStub($superString)"; | 740 return "AuthenticationServiceStub($superString)"; |
738 } | 741 } |
739 | 742 |
740 int get version => 0; | 743 int get version => 0; |
741 | 744 |
742 service_describer.ServiceDescription get serviceDescription => | 745 static service_describer.ServiceDescription _cachedServiceDescription; |
743 new _AuthenticationServiceServiceDescription(); | 746 static service_describer.ServiceDescription get serviceDescription { |
| 747 if (_cachedServiceDescription == null) { |
| 748 _cachedServiceDescription = new _AuthenticationServiceServiceDescription()
; |
| 749 } |
| 750 return _cachedServiceDescription; |
| 751 } |
744 } | 752 } |
745 | 753 |
746 | 754 |
747 | 755 |
OLD | NEW |