chore(transformers): remove reflector parameter from initReflector signature
Remove reflector parameter from initReflector method to simplify ng_deps for reflection initialization. It wasn't used and was added for testability, but wasn't used. This keeps the interface simplier.
This commit is contained in:
parent
a4915ad634
commit
c701664e07
@ -72,8 +72,7 @@ Future<String> linkNgDeps(AssetReader reader, AssetId entryPoint) async {
|
|||||||
importBuf.write('''
|
importBuf.write('''
|
||||||
import '${linkedDepsMap[it.current]}' as i${i};
|
import '${linkedDepsMap[it.current]}' as i${i};
|
||||||
''');
|
''');
|
||||||
declarationBuf
|
declarationBuf.write('i${i}.${SETUP_METHOD_NAME}();');
|
||||||
.write('i${i}.${SETUP_METHOD_NAME}(${REFLECTOR_VAR_NAME});');
|
|
||||||
++i;
|
++i;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -94,6 +94,7 @@ class CreateNgDepsVisitor extends Object with SimpleAstVisitor<Object> {
|
|||||||
if (_wroteBaseLibImport) return;
|
if (_wroteBaseLibImport) return;
|
||||||
_wroteBaseLibImport = true;
|
_wroteBaseLibImport = true;
|
||||||
writer.print('''import '${path.basename(assetId.path)}';''');
|
writer.print('''import '${path.basename(assetId.path)}';''');
|
||||||
|
writer.print("import '$_REFLECTOR_IMPORT' as $_REF_PREFIX;");
|
||||||
}
|
}
|
||||||
|
|
||||||
void _updateUsesNonLangLibs(UriBasedDirective directive) {
|
void _updateUsesNonLangLibs(UriBasedDirective directive) {
|
||||||
@ -118,7 +119,7 @@ class CreateNgDepsVisitor extends Object with SimpleAstVisitor<Object> {
|
|||||||
void _openFunctionWrapper() {
|
void _openFunctionWrapper() {
|
||||||
_maybeWriteImport();
|
_maybeWriteImport();
|
||||||
writer.print('var _visited = false;'
|
writer.print('var _visited = false;'
|
||||||
'void ${SETUP_METHOD_NAME}(${REFLECTOR_VAR_NAME}) {'
|
'void ${SETUP_METHOD_NAME}() {'
|
||||||
'if (_visited) return; _visited = true;');
|
'if (_visited) return; _visited = true;');
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -256,6 +257,9 @@ class CreateNgDepsVisitor extends Object with SimpleAstVisitor<Object> {
|
|||||||
_foundNgInjectable = true;
|
_foundNgInjectable = true;
|
||||||
|
|
||||||
// The receiver for cascaded calls.
|
// The receiver for cascaded calls.
|
||||||
writer.print(REFLECTOR_VAR_NAME);
|
writer.print('$_REF_PREFIX.$REFLECTOR_VAR_NAME');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
const _REF_PREFIX = '_ngRef';
|
||||||
|
const _REFLECTOR_IMPORT = 'package:angular2/src/reflection/reflection.dart';
|
||||||
|
@ -53,8 +53,7 @@ class Codegen {
|
|||||||
|
|
||||||
var count = 0;
|
var count = 0;
|
||||||
return importUris
|
return importUris
|
||||||
.map((_) =>
|
.map((_) => '${prefix}${count++}.${SETUP_METHOD_NAME}();')
|
||||||
'${prefix}${count++}.${SETUP_METHOD_NAME}(${reflectorExpression});')
|
|
||||||
.join('');
|
.join('');
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
export 'foo.dart';
|
export 'foo.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,19 +1,20 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
export 'foo.dart';
|
export 'foo.dart';
|
||||||
import 'foo.ng_deps.dart' as i0;
|
import 'foo.ng_deps.dart' as i0;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
'annotations': const [const Component(selector: '[soup]')]
|
'annotations': const [const Component(selector: '[soup]')]
|
||||||
});
|
});
|
||||||
i0.initReflector(reflector);
|
i0.initReflector();
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library foo.ng_deps.dart;
|
library foo.ng_deps.dart;
|
||||||
|
|
||||||
import 'foo.dart';
|
import 'foo.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(DependencyComponent, {
|
..registerType(DependencyComponent, {
|
||||||
'factory': () => new DependencyComponent(),
|
'factory': () => new DependencyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library web_foo.ng_deps.dart;
|
library web_foo.ng_deps.dart;
|
||||||
|
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/application.dart';
|
import 'package:angular2/src/core/application.dart';
|
||||||
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
import 'bar.ng_deps.dart' as i0;
|
import 'bar.ng_deps.dart' as i0;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
i0.initReflector(reflector);
|
i0.initReflector();
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library foo.ng_deps.dart;
|
library foo.ng_deps.dart;
|
||||||
|
|
||||||
import 'foo.dart';
|
import 'foo.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(DependencyComponent, {
|
..registerType(DependencyComponent, {
|
||||||
'factory': () => new DependencyComponent(),
|
'factory': () => new DependencyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,11 +1,12 @@
|
|||||||
library web_foo.ng_deps.dart;
|
library web_foo.ng_deps.dart;
|
||||||
|
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/application.dart';
|
import 'package:angular2/src/core/application.dart';
|
||||||
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
import 'foo.dart' as dep;
|
import 'foo.dart' as dep;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,15 +1,16 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
import 'foo.dart' as dep;
|
import 'foo.dart' as dep;
|
||||||
import 'foo.ng_deps.dart' as i0;
|
import 'foo.ng_deps.dart' as i0;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
@ -18,5 +19,5 @@ void initReflector(reflector) {
|
|||||||
selector: '[soup]', viewInjector: const [dep.DependencyComponent])
|
selector: '[soup]', viewInjector: const [dep.DependencyComponent])
|
||||||
]
|
]
|
||||||
});
|
});
|
||||||
i0.initReflector(reflector);
|
i0.initReflector();
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library foo.ng_deps.dart;
|
library foo.ng_deps.dart;
|
||||||
|
|
||||||
import 'foo.dart';
|
import 'foo.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(DependencyComponent, {
|
..registerType(DependencyComponent, {
|
||||||
'factory': () => new DependencyComponent(),
|
'factory': () => new DependencyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library web_foo.ng_deps.dart;
|
library web_foo.ng_deps.dart;
|
||||||
|
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/application.dart';
|
import 'package:angular2/src/core/application.dart';
|
||||||
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
import 'bar.ng_deps.dart' as i0;
|
import 'bar.ng_deps.dart' as i0;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
i0.initReflector(reflector);
|
i0.initReflector();
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library foo.ng_deps.dart;
|
library foo.ng_deps.dart;
|
||||||
|
|
||||||
import 'foo.dart';
|
import 'foo.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(DependencyComponent, {
|
..registerType(DependencyComponent, {
|
||||||
'factory': () => new DependencyComponent(),
|
'factory': () => new DependencyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,11 +1,12 @@
|
|||||||
library web_foo.ng_deps.dart;
|
library web_foo.ng_deps.dart;
|
||||||
|
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/application.dart';
|
import 'package:angular2/src/core/application.dart';
|
||||||
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
import 'package:angular2/src/reflection/reflection_capabilities.dart';
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
}
|
}
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.absolute_url_expression_files.ng_deps.dart;
|
library examples.src.hello_world.absolute_url_expression_files.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.package_soup.ng_deps.dart;
|
library dinner.package_soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'package_soup.dart';
|
import 'package_soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:soup/soup.dart';
|
import 'package:soup/soup.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(PackageSoup, {
|
..registerType(PackageSoup, {
|
||||||
'factory': () => new PackageSoup(),
|
'factory': () => new PackageSoup(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.relative_soup.ng_deps.dart;
|
library dinner.relative_soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'relative_soup.dart';
|
import 'relative_soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'annotations/soup.dart';
|
import 'annotations/soup.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(RelativeSoup, {
|
..registerType(RelativeSoup, {
|
||||||
'factory': () => new RelativeSoup(),
|
'factory': () => new RelativeSoup(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.index_common_dart.ng_deps.dart;
|
library examples.src.hello_world.index_common_dart.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.soup.ng_deps.dart;
|
library dinner.soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'soup.dart';
|
import 'soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(ChangingSoupComponent, {
|
..registerType(ChangingSoupComponent, {
|
||||||
'factory': () => new ChangingSoupComponent(),
|
'factory': () => new ChangingSoupComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.soup.ng_deps.dart;
|
library dinner.soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'soup.dart';
|
import 'soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(ChangingSoupComponent, {
|
..registerType(ChangingSoupComponent, {
|
||||||
'factory': () => new ChangingSoupComponent(),
|
'factory': () => new ChangingSoupComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library test.transform.directive_processor.invalid_url_files.hello.ng_deps.dart;
|
library test.transform.directive_processor.invalid_url_files.hello.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.multiple_style_urls_files.ng_deps.dart;
|
library examples.src.hello_world.multiple_style_urls_files.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.multiple_style_urls_not_inlined_files.ng_deps.dart;
|
library examples.src.hello_world.multiple_style_urls_not_inlined_files.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.soup.ng_deps.dart;
|
library dinner.soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'soup.dart';
|
import 'soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(SoupComponent, {
|
..registerType(SoupComponent, {
|
||||||
'factory':
|
'factory':
|
||||||
(String description, salt) => new SoupComponent(description, salt),
|
(String description, salt) => new SoupComponent(description, salt),
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.split_url_expression_files.ng_deps.dart;
|
library examples.src.hello_world.split_url_expression_files.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library static_function_files.hello.ng_deps.dart;
|
library static_function_files.hello.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart';
|
import 'package:angular2/angular2.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerFunction(getMessage, {
|
..registerFunction(getMessage, {
|
||||||
'parameters': const [const [const Inject(Message)]],
|
'parameters': const [const [const Inject(Message)]],
|
||||||
'annotations': const Injectable()
|
'annotations': const Injectable()
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library dinner.soup.ng_deps.dart;
|
library dinner.soup.ng_deps.dart;
|
||||||
|
|
||||||
import 'soup.dart';
|
import 'soup.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(ChangingSoupComponent, {
|
..registerType(ChangingSoupComponent, {
|
||||||
'factory': () => new ChangingSoupComponent(),
|
'factory': () => new ChangingSoupComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library examples.src.hello_world.url_expression_files.ng_deps.dart;
|
library examples.src.hello_world.url_expression_files.ng_deps.dart;
|
||||||
|
|
||||||
import 'hello.dart';
|
import 'hello.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/angular2.dart'
|
import 'package:angular2/angular2.dart'
|
||||||
show bootstrap, Component, Directive, View, NgElement;
|
show bootstrap, Component, Directive, View, NgElement;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(HelloCmp, {
|
..registerType(HelloCmp, {
|
||||||
'factory': () => new HelloCmp(),
|
'factory': () => new HelloCmp(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
import 'foo.dart';
|
import 'foo.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': (MyContext c) => new MyComponent(c),
|
'factory': (MyContext c) => new MyComponent(c),
|
||||||
'parameters': const [const [MyContext]],
|
'parameters': const [const [MyContext]],
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,6 +1,7 @@
|
|||||||
library web_foo.ng_deps.dart;
|
library web_foo.ng_deps.dart;
|
||||||
|
|
||||||
import 'index.dart';
|
import 'index.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/application.dart';
|
import 'package:angular2/src/core/application.dart';
|
||||||
import 'package:angular2/src/reflection/reflection.dart';
|
import 'package:angular2/src/reflection/reflection.dart';
|
||||||
import 'index.ng_deps.dart' as ngStaticInit0;
|
import 'index.ng_deps.dart' as ngStaticInit0;
|
||||||
@ -8,8 +9,8 @@ import 'bar.dart';
|
|||||||
import 'bar.ng_deps.dart' as i0;
|
import 'bar.ng_deps.dart' as i0;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
i0.initReflector(reflector);
|
i0.initReflector();
|
||||||
}
|
}
|
||||||
|
@ -1,13 +1,14 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -4,14 +4,15 @@ import 'package:angular2/src/change_detection/pregen_proto_change_detector.dart'
|
|||||||
as _gen;
|
as _gen;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
import 'package:angular2/src/core/annotations_impl/view.dart';
|
import 'package:angular2/src/core/annotations_impl/view.dart';
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory': () => new MyComponent(),
|
'factory': () => new MyComponent(),
|
||||||
'parameters': const [],
|
'parameters': const [],
|
||||||
|
@ -1,14 +1,15 @@
|
|||||||
library bar.ng_deps.dart;
|
library bar.ng_deps.dart;
|
||||||
|
|
||||||
import 'bar.dart';
|
import 'bar.dart';
|
||||||
|
import 'package:angular2/src/reflection/reflection.dart' as _ngRef;
|
||||||
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
import 'package:angular2/src/core/annotations_impl/annotations.dart';
|
||||||
import 'foo.dart' as prefix;
|
import 'foo.dart' as prefix;
|
||||||
|
|
||||||
var _visited = false;
|
var _visited = false;
|
||||||
void initReflector(reflector) {
|
void initReflector() {
|
||||||
if (_visited) return;
|
if (_visited) return;
|
||||||
_visited = true;
|
_visited = true;
|
||||||
reflector
|
_ngRef.reflector
|
||||||
..registerType(MyComponent, {
|
..registerType(MyComponent, {
|
||||||
'factory':
|
'factory':
|
||||||
(prefix.MyContext c, String inValue) => new MyComponent(c, inValue),
|
(prefix.MyContext c, String inValue) => new MyComponent(c, inValue),
|
||||||
|
@ -16,7 +16,7 @@ import 'package:angular2/src/reflection/reflection.dart';
|
|||||||
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
reflector.reflectionCapabilities = new ReflectionCapabilities();ngStaticInit0.initReflector(reflector);
|
reflector.reflectionCapabilities = new ReflectionCapabilities();ngStaticInit0.initReflector();
|
||||||
bootstrap(MyComponent);
|
bootstrap(MyComponent);
|
||||||
}
|
}
|
||||||
""";
|
""";
|
||||||
|
@ -16,7 +16,7 @@ import 'package:angular2/src/reflection/reflection.dart';
|
|||||||
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
reflector.reflectionCapabilities = new ReflectionCapabilities();ngStaticInit0.initReflector(reflector);
|
reflector.reflectionCapabilities = new ReflectionCapabilities();ngStaticInit0.initReflector();
|
||||||
bootstrap(MyComponent);
|
bootstrap(MyComponent);
|
||||||
}
|
}
|
||||||
""";
|
""";
|
||||||
|
@ -16,7 +16,7 @@ import 'package:angular2/src/reflection/reflection.dart';
|
|||||||
/*import 'package:angular2/src/reflection/reflection_capabilities.dart';*/import 'index.ng_deps.dart' as ngStaticInit0;
|
/*import 'package:angular2/src/reflection/reflection_capabilities.dart';*/import 'index.ng_deps.dart' as ngStaticInit0;
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
/*reflector.reflectionCapabilities = new ReflectionCapabilities();*/ngStaticInit0.initReflector(reflector);
|
/*reflector.reflectionCapabilities = new ReflectionCapabilities();*/ngStaticInit0.initReflector();
|
||||||
bootstrap(MyComponent);
|
bootstrap(MyComponent);
|
||||||
}
|
}
|
||||||
""";
|
""";
|
||||||
|
@ -16,7 +16,7 @@ import 'package:angular2/src/reflection/reflection.dart';
|
|||||||
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
import 'package:angular2/src/reflection/debug_reflection_capabilities.dart';import 'index.ng_deps.dart' as ngStaticInit0;
|
||||||
|
|
||||||
void main() {
|
void main() {
|
||||||
reflector.reflectionCapabilities = new ReflectionCapabilities(verbose: true);ngStaticInit0.initReflector(reflector);
|
reflector.reflectionCapabilities = new ReflectionCapabilities(verbose: true);ngStaticInit0.initReflector();
|
||||||
bootstrap(MyComponent);
|
bootstrap(MyComponent);
|
||||||
}
|
}
|
||||||
""";
|
""";
|
||||||
|
Loading…
x
Reference in New Issue
Block a user