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

Side by Side Diff: pkg/analyzer_experimental/lib/src/generated/java_io.dart

Issue 19297002: Try to fix Windows bots. Use absolute path instead of canonical. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « editor/util/plugins/com.google.dart.java2dart/resources/java_io.dart ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 library java.io; 1 library java.io;
2 2
3 import "dart:io"; 3 import "dart:io";
4 import 'package:path/path.dart' as pathos; 4 import 'package:path/path.dart' as pathos;
5 5
6 class JavaSystemIO { 6 class JavaSystemIO {
7 static Map<String, String> _properties = new Map(); 7 static Map<String, String> _properties = new Map();
8 static String getProperty(String name) { 8 static String getProperty(String name) {
9 { 9 {
10 String value = _properties[name]; 10 String value = _properties[name];
(...skipping 70 matching lines...) Expand 10 before | Expand all | Expand 10 after
81 // "." or "/" or "C:\" 81 // "." or "/" or "C:\"
82 if (result.length < 4) return null; 82 if (result.length < 4) return null;
83 return result; 83 return result;
84 } 84 }
85 JavaFile getParentFile() { 85 JavaFile getParentFile() {
86 var parent = getParent(); 86 var parent = getParent();
87 if (parent == null) return null; 87 if (parent == null) return null;
88 return new JavaFile(parent); 88 return new JavaFile(parent);
89 } 89 }
90 String getAbsolutePath() => pathos.absolute(_path); 90 String getAbsolutePath() => pathos.absolute(_path);
91 String getCanonicalPath() => _newFile().fullPathSync(); 91 // TODO(scheglov) it seems that this method is broken on Windows
92 // String getCanonicalPath() => _newFile().fullPathSync();
93 String getCanonicalPath() => getAbsolutePath();
92 JavaFile getAbsoluteFile() => new JavaFile(getAbsolutePath()); 94 JavaFile getAbsoluteFile() => new JavaFile(getAbsolutePath());
93 JavaFile getCanonicalFile() => new JavaFile(getCanonicalPath()); 95 JavaFile getCanonicalFile() => new JavaFile(getCanonicalPath());
94 bool exists() { 96 bool exists() {
95 if (_newFile().existsSync()) { 97 if (_newFile().existsSync()) {
96 return true; 98 return true;
97 } 99 }
98 if (_newDirectory().existsSync()) { 100 if (_newDirectory().existsSync()) {
99 return true; 101 return true;
100 } 102 }
101 return false; 103 return false;
(...skipping 12 matching lines...) Expand all
114 List<JavaFile> files = []; 116 List<JavaFile> files = [];
115 List<FileSystemEntity> entities = _newDirectory().listSync(); 117 List<FileSystemEntity> entities = _newDirectory().listSync();
116 for (FileSystemEntity entity in entities) { 118 for (FileSystemEntity entity in entities) {
117 files.add(new JavaFile(entity.path)); 119 files.add(new JavaFile(entity.path));
118 } 120 }
119 return files; 121 return files;
120 } 122 }
121 File _newFile() => new File(_path); 123 File _newFile() => new File(_path);
122 Directory _newDirectory() => new Directory(_path); 124 Directory _newDirectory() => new Directory(_path);
123 } 125 }
OLDNEW
« no previous file with comments | « editor/util/plugins/com.google.dart.java2dart/resources/java_io.dart ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698