Skip to content

Commit d10df7d

Browse files
Tim Blasimhevery
authored andcommitted
style(dart/transform): Rename .ngDeps.dart => .ng_deps.dart
Update to conform with file naming conventions. Closes angular#975
1 parent 91398c3 commit d10df7d

File tree

26 files changed

+32
-30
lines changed

26 files changed

+32
-30
lines changed

modules/angular2/src/transform/bind_generator/transformer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import 'package:barback/barback.dart';
1010

1111
import 'generator.dart';
1212

13-
/// Transformer responsible for reading .ngDeps.dart files and generating
13+
/// Transformer responsible for reading .ng_deps.dart files and generating
1414
/// setters from the "annotations" information in the generated
1515
/// `registerType` calls.
1616
///

modules/angular2/src/transform/common/names.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,6 @@ library angular2.src.transform.common.names;
22

33
const SETUP_METHOD_NAME = 'setupReflection';
44
const REFLECTOR_VAR_NAME = 'reflector';
5-
const DEPS_EXTENSION = '.ngDeps.dart';
5+
const DEPS_EXTENSION = '.ng_deps.dart';
66
const REGISTER_TYPE_METHOD_NAME = 'registerType';
77
const REGISTER_SETTERS_METHOD_NAME = 'registerSetters';

modules/angular2/src/transform/common/parser.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,8 +37,8 @@ class Parser {
3737
return ngDeps;
3838
}
3939

40-
/// Parses the `.ngDeps.dart` file represented by [id] into an [NgDeps]
41-
/// object. All `.ngDeps.dart` files imported by [id] are then parsed. The
40+
/// Parses the `.ng_deps.dart` file represented by [id] into an [NgDeps]
41+
/// object. All `.ng_deps.dart` files imported by [id] are then parsed. The
4242
/// results are added to [allDeps].
4343
Future<List<NgDeps>> _recurse(AssetId id,
4444
[List<NgDeps> allDeps, Set<AssetId> seen]) async {

modules/angular2/src/transform/directive_linker/transformer.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import 'package:barback/barback.dart';
1010

1111
import 'linker.dart';
1212

13-
/// Transformer responsible for processing .ngDeps.dart files created by
13+
/// Transformer responsible for processing .ng_deps.dart files created by
1414
/// [DirectiveProcessor] and ensuring that the generated calls to
1515
/// `setupReflection` call the necessary `setupReflection` method in all
1616
/// dependencies.

modules/angular2/src/transform/directive_processor/rewriter.dart

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ String createNgDeps(String code, String path, {bool forceGenerate: false}) {
3131
}
3232

3333
/// Visitor responsible for processing [CompilationUnit] and creating an
34-
/// associated .ngDeps.dart file.
34+
/// associated .ng_deps.dart file.
3535
class CreateNgDepsVisitor extends Object
3636
with SimpleAstVisitor<Object>, VisitorMixin {
3737
final PrintWriter writer;

modules/angular2/src/transform/directive_processor/transformer.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,10 +11,10 @@ import 'package:barback/barback.dart';
1111
import 'rewriter.dart';
1212

1313
/// Transformer responsible for processing all .dart assets and creating
14-
/// .ngDeps.dart files which register @Injectable annotated classes with the
14+
/// .ng_deps.dart files which register @Injectable annotated classes with the
1515
/// reflector.
1616
///
17-
/// This will also create .ngDeps.dart files for classes annotated
17+
/// This will also create .ng_deps.dart files for classes annotated
1818
/// with @Component, @Template, @Decorator, etc.
1919
///
2020
/// This transformer is the first phase in a two-phase transform. It should

modules/angular2/src/transform/reflection_remover/transformer.dart

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -14,9 +14,9 @@ import 'remove_reflection_capabilities.dart';
1414
/// The goal of this is to break the app's dependency on dart:mirrors.
1515
///
1616
/// This transformer assumes that [DirectiveProcessor] and [DirectiveLinker]
17-
/// have already been run and that a .ngDeps.dart file has been generated for
17+
/// have already been run and that a .ng_deps.dart file has been generated for
1818
/// [options.entryPoint]. The instantiation of [ReflectionCapabilities] is
19-
/// replaced by calling `setupReflection` in that .ngDeps.dart file.
19+
/// replaced by calling `setupReflection` in that .ng_deps.dart file.
2020
class ReflectionRemover extends Transformer {
2121
final TransformerOptions options;
2222

modules/angular2/test/transform/bind_generator/all_tests.dart

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,9 @@ void allTests() {
1919

2020
test('should generate a setter for a `bind` property in an annotation.',
2121
() async {
22-
var inputPath = 'bind_generator/basic_bind_files/bar.ngDeps.dart';
22+
var inputPath = 'bind_generator/basic_bind_files/bar.ng_deps.dart';
2323
var expected = formatter.format(
24-
readFile('bind_generator/basic_bind_files/expected/bar.ngDeps.dart'));
24+
readFile('bind_generator/basic_bind_files/expected/bar.ng_deps.dart'));
2525

2626
var output = formatter
2727
.format(await createNgSetters(reader, new AssetId('a', inputPath)));
@@ -30,9 +30,10 @@ void allTests() {
3030

3131
test('should generate a single setter when multiple annotations bind to the '
3232
'same property.', () async {
33-
var inputPath = 'bind_generator/duplicate_bind_name_files/soup.ngDeps.dart';
33+
var inputPath =
34+
'bind_generator/duplicate_bind_name_files/soup.ng_deps.dart';
3435
var expected = formatter.format(readFile(
35-
'bind_generator/duplicate_bind_name_files/expected/soup.ngDeps.dart'));
36+
'bind_generator/duplicate_bind_name_files/expected/soup.ng_deps.dart'));
3637

3738
var output = formatter
3839
.format(await createNgSetters(reader, new AssetId('a', inputPath)));

0 commit comments

Comments
 (0)