From 5d403966d5f888274c6d21195fa8417328b5b973 Mon Sep 17 00:00:00 2001 From: Misko Hevery Date: Fri, 21 Aug 2015 12:21:29 -0700 Subject: [PATCH] refactor: rename web-workers to web_workers Closes #3683 --- .../angular2/src/test_lib/test_injector.ts | 2 +- .../shared/api.ts | 0 .../shared/isolate_message_bus.dart | 2 +- .../shared/message_bus.ts | 17 +++-------- .../shared/messaging_api.ts | 0 .../shared/post_message_bus.dart | 0 .../shared/post_message_bus.ts | 6 ++-- .../shared/render_proto_view_ref_store.ts | 2 +- .../render_view_with_fragments_store.ts | 2 +- .../shared/serializer.ts | 6 ++-- .../ui/application.dart | 6 ++-- .../ui/application.ts | 6 ++-- .../ui/di_bindings.ts | 22 +++++++-------- .../ui/event_dispatcher.ts | 4 +-- .../ui/event_serializer.dart | 0 .../ui/event_serializer.ts | 0 .../{web-workers => web_workers}/ui/impl.ts | 10 +++---- .../ui/render_compiler.ts | 8 +++--- .../ui/renderer.ts | 14 +++++----- .../{web-workers => web_workers}/ui/setup.ts | 6 ++-- .../ui/xhr_impl.ts | 8 +++--- .../worker/application.dart | 4 +-- .../worker/application.ts | 4 +-- .../worker/application_common.ts | 28 +++++++++---------- .../worker/broker.ts | 4 +-- .../worker/event_deserializer.dart | 0 .../worker/event_deserializer.ts | 0 .../worker/event_dispatcher.ts | 6 ++-- .../worker/renderer.ts | 10 +++---- .../worker/xhr_impl.ts | 4 +-- .../shared/message_bus_spec.ts | 4 +-- .../shared/message_bus_util.dart | 8 +++--- .../shared/message_bus_util.ts | 6 ++-- .../render_proto_view_ref_store_spec.ts | 2 +- .../render_view_with_fragments_store_spec.ts | 2 +- .../worker/event_dispatcher_spec.ts | 12 ++++---- .../worker/mock_event_emitter.dart | 0 .../worker/mock_event_emitter.ts | 0 .../worker/renderer_integration_spec.ts | 16 +++++------ .../worker/worker_test_util.ts | 5 ++-- .../worker/xhr_impl_spec.ts | 4 +-- .../src/message_broker/background_index.dart | 8 +++--- .../src/message_broker/background_index.ts | 6 ++-- .../examples/src/message_broker/index.dart | 2 +- modules/examples/src/message_broker/index.ts | 2 +- .../web_workers/images/background_index.dart | 2 +- .../web_workers/images/background_index.ts | 2 +- .../src/web_workers/images/index.dart | 2 +- .../examples/src/web_workers/images/index.ts | 2 +- .../kitchen_sink/background_index.dart | 2 +- .../kitchen_sink/background_index.ts | 2 +- .../src/web_workers/kitchen_sink/index.dart | 2 +- .../src/web_workers/kitchen_sink/index.ts | 4 +-- .../web_workers/todo/background_index.dart | 2 +- .../src/web_workers/todo/background_index.ts | 2 +- .../examples/src/web_workers/todo/index.dart | 2 +- .../examples/src/web_workers/todo/index.ts | 2 +- 57 files changed, 137 insertions(+), 147 deletions(-) rename modules/angular2/src/{web-workers => web_workers}/shared/api.ts (100%) rename modules/angular2/src/{web-workers => web_workers}/shared/isolate_message_bus.dart (96%) rename modules/angular2/src/{web-workers => web_workers}/shared/message_bus.ts (73%) rename modules/angular2/src/{web-workers => web_workers}/shared/messaging_api.ts (100%) rename modules/angular2/src/{web-workers => web_workers}/shared/post_message_bus.dart (100%) rename modules/angular2/src/{web-workers => web_workers}/shared/post_message_bus.ts (94%) rename modules/angular2/src/{web-workers => web_workers}/shared/render_proto_view_ref_store.ts (96%) rename modules/angular2/src/{web-workers => web_workers}/shared/render_view_with_fragments_store.ts (98%) rename modules/angular2/src/{web-workers => web_workers}/shared/serializer.ts (98%) rename modules/angular2/src/{web-workers => web_workers}/ui/application.dart (87%) rename modules/angular2/src/{web-workers => web_workers}/ui/application.ts (81%) rename modules/angular2/src/{web-workers => web_workers}/ui/di_bindings.ts (88%) rename modules/angular2/src/{web-workers => web_workers}/ui/event_dispatcher.ts (96%) rename modules/angular2/src/{web-workers => web_workers}/ui/event_serializer.dart (100%) rename modules/angular2/src/{web-workers => web_workers}/ui/event_serializer.ts (100%) rename modules/angular2/src/{web-workers => web_workers}/ui/impl.ts (82%) rename modules/angular2/src/{web-workers => web_workers}/ui/render_compiler.ts (90%) rename modules/angular2/src/{web-workers => web_workers}/ui/renderer.ts (91%) rename modules/angular2/src/{web-workers => web_workers}/ui/setup.ts (83%) rename modules/angular2/src/{web-workers => web_workers}/ui/xhr_impl.ts (85%) rename modules/angular2/src/{web-workers => web_workers}/worker/application.dart (91%) rename modules/angular2/src/{web-workers => web_workers}/worker/application.ts (92%) rename modules/angular2/src/{web-workers => web_workers}/worker/application_common.ts (88%) rename modules/angular2/src/{web-workers => web_workers}/worker/broker.ts (96%) rename modules/angular2/src/{web-workers => web_workers}/worker/event_deserializer.dart (100%) rename modules/angular2/src/{web-workers => web_workers}/worker/event_deserializer.ts (100%) rename modules/angular2/src/{web-workers => web_workers}/worker/event_dispatcher.ts (90%) rename modules/angular2/src/{web-workers => web_workers}/worker/renderer.ts (97%) rename modules/angular2/src/{web-workers => web_workers}/worker/xhr_impl.ts (88%) rename modules/angular2/test/{web-workers => web_workers}/shared/message_bus_spec.ts (96%) rename modules/angular2/test/{web-workers => web_workers}/shared/message_bus_util.dart (68%) rename modules/angular2/test/{web-workers => web_workers}/shared/message_bus_util.ts (77%) rename modules/angular2/test/{web-workers => web_workers}/shared/render_proto_view_ref_store_spec.ts (93%) rename modules/angular2/test/{web-workers => web_workers}/shared/render_view_with_fragments_store_spec.ts (98%) rename modules/angular2/test/{web-workers => web_workers}/worker/event_dispatcher_spec.ts (86%) rename modules/angular2/test/{web-workers => web_workers}/worker/mock_event_emitter.dart (100%) rename modules/angular2/test/{web-workers => web_workers}/worker/mock_event_emitter.ts (100%) rename modules/angular2/test/{web-workers => web_workers}/worker/renderer_integration_spec.ts (96%) rename modules/angular2/test/{web-workers => web_workers}/worker/worker_test_util.ts (92%) rename modules/angular2/test/{web-workers => web_workers}/worker/xhr_impl_spec.ts (93%) diff --git a/modules/angular2/src/test_lib/test_injector.ts b/modules/angular2/src/test_lib/test_injector.ts index 53cb95973f..455043d932 100644 --- a/modules/angular2/src/test_lib/test_injector.ts +++ b/modules/angular2/src/test_lib/test_injector.ts @@ -63,7 +63,7 @@ import { } from 'angular2/src/render/render'; import {ElementSchemaRegistry} from 'angular2/src/render/dom/schema/element_schema_registry'; import {DomElementSchemaRegistry} from 'angular2/src/render/dom/schema/dom_element_schema_registry'; -import {Serializer} from "angular2/src/web-workers/shared/serializer"; +import {Serializer} from "angular2/src/web_workers/shared/serializer"; import {Log} from './utils'; /** diff --git a/modules/angular2/src/web-workers/shared/api.ts b/modules/angular2/src/web_workers/shared/api.ts similarity index 100% rename from modules/angular2/src/web-workers/shared/api.ts rename to modules/angular2/src/web_workers/shared/api.ts diff --git a/modules/angular2/src/web-workers/shared/isolate_message_bus.dart b/modules/angular2/src/web_workers/shared/isolate_message_bus.dart similarity index 96% rename from modules/angular2/src/web-workers/shared/isolate_message_bus.dart rename to modules/angular2/src/web_workers/shared/isolate_message_bus.dart index 7d60e5882a..d268dce41c 100644 --- a/modules/angular2/src/web-workers/shared/isolate_message_bus.dart +++ b/modules/angular2/src/web_workers/shared/isolate_message_bus.dart @@ -3,7 +3,7 @@ library angular2.src.web_workers.shared.isolate_message_bus; import 'dart:isolate'; import 'dart:async'; import 'dart:core'; -import 'package:angular2/src/web-workers/shared/message_bus.dart' +import 'package:angular2/src/web_workers/shared/message_bus.dart' show MessageBus, MessageBusSink, MessageBusSource; import 'package:angular2/src/facade/async.dart'; diff --git a/modules/angular2/src/web-workers/shared/message_bus.ts b/modules/angular2/src/web_workers/shared/message_bus.ts similarity index 73% rename from modules/angular2/src/web-workers/shared/message_bus.ts rename to modules/angular2/src/web_workers/shared/message_bus.ts index 65e6e5bfe1..9192fa5735 100644 --- a/modules/angular2/src/web-workers/shared/message_bus.ts +++ b/modules/angular2/src/web_workers/shared/message_bus.ts @@ -1,6 +1,5 @@ import {EventEmitter} from 'angular2/src/facade/async'; import {BaseException} from 'angular2/src/facade/lang'; -// TODO(jteplitz602): Replace both the interface and the exported class with an abstract class #3683 function _abstract() { throw new BaseException("This method is abstract"); @@ -11,21 +10,20 @@ function _abstract() { * Communication is based on a channel abstraction. Messages published in a * given channel to one MessageBusSink are received on the same channel * by the corresponding MessageBusSource. - * TODO(jteplitz602): This should just extend both the source and the sink once - * https://github.com/angular/ts2dart/issues/263 is closed. */ -export interface MessageBusInterface { +export /* abstract (with TS 1.6) */ class MessageBus implements MessageBusSource, MessageBusSink { /** * Returns an {@link EventEmitter} that emits every time a messsage * is received on the given channel. */ - from(channel: string): EventEmitter; + from(channel: string): EventEmitter { throw _abstract(); } + /** * Returns an {@link EventEmitter} for the given channel * To publish methods to that channel just call next (or add in dart) on the returned emitter */ - to(channel: string): EventEmitter; + to(channel: string): EventEmitter { throw _abstract(); } } export interface MessageBusSource { @@ -43,10 +41,3 @@ export interface MessageBusSink { */ to(channel: string): EventEmitter; } - -// TODO(jteplitz602): Remove this class once we have abstract classes #3683 -export class MessageBus implements MessageBusInterface { - from(channel: string): EventEmitter { throw _abstract(); } - - to(channel: string): EventEmitter { throw _abstract(); } -} diff --git a/modules/angular2/src/web-workers/shared/messaging_api.ts b/modules/angular2/src/web_workers/shared/messaging_api.ts similarity index 100% rename from modules/angular2/src/web-workers/shared/messaging_api.ts rename to modules/angular2/src/web_workers/shared/messaging_api.ts diff --git a/modules/angular2/src/web-workers/shared/post_message_bus.dart b/modules/angular2/src/web_workers/shared/post_message_bus.dart similarity index 100% rename from modules/angular2/src/web-workers/shared/post_message_bus.dart rename to modules/angular2/src/web_workers/shared/post_message_bus.dart diff --git a/modules/angular2/src/web-workers/shared/post_message_bus.ts b/modules/angular2/src/web_workers/shared/post_message_bus.ts similarity index 94% rename from modules/angular2/src/web-workers/shared/post_message_bus.ts rename to modules/angular2/src/web_workers/shared/post_message_bus.ts index cdd807efe2..0a230dec13 100644 --- a/modules/angular2/src/web-workers/shared/post_message_bus.ts +++ b/modules/angular2/src/web_workers/shared/post_message_bus.ts @@ -1,8 +1,8 @@ import { - MessageBusInterface, + MessageBus, MessageBusSource, MessageBusSink -} from "angular2/src/web-workers/shared/message_bus"; +} from "angular2/src/web_workers/shared/message_bus"; import {EventEmitter} from 'angular2/src/facade/async'; import {StringMap, StringMapWrapper} from 'angular2/src/facade/collection'; import {Injectable} from "angular2/di"; @@ -12,7 +12,7 @@ import {Injectable} from "angular2/di"; * postMessage API. */ @Injectable() -export class PostMessageBus implements MessageBusInterface { +export class PostMessageBus implements MessageBus { constructor(private _sink: PostMessageBusSink, private _source: PostMessageBusSource) {} from(channel: string): EventEmitter { return this._source.from(channel); } diff --git a/modules/angular2/src/web-workers/shared/render_proto_view_ref_store.ts b/modules/angular2/src/web_workers/shared/render_proto_view_ref_store.ts similarity index 96% rename from modules/angular2/src/web-workers/shared/render_proto_view_ref_store.ts rename to modules/angular2/src/web_workers/shared/render_proto_view_ref_store.ts index ef46bc0dcf..26f035c920 100644 --- a/modules/angular2/src/web-workers/shared/render_proto_view_ref_store.ts +++ b/modules/angular2/src/web_workers/shared/render_proto_view_ref_store.ts @@ -1,6 +1,6 @@ import {Injectable, Inject} from "angular2/di"; import {RenderProtoViewRef} from "angular2/src/render/api"; -import {ON_WEB_WORKER} from "angular2/src/web-workers/shared/api"; +import {ON_WEB_WORKER} from "angular2/src/web_workers/shared/api"; @Injectable() export class RenderProtoViewRefStore { diff --git a/modules/angular2/src/web-workers/shared/render_view_with_fragments_store.ts b/modules/angular2/src/web_workers/shared/render_view_with_fragments_store.ts similarity index 98% rename from modules/angular2/src/web-workers/shared/render_view_with_fragments_store.ts rename to modules/angular2/src/web_workers/shared/render_view_with_fragments_store.ts index a7d7ef48d6..568b124f0f 100644 --- a/modules/angular2/src/web-workers/shared/render_view_with_fragments_store.ts +++ b/modules/angular2/src/web_workers/shared/render_view_with_fragments_store.ts @@ -1,6 +1,6 @@ import {Injectable, Inject} from "angular2/di"; import {RenderViewRef, RenderFragmentRef, RenderViewWithFragments} from "angular2/src/render/api"; -import {ON_WEB_WORKER} from "angular2/src/web-workers/shared/api"; +import {ON_WEB_WORKER} from "angular2/src/web_workers/shared/api"; import {List, ListWrapper} from "angular2/src/facade/collection"; @Injectable() diff --git a/modules/angular2/src/web-workers/shared/serializer.ts b/modules/angular2/src/web_workers/shared/serializer.ts similarity index 98% rename from modules/angular2/src/web-workers/shared/serializer.ts rename to modules/angular2/src/web_workers/shared/serializer.ts index 9d8940accf..4a476247e1 100644 --- a/modules/angular2/src/web-workers/shared/serializer.ts +++ b/modules/angular2/src/web_workers/shared/serializer.ts @@ -31,14 +31,14 @@ import { ViewEncapsulation, PropertyBindingType } from "angular2/src/render/api"; -import {WebWorkerElementRef} from 'angular2/src/web-workers/shared/api'; +import {WebWorkerElementRef} from 'angular2/src/web_workers/shared/api'; import {AST, ASTWithSource} from 'angular2/src/change_detection/change_detection'; import {Parser} from "angular2/src/change_detection/parser/parser"; import {Injectable} from "angular2/di"; -import {RenderProtoViewRefStore} from 'angular2/src/web-workers/shared/render_proto_view_ref_store'; +import {RenderProtoViewRefStore} from 'angular2/src/web_workers/shared/render_proto_view_ref_store'; import { RenderViewWithFragmentsStore -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; @Injectable() export class Serializer { diff --git a/modules/angular2/src/web-workers/ui/application.dart b/modules/angular2/src/web_workers/ui/application.dart similarity index 87% rename from modules/angular2/src/web-workers/ui/application.dart rename to modules/angular2/src/web_workers/ui/application.dart index fc51fc8641..9fb758d9b2 100644 --- a/modules/angular2/src/web-workers/ui/application.dart +++ b/modules/angular2/src/web_workers/ui/application.dart @@ -3,10 +3,10 @@ library angular2.src.web_workers.ui; import 'dart:isolate'; import 'dart:async'; import 'dart:core'; -import 'package:angular2/src/web-workers/shared/message_bus.dart' +import 'package:angular2/src/web_workers/shared/message_bus.dart' show MessageBus; -import 'package:angular2/src/web-workers/ui/impl.dart' show bootstrapUICommon; -import 'package:angular2/src/web-workers/shared/isolate_message_bus.dart'; +import 'package:angular2/src/web_workers/ui/impl.dart' show bootstrapUICommon; +import 'package:angular2/src/web_workers/shared/isolate_message_bus.dart'; /** * Bootstrapping a WebWorker diff --git a/modules/angular2/src/web-workers/ui/application.ts b/modules/angular2/src/web_workers/ui/application.ts similarity index 81% rename from modules/angular2/src/web-workers/ui/application.ts rename to modules/angular2/src/web_workers/ui/application.ts index 4d898c0a03..18947746e8 100644 --- a/modules/angular2/src/web-workers/ui/application.ts +++ b/modules/angular2/src/web_workers/ui/application.ts @@ -2,10 +2,10 @@ import { PostMessageBus, PostMessageBusSink, PostMessageBusSource -} from 'angular2/src/web-workers/shared/post_message_bus'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; +} from 'angular2/src/web_workers/shared/post_message_bus'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; import {BaseException} from "angular2/src/facade/lang"; -import {bootstrapUICommon} from "angular2/src/web-workers/ui/impl"; +import {bootstrapUICommon} from "angular2/src/web_workers/ui/impl"; /** * Bootstrapping a WebWorker diff --git a/modules/angular2/src/web-workers/ui/di_bindings.ts b/modules/angular2/src/web_workers/ui/di_bindings.ts similarity index 88% rename from modules/angular2/src/web-workers/ui/di_bindings.ts rename to modules/angular2/src/web_workers/ui/di_bindings.ts index c5b9c0a82c..79df3b79bf 100644 --- a/modules/angular2/src/web-workers/ui/di_bindings.ts +++ b/modules/angular2/src/web_workers/ui/di_bindings.ts @@ -52,19 +52,19 @@ import {UrlResolver} from 'angular2/src/services/url_resolver'; import {Testability} from 'angular2/src/core/testability/testability'; import {XHR} from 'angular2/src/render/xhr'; import {XHRImpl} from 'angular2/src/render/xhr_impl'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; -import {ON_WEB_WORKER} from 'angular2/src/web-workers/shared/api'; -import {RenderProtoViewRefStore} from 'angular2/src/web-workers/shared/render_proto_view_ref_store'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; +import {ON_WEB_WORKER} from 'angular2/src/web_workers/shared/api'; +import {RenderProtoViewRefStore} from 'angular2/src/web_workers/shared/render_proto_view_ref_store'; import { RenderViewWithFragmentsStore -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; import {AnchorBasedAppRootUrl} from 'angular2/src/services/anchor_based_app_root_url'; -import {WebWorkerMain} from 'angular2/src/web-workers/ui/impl'; -import {MessageBus, MessageBusInterface} from 'angular2/src/web-workers/shared/message_bus'; -import {MessageBasedRenderCompiler} from 'angular2/src/web-workers/ui/render_compiler'; -import {MessageBasedRenderer} from 'angular2/src/web-workers/ui/renderer'; -import {MessageBasedXHRImpl} from 'angular2/src/web-workers/ui/xhr_impl'; -import {WebWorkerSetup} from 'angular2/src/web-workers/ui/setup'; +import {WebWorkerMain} from 'angular2/src/web_workers/ui/impl'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; +import {MessageBasedRenderCompiler} from 'angular2/src/web_workers/ui/render_compiler'; +import {MessageBasedRenderer} from 'angular2/src/web_workers/ui/renderer'; +import {MessageBasedXHRImpl} from 'angular2/src/web_workers/ui/xhr_impl'; +import {WebWorkerSetup} from 'angular2/src/web_workers/ui/setup'; var _rootInjector: Injector; @@ -139,7 +139,7 @@ function _injectorBindings(): List { ]; } -export function createInjector(zone: NgZone, bus: MessageBusInterface): Injector { +export function createInjector(zone: NgZone, bus: MessageBus): Injector { BrowserDomAdapter.makeCurrent(); _rootBindings.push(bind(NgZone).toValue(zone)); _rootBindings.push(bind(MessageBus).toValue(bus)); diff --git a/modules/angular2/src/web-workers/ui/event_dispatcher.ts b/modules/angular2/src/web_workers/ui/event_dispatcher.ts similarity index 96% rename from modules/angular2/src/web-workers/ui/event_dispatcher.ts rename to modules/angular2/src/web_workers/ui/event_dispatcher.ts index bdbad5b54a..e79fe60550 100644 --- a/modules/angular2/src/web-workers/ui/event_dispatcher.ts +++ b/modules/angular2/src/web_workers/ui/event_dispatcher.ts @@ -2,13 +2,13 @@ import { RenderViewRef, RenderEventDispatcher, } from 'angular2/src/render/api'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; import { serializeMouseEvent, serializeKeyboardEvent, serializeGenericEvent, serializeEventWithTarget -} from 'angular2/src/web-workers/ui/event_serializer'; +} from 'angular2/src/web_workers/ui/event_serializer'; import {BaseException} from "angular2/src/facade/lang"; import {StringMapWrapper} from 'angular2/src/facade/collection'; import {EventEmitter, ObservableWrapper} from 'angular2/src/facade/async'; diff --git a/modules/angular2/src/web-workers/ui/event_serializer.dart b/modules/angular2/src/web_workers/ui/event_serializer.dart similarity index 100% rename from modules/angular2/src/web-workers/ui/event_serializer.dart rename to modules/angular2/src/web_workers/ui/event_serializer.dart diff --git a/modules/angular2/src/web-workers/ui/event_serializer.ts b/modules/angular2/src/web_workers/ui/event_serializer.ts similarity index 100% rename from modules/angular2/src/web-workers/ui/event_serializer.ts rename to modules/angular2/src/web_workers/ui/event_serializer.ts diff --git a/modules/angular2/src/web-workers/ui/impl.ts b/modules/angular2/src/web_workers/ui/impl.ts similarity index 82% rename from modules/angular2/src/web-workers/ui/impl.ts rename to modules/angular2/src/web_workers/ui/impl.ts index ffa1e4893c..e38f362305 100644 --- a/modules/angular2/src/web-workers/ui/impl.ts +++ b/modules/angular2/src/web_workers/ui/impl.ts @@ -6,15 +6,15 @@ */ import {createInjector} from "./di_bindings"; -import {MessageBus, MessageBusSink} from "angular2/src/web-workers/shared/message_bus"; +import {MessageBus, MessageBusSink} from "angular2/src/web_workers/shared/message_bus"; import {createNgZone} from 'angular2/src/core/application_common'; import {Injectable} from 'angular2/di'; import {BrowserDomAdapter} from 'angular2/src/dom/browser_adapter'; import {wtfInit} from 'angular2/src/profile/wtf_init'; -import {WebWorkerSetup} from 'angular2/src/web-workers/ui/setup'; -import {MessageBasedRenderCompiler} from 'angular2/src/web-workers/ui/render_compiler'; -import {MessageBasedRenderer} from 'angular2/src/web-workers/ui/renderer'; -import {MessageBasedXHRImpl} from 'angular2/src/web-workers/ui/xhr_impl'; +import {WebWorkerSetup} from 'angular2/src/web_workers/ui/setup'; +import {MessageBasedRenderCompiler} from 'angular2/src/web_workers/ui/render_compiler'; +import {MessageBasedRenderer} from 'angular2/src/web_workers/ui/renderer'; +import {MessageBasedXHRImpl} from 'angular2/src/web_workers/ui/xhr_impl'; /** * Creates a zone, sets up the DI bindings diff --git a/modules/angular2/src/web-workers/ui/render_compiler.ts b/modules/angular2/src/web_workers/ui/render_compiler.ts similarity index 90% rename from modules/angular2/src/web-workers/ui/render_compiler.ts rename to modules/angular2/src/web_workers/ui/render_compiler.ts index 1efbfef675..6d1dad00d2 100644 --- a/modules/angular2/src/web-workers/ui/render_compiler.ts +++ b/modules/angular2/src/web_workers/ui/render_compiler.ts @@ -1,6 +1,6 @@ import {Injectable} from 'angular2/di'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; import { RenderDirectiveMetadata, ProtoViewDto, @@ -10,8 +10,8 @@ import { RenderCompiler } from 'angular2/src/render/api'; import {EventEmitter, ObservableWrapper, PromiseWrapper, Promise} from 'angular2/src/facade/async'; -import {RENDER_COMPILER_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; -import {ReceivedMessage} from 'angular2/src/web-workers/ui/impl'; +import {RENDER_COMPILER_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; +import {ReceivedMessage} from 'angular2/src/web_workers/ui/impl'; import {BaseException, Type} from 'angular2/src/facade/lang'; // TODO(jteplitz602): Create parent UIComponent class #3703 diff --git a/modules/angular2/src/web-workers/ui/renderer.ts b/modules/angular2/src/web_workers/ui/renderer.ts similarity index 91% rename from modules/angular2/src/web-workers/ui/renderer.ts rename to modules/angular2/src/web_workers/ui/renderer.ts index 2450f5fd3c..8d0e0e2a47 100644 --- a/modules/angular2/src/web-workers/ui/renderer.ts +++ b/modules/angular2/src/web_workers/ui/renderer.ts @@ -1,21 +1,21 @@ import {Injectable} from 'angular2/di'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; import { RenderViewRef, RenderFragmentRef, RenderProtoViewRef, Renderer } from 'angular2/src/render/api'; -import {WebWorkerElementRef} from 'angular2/src/web-workers/shared/api'; +import {WebWorkerElementRef} from 'angular2/src/web_workers/shared/api'; import {EventEmitter, ObservableWrapper, PromiseWrapper, Promise} from 'angular2/src/facade/async'; -import {EVENT_CHANNEL, RENDERER_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; -import {ReceivedMessage} from 'angular2/src/web-workers/ui/impl'; +import {EVENT_CHANNEL, RENDERER_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; +import {ReceivedMessage} from 'angular2/src/web_workers/ui/impl'; import {BaseException, Type} from 'angular2/src/facade/lang'; -import {EventDispatcher} from 'angular2/src/web-workers/ui/event_dispatcher'; +import {EventDispatcher} from 'angular2/src/web_workers/ui/event_dispatcher'; import { RenderViewWithFragmentsStore -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; @Injectable() export class MessageBasedRenderer { diff --git a/modules/angular2/src/web-workers/ui/setup.ts b/modules/angular2/src/web_workers/ui/setup.ts similarity index 83% rename from modules/angular2/src/web-workers/ui/setup.ts rename to modules/angular2/src/web_workers/ui/setup.ts index 89b1a0b410..7b84a254d3 100644 --- a/modules/angular2/src/web-workers/ui/setup.ts +++ b/modules/angular2/src/web_workers/ui/setup.ts @@ -1,6 +1,6 @@ -import {SETUP_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; +import {SETUP_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; import {EventEmitter, ObservableWrapper} from 'angular2/src/facade/async'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; import {AnchorBasedAppRootUrl} from 'angular2/src/services/anchor_based_app_root_url'; import {Injectable} from 'angular2/di'; @@ -17,4 +17,4 @@ export class WebWorkerSetup { } }); } -} \ No newline at end of file +} diff --git a/modules/angular2/src/web-workers/ui/xhr_impl.ts b/modules/angular2/src/web_workers/ui/xhr_impl.ts similarity index 85% rename from modules/angular2/src/web-workers/ui/xhr_impl.ts rename to modules/angular2/src/web_workers/ui/xhr_impl.ts index 683762d45f..83a8c2177f 100644 --- a/modules/angular2/src/web-workers/ui/xhr_impl.ts +++ b/modules/angular2/src/web_workers/ui/xhr_impl.ts @@ -1,9 +1,9 @@ import {Injectable} from 'angular2/di'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; import {EventEmitter, ObservableWrapper, PromiseWrapper, Promise} from 'angular2/src/facade/async'; -import {XHR_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; -import {ReceivedMessage} from 'angular2/src/web-workers/ui/impl'; +import {XHR_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; +import {ReceivedMessage} from 'angular2/src/web_workers/ui/impl'; import {BaseException, Type} from 'angular2/src/facade/lang'; import {XHR} from 'angular2/src/render/xhr'; diff --git a/modules/angular2/src/web-workers/worker/application.dart b/modules/angular2/src/web_workers/worker/application.dart similarity index 91% rename from modules/angular2/src/web-workers/worker/application.dart rename to modules/angular2/src/web_workers/worker/application.dart index 196a6ee7fc..4386c50bcd 100644 --- a/modules/angular2/src/web-workers/worker/application.dart +++ b/modules/angular2/src/web_workers/worker/application.dart @@ -1,7 +1,7 @@ library angular2.src.web_workers.worker; -import "package:angular2/src/web-workers/shared/isolate_message_bus.dart"; -import "package:angular2/src/web-workers/worker/application_common.dart" +import "package:angular2/src/web_workers/shared/isolate_message_bus.dart"; +import "package:angular2/src/web_workers/worker/application_common.dart" show bootstrapWebWorkerCommon; import "package:angular2/src/facade/async.dart" show Future; import "package:angular2/src/core/application_ref.dart" show ApplicationRef; diff --git a/modules/angular2/src/web-workers/worker/application.ts b/modules/angular2/src/web_workers/worker/application.ts similarity index 92% rename from modules/angular2/src/web-workers/worker/application.ts rename to modules/angular2/src/web_workers/worker/application.ts index b15b3335c8..50be81ba98 100644 --- a/modules/angular2/src/web-workers/worker/application.ts +++ b/modules/angular2/src/web_workers/worker/application.ts @@ -2,12 +2,12 @@ import { PostMessageBus, PostMessageBusSink, PostMessageBusSource -} from 'angular2/src/web-workers/shared/post_message_bus'; +} from 'angular2/src/web_workers/shared/post_message_bus'; import {Type, BaseException} from "angular2/src/facade/lang"; import {Binding} from "angular2/di"; import {Map} from 'angular2/src/facade/collection'; import {Promise} from 'angular2/src/facade/async'; -import {bootstrapWebWorkerCommon} from "angular2/src/web-workers/worker/application_common"; +import {bootstrapWebWorkerCommon} from "angular2/src/web_workers/worker/application_common"; import {ApplicationRef} from "angular2/src/core/application_ref"; import {Injectable} from "angular2/di"; diff --git a/modules/angular2/src/web-workers/worker/application_common.ts b/modules/angular2/src/web_workers/worker/application_common.ts similarity index 88% rename from modules/angular2/src/web-workers/worker/application_common.ts rename to modules/angular2/src/web_workers/worker/application_common.ts index f422fa4d73..a214291948 100644 --- a/modules/angular2/src/web-workers/worker/application_common.ts +++ b/modules/angular2/src/web_workers/worker/application_common.ts @@ -34,7 +34,7 @@ import {Promise, PromiseWrapper, PromiseCompleter} from 'angular2/src/facade/asy import {NgZone} from 'angular2/src/core/zone/ng_zone'; import {LifeCycle} from 'angular2/src/core/life_cycle/life_cycle'; import {XHR} from 'angular2/src/render/xhr'; -import {WebWorkerXHRImpl} from 'angular2/src/web-workers/worker/xhr_impl'; +import {WebWorkerXHRImpl} from 'angular2/src/web_workers/worker/xhr_impl'; import {ComponentUrlMapper} from 'angular2/src/core/compiler/component_url_mapper'; import {UrlResolver} from 'angular2/src/services/url_resolver'; import {AppRootUrl} from 'angular2/src/services/app_root_url'; @@ -52,19 +52,19 @@ import {WebWorkerRenderer, WebWorkerCompiler} from './renderer'; import {Renderer, RenderCompiler} from 'angular2/src/render/api'; import {internalView} from 'angular2/src/core/compiler/view_ref'; -import {MessageBrokerFactory} from 'angular2/src/web-workers/worker/broker'; -import {MessageBus, MessageBusInterface} from 'angular2/src/web-workers/shared/message_bus'; +import {MessageBrokerFactory} from 'angular2/src/web_workers/worker/broker'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; import {APP_COMPONENT_REF_PROMISE, APP_COMPONENT} from 'angular2/src/core/application_tokens'; import {ApplicationRef} from 'angular2/src/core/application_ref'; -import {Serializer} from "angular2/src/web-workers/shared/serializer"; -import {ON_WEB_WORKER} from "angular2/src/web-workers/shared/api"; -import {RenderProtoViewRefStore} from 'angular2/src/web-workers/shared/render_proto_view_ref_store'; +import {Serializer} from "angular2/src/web_workers/shared/serializer"; +import {ON_WEB_WORKER} from "angular2/src/web_workers/shared/api"; +import {RenderProtoViewRefStore} from 'angular2/src/web_workers/shared/render_proto_view_ref_store'; import { RenderViewWithFragmentsStore -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; import {ObservableWrapper} from 'angular2/src/facade/async'; -import {SETUP_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; -import {WebWorkerEventDispatcher} from 'angular2/src/web-workers/worker/event_dispatcher'; +import {SETUP_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; +import {WebWorkerEventDispatcher} from 'angular2/src/web_workers/worker/event_dispatcher'; var _rootInjector: Injector; @@ -77,8 +77,8 @@ class PrintLogger { logGroupEnd() {} } -function _injectorBindings(appComponentType, bus: MessageBusInterface, - initData: StringMap): List> { +function _injectorBindings(appComponentType, bus: MessageBus, initData: StringMap): + List> { var bestChangeDetection = new DynamicChangeDetection(); if (PreGeneratedChangeDetection.isSupported()) { bestChangeDetection = new PreGeneratedChangeDetection(); @@ -142,7 +142,7 @@ function _injectorBindings(appComponentType, bus: MessageBusInterface, } export function bootstrapWebWorkerCommon( - appComponentType: Type, bus: MessageBusInterface, + appComponentType: Type, bus: MessageBus, componentInjectableBindings: List> = null): Promise { var bootstrapProcess: PromiseCompleter = PromiseWrapper.completer(); @@ -187,8 +187,8 @@ export function bootstrapWebWorkerCommon( } function _createAppInjector(appComponentType: Type, bindings: List>, - zone: NgZone, bus: MessageBusInterface, - initData: StringMap): Injector { + zone: NgZone, bus: MessageBus, initData: StringMap): + Injector { if (isBlank(_rootInjector)) _rootInjector = Injector.resolveAndCreate(_rootBindings); var mergedBindings: any[] = isPresent(bindings) ? diff --git a/modules/angular2/src/web-workers/worker/broker.ts b/modules/angular2/src/web_workers/worker/broker.ts similarity index 96% rename from modules/angular2/src/web-workers/worker/broker.ts rename to modules/angular2/src/web_workers/worker/broker.ts index 2450a64bd0..bbeb85e988 100644 --- a/modules/angular2/src/web-workers/worker/broker.ts +++ b/modules/angular2/src/web_workers/worker/broker.ts @@ -1,5 +1,5 @@ /// -import {MessageBus} from "angular2/src/web-workers/shared/message_bus"; +import {MessageBus} from "angular2/src/web_workers/shared/message_bus"; import {print, isPresent, DateWrapper, stringify} from "../../facade/lang"; import { Promise, @@ -9,7 +9,7 @@ import { EventEmitter } from "angular2/src/facade/async"; import {ListWrapper, StringMapWrapper, MapWrapper} from "../../facade/collection"; -import {Serializer} from "angular2/src/web-workers/shared/serializer"; +import {Serializer} from "angular2/src/web_workers/shared/serializer"; import {Injectable} from "angular2/di"; import {Type} from "angular2/src/facade/lang"; diff --git a/modules/angular2/src/web-workers/worker/event_deserializer.dart b/modules/angular2/src/web_workers/worker/event_deserializer.dart similarity index 100% rename from modules/angular2/src/web-workers/worker/event_deserializer.dart rename to modules/angular2/src/web_workers/worker/event_deserializer.dart diff --git a/modules/angular2/src/web-workers/worker/event_deserializer.ts b/modules/angular2/src/web_workers/worker/event_deserializer.ts similarity index 100% rename from modules/angular2/src/web-workers/worker/event_deserializer.ts rename to modules/angular2/src/web_workers/worker/event_deserializer.ts diff --git a/modules/angular2/src/web-workers/worker/event_dispatcher.ts b/modules/angular2/src/web_workers/worker/event_dispatcher.ts similarity index 90% rename from modules/angular2/src/web-workers/worker/event_dispatcher.ts rename to modules/angular2/src/web_workers/worker/event_dispatcher.ts index 61d4fcb99b..393a1dffc9 100644 --- a/modules/angular2/src/web-workers/worker/event_dispatcher.ts +++ b/modules/angular2/src/web_workers/worker/event_dispatcher.ts @@ -1,9 +1,9 @@ import {Injectable} from 'angular2/di'; import {Map, MapWrapper} from 'angular2/src/facade/collection'; import {RenderViewRef, RenderEventDispatcher} from 'angular2/src/render/api'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; -import {EVENT_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; -import {MessageBus} from 'angular2/src/web-workers/shared/message_bus'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; +import {EVENT_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; import {EventEmitter, ObservableWrapper} from 'angular2/src/facade/async'; import {deserializeGenericEvent} from './event_deserializer'; import {NgZone} from 'angular2/src/core/zone/ng_zone'; diff --git a/modules/angular2/src/web-workers/worker/renderer.ts b/modules/angular2/src/web_workers/worker/renderer.ts similarity index 97% rename from modules/angular2/src/web-workers/worker/renderer.ts rename to modules/angular2/src/web_workers/worker/renderer.ts index a9ea94f6ac..233c74948a 100644 --- a/modules/angular2/src/web-workers/worker/renderer.ts +++ b/modules/angular2/src/web_workers/worker/renderer.ts @@ -18,19 +18,19 @@ import { MessageBrokerFactory, FnArg, UiArguments -} from "angular2/src/web-workers/worker/broker"; +} from "angular2/src/web_workers/worker/broker"; import {isPresent, print, BaseException} from "angular2/src/facade/lang"; import {Injectable} from "angular2/di"; import { RenderViewWithFragmentsStore, WebWorkerRenderViewRef -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; -import {WebWorkerElementRef} from 'angular2/src/web-workers/shared/api'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; +import {WebWorkerElementRef} from 'angular2/src/web_workers/shared/api'; import { RENDER_COMPILER_CHANNEL, RENDERER_CHANNEL -} from 'angular2/src/web-workers/shared/messaging_api'; -import {WebWorkerEventDispatcher} from 'angular2/src/web-workers/worker/event_dispatcher'; +} from 'angular2/src/web_workers/shared/messaging_api'; +import {WebWorkerEventDispatcher} from 'angular2/src/web_workers/worker/event_dispatcher'; @Injectable() export class WebWorkerCompiler implements RenderCompiler { diff --git a/modules/angular2/src/web-workers/worker/xhr_impl.ts b/modules/angular2/src/web_workers/worker/xhr_impl.ts similarity index 88% rename from modules/angular2/src/web-workers/worker/xhr_impl.ts rename to modules/angular2/src/web_workers/worker/xhr_impl.ts index fc2e72ef8b..5b4a538b36 100644 --- a/modules/angular2/src/web-workers/worker/xhr_impl.ts +++ b/modules/angular2/src/web_workers/worker/xhr_impl.ts @@ -6,8 +6,8 @@ import { UiArguments, MessageBroker, MessageBrokerFactory -} from 'angular2/src/web-workers/worker/broker'; -import {XHR_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; +} from 'angular2/src/web_workers/worker/broker'; +import {XHR_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; /** * Implementation of render/xhr that relays XHR requests to the UI side where they are sent diff --git a/modules/angular2/test/web-workers/shared/message_bus_spec.ts b/modules/angular2/test/web_workers/shared/message_bus_spec.ts similarity index 96% rename from modules/angular2/test/web-workers/shared/message_bus_spec.ts rename to modules/angular2/test/web_workers/shared/message_bus_spec.ts index 34e742af38..ee2595f7c2 100644 --- a/modules/angular2/test/web-workers/shared/message_bus_spec.ts +++ b/modules/angular2/test/web_workers/shared/message_bus_spec.ts @@ -11,7 +11,7 @@ import { proxy } from 'angular2/test_lib'; import {ObservableWrapper} from 'angular2/src/facade/async'; -import {MessageBusInterface} from 'angular2/src/web-workers/shared/message_bus'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; import {createConnectedMessageBus} from './message_bus_util'; export function main() { @@ -19,7 +19,7 @@ export function main() { * Tests the PostMessageBus in TypeScript and the IsolateMessageBus in Dart */ describe("MessageBus", () => { - var bus: MessageBusInterface; + var bus: MessageBus; beforeEach(() => { bus = createConnectedMessageBus(); }); diff --git a/modules/angular2/test/web-workers/shared/message_bus_util.dart b/modules/angular2/test/web_workers/shared/message_bus_util.dart similarity index 68% rename from modules/angular2/test/web-workers/shared/message_bus_util.dart rename to modules/angular2/test/web_workers/shared/message_bus_util.dart index cc525a819e..fda1488bad 100644 --- a/modules/angular2/test/web-workers/shared/message_bus_util.dart +++ b/modules/angular2/test/web_workers/shared/message_bus_util.dart @@ -1,15 +1,15 @@ library angular2.test.web_workers.shared.message_bus_util; import 'dart:isolate'; -import 'package:angular2/src/web-workers/shared/message_bus.dart' - show MessageBusInterface; -import 'package:angular2/src/web-workers/shared/isolate_message_bus.dart'; +import 'package:angular2/src/web_workers/shared/message_bus.dart' + show MessageBus; +import 'package:angular2/src/web_workers/shared/isolate_message_bus.dart'; /* * Returns an IsolateMessageBus thats sink is connected to its own source. * Useful for testing the sink and source. */ -MessageBusInterface createConnectedMessageBus() { +MessageBus createConnectedMessageBus() { var receivePort = new ReceivePort(); var sendPort = receivePort.sendPort; diff --git a/modules/angular2/test/web-workers/shared/message_bus_util.ts b/modules/angular2/test/web_workers/shared/message_bus_util.ts similarity index 77% rename from modules/angular2/test/web-workers/shared/message_bus_util.ts rename to modules/angular2/test/web_workers/shared/message_bus_util.ts index fb4f794add..ec76e7f691 100644 --- a/modules/angular2/test/web-workers/shared/message_bus_util.ts +++ b/modules/angular2/test/web_workers/shared/message_bus_util.ts @@ -2,14 +2,14 @@ import { PostMessageBusSource, PostMessageBusSink, PostMessageBus -} from 'angular2/src/web-workers/shared/post_message_bus'; -import {MessageBusInterface} from 'angular2/src/web-workers/shared/message_bus'; +} from 'angular2/src/web_workers/shared/post_message_bus'; +import {MessageBus} from 'angular2/src/web_workers/shared/message_bus'; /* * Returns a PostMessageBus thats sink is connected to its own source. * Useful for testing the sink and source. */ -export function createConnectedMessageBus(): MessageBusInterface { +export function createConnectedMessageBus(): MessageBus { var mockPostMessage = new MockPostMessage(); var source = new PostMessageBusSource(mockPostMessage); var sink = new PostMessageBusSink(mockPostMessage); diff --git a/modules/angular2/test/web-workers/shared/render_proto_view_ref_store_spec.ts b/modules/angular2/test/web_workers/shared/render_proto_view_ref_store_spec.ts similarity index 93% rename from modules/angular2/test/web-workers/shared/render_proto_view_ref_store_spec.ts rename to modules/angular2/test/web_workers/shared/render_proto_view_ref_store_spec.ts index c4c9278eaf..bead1eb906 100644 --- a/modules/angular2/test/web-workers/shared/render_proto_view_ref_store_spec.ts +++ b/modules/angular2/test/web_workers/shared/render_proto_view_ref_store_spec.ts @@ -1,6 +1,6 @@ import {AsyncTestCompleter, inject, describe, it, expect} from "angular2/test_lib"; import {RenderProtoViewRef} from "angular2/src/render/api"; -import {RenderProtoViewRefStore} from "angular2/src/web-workers/shared/render_proto_view_ref_store"; +import {RenderProtoViewRefStore} from "angular2/src/web_workers/shared/render_proto_view_ref_store"; export function main() { describe("RenderProtoViewRefStore", () => { diff --git a/modules/angular2/test/web-workers/shared/render_view_with_fragments_store_spec.ts b/modules/angular2/test/web_workers/shared/render_view_with_fragments_store_spec.ts similarity index 98% rename from modules/angular2/test/web-workers/shared/render_view_with_fragments_store_spec.ts rename to modules/angular2/test/web_workers/shared/render_view_with_fragments_store_spec.ts index c445c02d35..ee2ec57a32 100644 --- a/modules/angular2/test/web-workers/shared/render_view_with_fragments_store_spec.ts +++ b/modules/angular2/test/web_workers/shared/render_view_with_fragments_store_spec.ts @@ -4,7 +4,7 @@ import { RenderViewWithFragmentsStore, WebWorkerRenderViewRef, WebWorkerRenderFragmentRef -} from "angular2/src/web-workers/shared/render_view_with_fragments_store"; +} from "angular2/src/web_workers/shared/render_view_with_fragments_store"; import {List, ListWrapper} from "angular2/src/facade/collection"; export function main() { diff --git a/modules/angular2/test/web-workers/worker/event_dispatcher_spec.ts b/modules/angular2/test/web_workers/worker/event_dispatcher_spec.ts similarity index 86% rename from modules/angular2/test/web-workers/worker/event_dispatcher_spec.ts rename to modules/angular2/test/web_workers/worker/event_dispatcher_spec.ts index 43471a1078..3a9c53b61a 100644 --- a/modules/angular2/test/web-workers/worker/event_dispatcher_spec.ts +++ b/modules/angular2/test/web_workers/worker/event_dispatcher_spec.ts @@ -11,20 +11,20 @@ import { proxy } from 'angular2/test_lib'; import {IMPLEMENTS} from 'angular2/src/facade/lang'; -import {Serializer} from 'angular2/src/web-workers/shared/serializer'; +import {Serializer} from 'angular2/src/web_workers/shared/serializer'; import {NgZone} from 'angular2/src/core/zone/ng_zone'; -import {ON_WEB_WORKER} from 'angular2/src/web-workers/shared/api'; +import {ON_WEB_WORKER} from 'angular2/src/web_workers/shared/api'; import {bind} from 'angular2/di'; -import {RenderProtoViewRefStore} from 'angular2/src/web-workers/shared/render_proto_view_ref_store'; +import {RenderProtoViewRefStore} from 'angular2/src/web_workers/shared/render_proto_view_ref_store'; import { RenderViewWithFragmentsStore, WebWorkerRenderViewRef -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; import {RenderEventDispatcher, RenderViewRef} from 'angular2/src/render/api'; import {createPairedMessageBuses} from './worker_test_util'; -import {WebWorkerEventDispatcher} from 'angular2/src/web-workers/worker/event_dispatcher'; +import {WebWorkerEventDispatcher} from 'angular2/src/web_workers/worker/event_dispatcher'; import {ObservableWrapper} from 'angular2/src/facade/async'; -import {EVENT_CHANNEL} from 'angular2/src/web-workers/shared/messaging_api'; +import {EVENT_CHANNEL} from 'angular2/src/web_workers/shared/messaging_api'; export function main() { describe("EventDispatcher", () => { diff --git a/modules/angular2/test/web-workers/worker/mock_event_emitter.dart b/modules/angular2/test/web_workers/worker/mock_event_emitter.dart similarity index 100% rename from modules/angular2/test/web-workers/worker/mock_event_emitter.dart rename to modules/angular2/test/web_workers/worker/mock_event_emitter.dart diff --git a/modules/angular2/test/web-workers/worker/mock_event_emitter.ts b/modules/angular2/test/web_workers/worker/mock_event_emitter.ts similarity index 100% rename from modules/angular2/test/web-workers/worker/mock_event_emitter.ts rename to modules/angular2/test/web_workers/worker/mock_event_emitter.ts diff --git a/modules/angular2/test/web-workers/worker/renderer_integration_spec.ts b/modules/angular2/test/web_workers/worker/renderer_integration_spec.ts similarity index 96% rename from modules/angular2/test/web-workers/worker/renderer_integration_spec.ts rename to modules/angular2/test/web_workers/worker/renderer_integration_spec.ts index d3fc22e8c4..5a9774f781 100644 --- a/modules/angular2/test/web-workers/worker/renderer_integration_spec.ts +++ b/modules/angular2/test/web_workers/worker/renderer_integration_spec.ts @@ -11,9 +11,9 @@ import { import {DOM} from 'angular2/src/dom/dom_adapter'; import {DomTestbed, TestRootView, elRef} from '../../render/dom/dom_testbed'; import {bind} from 'angular2/di'; -import {WebWorkerCompiler, WebWorkerRenderer} from "angular2/src/web-workers/worker/renderer"; -import {MessageBrokerFactory, UiArguments, FnArg} from "angular2/src/web-workers/worker/broker"; -import {Serializer} from "angular2/src/web-workers/shared/serializer"; +import {WebWorkerCompiler, WebWorkerRenderer} from "angular2/src/web_workers/worker/renderer"; +import {MessageBrokerFactory, UiArguments, FnArg} from "angular2/src/web_workers/worker/broker"; +import {Serializer} from "angular2/src/web_workers/shared/serializer"; import {isPresent, isBlank, BaseException, Type} from "angular2/src/facade/lang"; import {MapWrapper, ListWrapper} from "angular2/src/facade/collection"; import { @@ -29,16 +29,16 @@ import { import { RenderProtoViewRefStore, WebWorkerRenderProtoViewRef -} from "angular2/src/web-workers/shared/render_proto_view_ref_store"; +} from "angular2/src/web_workers/shared/render_proto_view_ref_store"; import { RenderViewWithFragmentsStore, WebWorkerRenderViewRef -} from 'angular2/src/web-workers/shared/render_view_with_fragments_store'; +} from 'angular2/src/web_workers/shared/render_view_with_fragments_store'; import {resolveInternalDomProtoView, DomProtoView} from 'angular2/src/render/dom/view/proto_view'; import {someComponent} from '../../render/dom/dom_renderer_integration_spec'; -import {WebWorkerMain} from 'angular2/src/web-workers/ui/impl'; -import {MessageBasedRenderCompiler} from 'angular2/src/web-workers/ui/render_compiler'; -import {MessageBasedRenderer} from 'angular2/src/web-workers/ui/renderer'; +import {WebWorkerMain} from 'angular2/src/web_workers/ui/impl'; +import {MessageBasedRenderCompiler} from 'angular2/src/web_workers/ui/render_compiler'; +import {MessageBasedRenderer} from 'angular2/src/web_workers/ui/renderer'; import { createPairedMessageBuses } from './worker_test_util' diff --git a/modules/angular2/test/web-workers/worker/worker_test_util.ts b/modules/angular2/test/web_workers/worker/worker_test_util.ts similarity index 92% rename from modules/angular2/test/web-workers/worker/worker_test_util.ts rename to modules/angular2/test/web_workers/worker/worker_test_util.ts index 31bf6b1026..5fb2777d6f 100644 --- a/modules/angular2/test/web-workers/worker/worker_test_util.ts +++ b/modules/angular2/test/web_workers/worker/worker_test_util.ts @@ -1,10 +1,9 @@ import {StringMap, StringMapWrapper, ListWrapper} from 'angular2/src/facade/collection'; import { - MessageBusInterface, MessageBusSink, MessageBusSource, MessageBus -} from 'angular2/src/web-workers/shared/message_bus'; +} from 'angular2/src/web_workers/shared/message_bus'; import {MockEventEmitter} from './mock_event_emitter'; /** @@ -25,7 +24,7 @@ export function createPairedMessageBuses(): PairedMessageBuses { } export class PairedMessageBuses { - constructor(public ui: MessageBusInterface, public worker: MessageBusInterface) {} + constructor(public ui: MessageBus, public worker: MessageBus) {} } export class MockMessageBusSource implements MessageBusSource { diff --git a/modules/angular2/test/web-workers/worker/xhr_impl_spec.ts b/modules/angular2/test/web_workers/worker/xhr_impl_spec.ts similarity index 93% rename from modules/angular2/test/web-workers/worker/xhr_impl_spec.ts rename to modules/angular2/test/web_workers/worker/xhr_impl_spec.ts index 9be068f35c..56bb28247b 100644 --- a/modules/angular2/test/web-workers/worker/xhr_impl_spec.ts +++ b/modules/angular2/test/web_workers/worker/xhr_impl_spec.ts @@ -15,8 +15,8 @@ import { MessageBroker, UiArguments, MessageBrokerFactory -} from 'angular2/src/web-workers/worker/broker'; -import {WebWorkerXHRImpl} from "angular2/src/web-workers/worker/xhr_impl"; +} from 'angular2/src/web_workers/worker/broker'; +import {WebWorkerXHRImpl} from "angular2/src/web_workers/worker/xhr_impl"; import {PromiseWrapper} from "angular2/src/facade/async"; export function main() { diff --git a/modules/examples/src/message_broker/background_index.dart b/modules/examples/src/message_broker/background_index.dart index 532a720b7d..dce4e581da 100644 --- a/modules/examples/src/message_broker/background_index.dart +++ b/modules/examples/src/message_broker/background_index.dart @@ -1,11 +1,11 @@ library angular2.examples.message_broker.background_index; -import "package:angular2/src/web-workers/worker/broker.dart" +import "package:angular2/src/web_workers/worker/broker.dart" show MessageBroker, UiArguments; -import "package:angular2/src/web-workers/shared/serializer.dart" +import "package:angular2/src/web_workers/shared/serializer.dart" show Serializer; -import "package:angular2/src/web-workers/shared/isolate_message_bus.dart"; -import "package:angular2/src/web-workers/worker/application.dart" +import "package:angular2/src/web_workers/shared/isolate_message_bus.dart"; +import "package:angular2/src/web_workers/worker/application.dart" show WebWorkerMessageBusSink; import "package:angular2/src/facade/async.dart"; import "dart:isolate"; diff --git a/modules/examples/src/message_broker/background_index.ts b/modules/examples/src/message_broker/background_index.ts index 77952f053c..908cb21bce 100644 --- a/modules/examples/src/message_broker/background_index.ts +++ b/modules/examples/src/message_broker/background_index.ts @@ -2,10 +2,10 @@ import { PostMessageBus, PostMessageBusSink, PostMessageBusSource -} from 'angular2/src/web-workers/shared/post_message_bus'; +} from 'angular2/src/web_workers/shared/post_message_bus'; import {ObservableWrapper} from 'angular2/src/facade/async'; -import {MessageBroker, UiArguments} from "angular2/src/web-workers/worker/broker"; -import {Serializer} from "angular2/src/web-workers/shared/serializer"; +import {MessageBroker, UiArguments} from "angular2/src/web_workers/worker/broker"; +import {Serializer} from "angular2/src/web_workers/shared/serializer"; interface PostMessageInterface { (message: any, transferrables?:[ArrayBuffer]): void; diff --git a/modules/examples/src/message_broker/index.dart b/modules/examples/src/message_broker/index.dart index 159f98639b..6ea90733d3 100644 --- a/modules/examples/src/message_broker/index.dart +++ b/modules/examples/src/message_broker/index.dart @@ -1,6 +1,6 @@ library angular2.examples.message_broker.index; -import "package:angular2/src/web-workers/ui/application.dart" +import "package:angular2/src/web_workers/ui/application.dart" show spawnWebWorker; import "package:angular2/src/facade/async.dart"; import "dart:html"; diff --git a/modules/examples/src/message_broker/index.ts b/modules/examples/src/message_broker/index.ts index 042cb3a380..2701e90d5b 100644 --- a/modules/examples/src/message_broker/index.ts +++ b/modules/examples/src/message_broker/index.ts @@ -2,7 +2,7 @@ import { PostMessageBus, PostMessageBusSink, PostMessageBusSource -} from 'angular2/src/web-workers/shared/post_message_bus'; +} from 'angular2/src/web_workers/shared/post_message_bus'; import {ObservableWrapper} from 'angular2/src/facade/async'; var webWorker = new Worker("loader.js"); diff --git a/modules/examples/src/web_workers/images/background_index.dart b/modules/examples/src/web_workers/images/background_index.dart index 95c4bb71bf..b8e3609dd6 100644 --- a/modules/examples/src/web_workers/images/background_index.dart +++ b/modules/examples/src/web_workers/images/background_index.dart @@ -2,7 +2,7 @@ library examples.src.web_workers.images.background_index; import "index_common.dart" show ImageDemo; import "dart:isolate"; -import "package:angular2/src/web-workers/worker/application.dart" +import "package:angular2/src/web_workers/worker/application.dart" show bootstrapWebWorker; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/images/background_index.ts b/modules/examples/src/web_workers/images/background_index.ts index 52322e246f..3069f7c9db 100644 --- a/modules/examples/src/web_workers/images/background_index.ts +++ b/modules/examples/src/web_workers/images/background_index.ts @@ -1,4 +1,4 @@ -import {bootstrapWebWorker} from "angular2/src/web-workers/worker/application"; +import {bootstrapWebWorker} from "angular2/src/web_workers/worker/application"; import {ImageDemo} from "./index_common"; export function main() { diff --git a/modules/examples/src/web_workers/images/index.dart b/modules/examples/src/web_workers/images/index.dart index 930edea0b8..6a3356c08a 100644 --- a/modules/examples/src/web_workers/images/index.dart +++ b/modules/examples/src/web_workers/images/index.dart @@ -1,6 +1,6 @@ library angular2.examples.web_workers.images.index; -import "package:angular2/src/web-workers/ui/application.dart" show bootstrap; +import "package:angular2/src/web_workers/ui/application.dart" show bootstrap; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/images/index.ts b/modules/examples/src/web_workers/images/index.ts index 170f78bba0..d1726a1fed 100644 --- a/modules/examples/src/web_workers/images/index.ts +++ b/modules/examples/src/web_workers/images/index.ts @@ -1,2 +1,2 @@ -import {bootstrap} from "angular2/src/web-workers/ui/application"; +import {bootstrap} from "angular2/src/web_workers/ui/application"; bootstrap("loader.js"); diff --git a/modules/examples/src/web_workers/kitchen_sink/background_index.dart b/modules/examples/src/web_workers/kitchen_sink/background_index.dart index ceb734025c..808b85bd3c 100644 --- a/modules/examples/src/web_workers/kitchen_sink/background_index.dart +++ b/modules/examples/src/web_workers/kitchen_sink/background_index.dart @@ -2,7 +2,7 @@ library examples.src.web_workers.kitchen_sink.background_index; import "index_common.dart" show HelloCmp; import "dart:isolate"; -import "package:angular2/src/web-workers/worker/application.dart" +import "package:angular2/src/web_workers/worker/application.dart" show bootstrapWebWorker; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/kitchen_sink/background_index.ts b/modules/examples/src/web_workers/kitchen_sink/background_index.ts index 4900897832..ccc6352df4 100644 --- a/modules/examples/src/web_workers/kitchen_sink/background_index.ts +++ b/modules/examples/src/web_workers/kitchen_sink/background_index.ts @@ -1,5 +1,5 @@ import {HelloCmp} from "./index_common"; -import {bootstrapWebWorker} from "angular2/src/web-workers/worker/application"; +import {bootstrapWebWorker} from "angular2/src/web_workers/worker/application"; export function main() { bootstrapWebWorker(HelloCmp); diff --git a/modules/examples/src/web_workers/kitchen_sink/index.dart b/modules/examples/src/web_workers/kitchen_sink/index.dart index 5e91566986..3d44ecab0e 100644 --- a/modules/examples/src/web_workers/kitchen_sink/index.dart +++ b/modules/examples/src/web_workers/kitchen_sink/index.dart @@ -1,6 +1,6 @@ library angular2.examples.web_workers.kitchen_sink.index; -import "package:angular2/src/web-workers/ui/application.dart" show bootstrap; +import "package:angular2/src/web_workers/ui/application.dart" show bootstrap; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/kitchen_sink/index.ts b/modules/examples/src/web_workers/kitchen_sink/index.ts index 5b67e20633..d1726a1fed 100644 --- a/modules/examples/src/web_workers/kitchen_sink/index.ts +++ b/modules/examples/src/web_workers/kitchen_sink/index.ts @@ -1,2 +1,2 @@ -import {bootstrap} from "angular2/src/web-workers/ui/application"; -bootstrap("loader.js"); \ No newline at end of file +import {bootstrap} from "angular2/src/web_workers/ui/application"; +bootstrap("loader.js"); diff --git a/modules/examples/src/web_workers/todo/background_index.dart b/modules/examples/src/web_workers/todo/background_index.dart index e323476375..7b8f6614e4 100644 --- a/modules/examples/src/web_workers/todo/background_index.dart +++ b/modules/examples/src/web_workers/todo/background_index.dart @@ -2,7 +2,7 @@ library examples.src.web_workers.todo.background_index; import "index_common.dart" show TodoApp; import "dart:isolate"; -import "package:angular2/src/web-workers/worker/application.dart" +import "package:angular2/src/web_workers/worker/application.dart" show bootstrapWebWorker; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/todo/background_index.ts b/modules/examples/src/web_workers/todo/background_index.ts index fe981babe6..d6807bb930 100644 --- a/modules/examples/src/web_workers/todo/background_index.ts +++ b/modules/examples/src/web_workers/todo/background_index.ts @@ -1,4 +1,4 @@ -import {bootstrapWebWorker} from "angular2/src/web-workers/worker/application"; +import {bootstrapWebWorker} from "angular2/src/web_workers/worker/application"; import {TodoApp} from "./index_common"; export function main() { diff --git a/modules/examples/src/web_workers/todo/index.dart b/modules/examples/src/web_workers/todo/index.dart index 43ff3371ab..5190de91b0 100644 --- a/modules/examples/src/web_workers/todo/index.dart +++ b/modules/examples/src/web_workers/todo/index.dart @@ -1,6 +1,6 @@ library angular2.examples.web_workers.todo.index; -import "package:angular2/src/web-workers/ui/application.dart" show bootstrap; +import "package:angular2/src/web_workers/ui/application.dart" show bootstrap; import "package:angular2/src/reflection/reflection_capabilities.dart"; import "package:angular2/src/reflection/reflection.dart"; diff --git a/modules/examples/src/web_workers/todo/index.ts b/modules/examples/src/web_workers/todo/index.ts index 170f78bba0..d1726a1fed 100644 --- a/modules/examples/src/web_workers/todo/index.ts +++ b/modules/examples/src/web_workers/todo/index.ts @@ -1,2 +1,2 @@ -import {bootstrap} from "angular2/src/web-workers/ui/application"; +import {bootstrap} from "angular2/src/web_workers/ui/application"; bootstrap("loader.js");