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

Unified Diff: mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart

Issue 1998433002: Dart: Adds Interface and InterfaceRequest interfaces. (Closed) Base URL: git@github.com:domokit/mojo.git@master
Patch Set: Merge Created 4 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart
diff --git a/mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart b/mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart
index e7ae665e2d2e48507c547f0dc819f834bba0e12a..78269a657455996b5f5ad31e3dfe46d0969d6578 100644
--- a/mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart
+++ b/mojo/dart/packages/mojo_services/lib/mojo/authenticating_url_loader_interceptor_meta_factory.mojom.dart
@@ -16,8 +16,8 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryCreateUrlLoaderInterceptorFa
static const List<bindings.StructDataHeader> kVersions = const [
const bindings.StructDataHeader(24, 0)
];
- Object factoryRequest = null;
- Object authenticationService = null;
+ url_loader_interceptor_mojom.UrlLoaderInterceptorFactoryInterfaceRequest factoryRequest = null;
+ authentication_mojom.AuthenticationServiceInterface authenticationService = null;
_AuthenticatingUrlLoaderInterceptorMetaFactoryCreateUrlLoaderInterceptorFactoryParams() : super(kVersions.last.size);
@@ -110,12 +110,50 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryServiceDescription implement
abstract class AuthenticatingUrlLoaderInterceptorMetaFactory {
static const String serviceName = "mojo::AuthenticatingURLLoaderInterceptorMetaFactory";
- void createUrlLoaderInterceptorFactory(Object factoryRequest, Object authenticationService);
+
+ static service_describer.ServiceDescription _cachedServiceDescription;
+ static service_describer.ServiceDescription get serviceDescription {
+ if (_cachedServiceDescription == null) {
+ _cachedServiceDescription = new _AuthenticatingUrlLoaderInterceptorMetaFactoryServiceDescription();
+ }
+ return _cachedServiceDescription;
+ }
+
+ static AuthenticatingUrlLoaderInterceptorMetaFactoryProxy connectToService(
+ bindings.ServiceConnector s, String url, [String serviceName]) {
+ AuthenticatingUrlLoaderInterceptorMetaFactoryProxy p = new AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.unbound();
+ String name = serviceName ?? AuthenticatingUrlLoaderInterceptorMetaFactory.serviceName;
+ if ((name == null) || name.isEmpty) {
+ throw new core.MojoApiError(
+ "If an interface has no ServiceName, then one must be provided.");
+ }
+ s.connectToService(url, p, name);
+ return p;
+ }
+ void createUrlLoaderInterceptorFactory(url_loader_interceptor_mojom.UrlLoaderInterceptorFactoryInterfaceRequest factoryRequest, authentication_mojom.AuthenticationServiceInterface authenticationService);
+}
+
+abstract class AuthenticatingUrlLoaderInterceptorMetaFactoryInterface
+ implements bindings.MojoInterface<AuthenticatingUrlLoaderInterceptorMetaFactory>,
+ AuthenticatingUrlLoaderInterceptorMetaFactory {
+ factory AuthenticatingUrlLoaderInterceptorMetaFactoryInterface([AuthenticatingUrlLoaderInterceptorMetaFactory impl]) =>
+ new AuthenticatingUrlLoaderInterceptorMetaFactoryStub.unbound(impl);
+ factory AuthenticatingUrlLoaderInterceptorMetaFactoryInterface.fromEndpoint(
+ core.MojoMessagePipeEndpoint endpoint,
+ [AuthenticatingUrlLoaderInterceptorMetaFactory impl]) =>
+ new AuthenticatingUrlLoaderInterceptorMetaFactoryStub.fromEndpoint(endpoint, impl);
+}
+
+abstract class AuthenticatingUrlLoaderInterceptorMetaFactoryInterfaceRequest
+ implements bindings.MojoInterface<AuthenticatingUrlLoaderInterceptorMetaFactory>,
+ AuthenticatingUrlLoaderInterceptorMetaFactory {
+ factory AuthenticatingUrlLoaderInterceptorMetaFactoryInterfaceRequest() =>
+ new AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.unbound();
}
class _AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl
extends bindings.ProxyMessageHandler
- implements bindings.ProxyControl {
+ implements bindings.ProxyControl<AuthenticatingUrlLoaderInterceptorMetaFactory> {
_AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl.fromEndpoint(
core.MojoMessagePipeEndpoint endpoint) : super.fromEndpoint(endpoint);
@@ -124,9 +162,6 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl
_AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl.unbound() : super.unbound();
- service_describer.ServiceDescription get serviceDescription =>
- new _AuthenticatingUrlLoaderInterceptorMetaFactoryServiceDescription();
-
String get serviceName => AuthenticatingUrlLoaderInterceptorMetaFactory.serviceName;
void handleResponse(bindings.ServiceMessage message) {
@@ -138,6 +173,11 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl
}
}
+ AuthenticatingUrlLoaderInterceptorMetaFactory get impl => null;
+ set impl(AuthenticatingUrlLoaderInterceptorMetaFactory _) {
+ throw new core.MojoApiError("The impl of a Proxy cannot be set.");
+ }
+
@override
String toString() {
var superString = super.toString();
@@ -146,8 +186,10 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl
}
class AuthenticatingUrlLoaderInterceptorMetaFactoryProxy
- extends bindings.Proxy
- implements AuthenticatingUrlLoaderInterceptorMetaFactory {
+ extends bindings.Proxy<AuthenticatingUrlLoaderInterceptorMetaFactory>
+ implements AuthenticatingUrlLoaderInterceptorMetaFactory,
+ AuthenticatingUrlLoaderInterceptorMetaFactoryInterface,
+ AuthenticatingUrlLoaderInterceptorMetaFactoryInterfaceRequest {
AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.fromEndpoint(
core.MojoMessagePipeEndpoint endpoint)
: super(new _AuthenticatingUrlLoaderInterceptorMetaFactoryProxyControl.fromEndpoint(endpoint));
@@ -164,15 +206,8 @@ class AuthenticatingUrlLoaderInterceptorMetaFactoryProxy
return new AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.fromEndpoint(endpoint);
}
- factory AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.connectToService(
- bindings.ServiceConnector s, String url, [String serviceName]) {
- AuthenticatingUrlLoaderInterceptorMetaFactoryProxy p = new AuthenticatingUrlLoaderInterceptorMetaFactoryProxy.unbound();
- s.connectToService(url, p, serviceName);
- return p;
- }
-
- void createUrlLoaderInterceptorFactory(Object factoryRequest, Object authenticationService) {
+ void createUrlLoaderInterceptorFactory(url_loader_interceptor_mojom.UrlLoaderInterceptorFactoryInterfaceRequest factoryRequest, authentication_mojom.AuthenticationServiceInterface authenticationService) {
if (!ctrl.isBound) {
ctrl.proxyError("The Proxy is closed.");
return;
@@ -204,6 +239,8 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl
_AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.unbound([this._impl]) : super.unbound();
+ String get serviceName => AuthenticatingUrlLoaderInterceptorMetaFactory.serviceName;
+
dynamic handleMessage(bindings.ServiceMessage message) {
@@ -254,19 +291,16 @@ class _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl
}
int get version => 0;
-
- static service_describer.ServiceDescription _cachedServiceDescription;
- static service_describer.ServiceDescription get serviceDescription {
- if (_cachedServiceDescription == null) {
- _cachedServiceDescription = new _AuthenticatingUrlLoaderInterceptorMetaFactoryServiceDescription();
- }
- return _cachedServiceDescription;
- }
}
class AuthenticatingUrlLoaderInterceptorMetaFactoryStub
extends bindings.Stub<AuthenticatingUrlLoaderInterceptorMetaFactory>
- implements AuthenticatingUrlLoaderInterceptorMetaFactory {
+ implements AuthenticatingUrlLoaderInterceptorMetaFactory,
+ AuthenticatingUrlLoaderInterceptorMetaFactoryInterface,
+ AuthenticatingUrlLoaderInterceptorMetaFactoryInterfaceRequest {
+ AuthenticatingUrlLoaderInterceptorMetaFactoryStub.unbound([AuthenticatingUrlLoaderInterceptorMetaFactory impl])
+ : super(new _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.unbound(impl));
+
AuthenticatingUrlLoaderInterceptorMetaFactoryStub.fromEndpoint(
core.MojoMessagePipeEndpoint endpoint, [AuthenticatingUrlLoaderInterceptorMetaFactory impl])
: super(new _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.fromEndpoint(endpoint, impl));
@@ -275,20 +309,14 @@ class AuthenticatingUrlLoaderInterceptorMetaFactoryStub
core.MojoHandle handle, [AuthenticatingUrlLoaderInterceptorMetaFactory impl])
: super(new _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.fromHandle(handle, impl));
- AuthenticatingUrlLoaderInterceptorMetaFactoryStub.unbound([AuthenticatingUrlLoaderInterceptorMetaFactory impl])
- : super(new _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.unbound(impl));
-
static AuthenticatingUrlLoaderInterceptorMetaFactoryStub newFromEndpoint(
core.MojoMessagePipeEndpoint endpoint) {
assert(endpoint.setDescription("For AuthenticatingUrlLoaderInterceptorMetaFactoryStub"));
return new AuthenticatingUrlLoaderInterceptorMetaFactoryStub.fromEndpoint(endpoint);
}
- static service_describer.ServiceDescription get serviceDescription =>
- _AuthenticatingUrlLoaderInterceptorMetaFactoryStubControl.serviceDescription;
-
- void createUrlLoaderInterceptorFactory(Object factoryRequest, Object authenticationService) {
+ void createUrlLoaderInterceptorFactory(url_loader_interceptor_mojom.UrlLoaderInterceptorFactoryInterfaceRequest factoryRequest, authentication_mojom.AuthenticationServiceInterface authenticationService) {
return impl.createUrlLoaderInterceptorFactory(factoryRequest, authenticationService);
}
}

Powered by Google App Engine
This is Rietveld 408576698