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

Side by Side Diff: pkg/analysis_server/lib/src/edit/edit_domain.dart

Issue 1388783003: Spec change: include covering expressions into Extract Local protocol. (Closed) Base URL: git@github.com:dart-lang/sdk.git@master
Patch Set: Created 5 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2014, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 library edit.domain; 5 library edit.domain;
6 6
7 import 'dart:async'; 7 import 'dart:async';
8 8
9 import 'package:analysis_server/edit/assist/assist_core.dart'; 9 import 'package:analysis_server/edit/assist/assist_core.dart';
10 import 'package:analysis_server/edit/fix/fix_core.dart'; 10 import 'package:analysis_server/edit/fix/fix_core.dart';
(...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after
550 if (element is ExecutableElement) { 550 if (element is ExecutableElement) {
551 refactoring = 551 refactoring =
552 new ConvertMethodToGetterRefactoring(searchEngine, element); 552 new ConvertMethodToGetterRefactoring(searchEngine, element);
553 } 553 }
554 } 554 }
555 } 555 }
556 if (kind == RefactoringKind.EXTRACT_LOCAL_VARIABLE) { 556 if (kind == RefactoringKind.EXTRACT_LOCAL_VARIABLE) {
557 List<CompilationUnit> units = server.getResolvedCompilationUnits(file); 557 List<CompilationUnit> units = server.getResolvedCompilationUnits(file);
558 if (units.isNotEmpty) { 558 if (units.isNotEmpty) {
559 refactoring = new ExtractLocalRefactoring(units[0], offset, length); 559 refactoring = new ExtractLocalRefactoring(units[0], offset, length);
560 feedback = new ExtractLocalVariableFeedback([], [], []); 560 feedback = new ExtractLocalVariableFeedback(
561 <int>[], <int>[], <String>[], <int>[], <int>[]);
561 } 562 }
562 } 563 }
563 if (kind == RefactoringKind.EXTRACT_METHOD) { 564 if (kind == RefactoringKind.EXTRACT_METHOD) {
564 List<CompilationUnit> units = server.getResolvedCompilationUnits(file); 565 List<CompilationUnit> units = server.getResolvedCompilationUnits(file);
565 if (units.isNotEmpty) { 566 if (units.isNotEmpty) {
566 refactoring = new ExtractMethodRefactoring( 567 refactoring = new ExtractMethodRefactoring(
567 searchEngine, units[0], offset, length); 568 searchEngine, units[0], offset, length);
568 feedback = new ExtractMethodFeedback( 569 feedback = new ExtractMethodFeedback(offset, length, '', <String>[],
569 offset, length, '', [], false, [], [], []); 570 false, <RefactoringMethodParameter>[], <int>[], <int>[]);
570 } 571 }
571 } 572 }
572 if (kind == RefactoringKind.INLINE_LOCAL_VARIABLE) { 573 if (kind == RefactoringKind.INLINE_LOCAL_VARIABLE) {
573 List<CompilationUnit> units = server.getResolvedCompilationUnits(file); 574 List<CompilationUnit> units = server.getResolvedCompilationUnits(file);
574 if (units.isNotEmpty) { 575 if (units.isNotEmpty) {
575 refactoring = 576 refactoring =
576 new InlineLocalRefactoring(searchEngine, units[0], offset); 577 new InlineLocalRefactoring(searchEngine, units[0], offset);
577 } 578 }
578 } 579 }
579 if (kind == RefactoringKind.INLINE_METHOD) { 580 if (kind == RefactoringKind.INLINE_METHOD) {
(...skipping 149 matching lines...) Expand 10 before | Expand all | Expand 10 after
729 } 730 }
730 return new RefactoringStatus(); 731 return new RefactoringStatus();
731 } 732 }
732 } 733 }
733 734
734 /** 735 /**
735 * [_RefactoringManager] throws instances of this class internally to stop 736 * [_RefactoringManager] throws instances of this class internally to stop
736 * processing in a manager that was reset. 737 * processing in a manager that was reset.
737 */ 738 */
738 class _ResetError {} 739 class _ResetError {}
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698