File tree Expand file tree Collapse file tree 2 files changed +0
-15
lines changed
compiler/src/dotty/tools/io Expand file tree Collapse file tree 2 files changed +0
-15
lines changed Original file line number Diff line number Diff line change @@ -136,12 +136,6 @@ abstract class AbstractFile extends Iterable[AbstractFile] {
136136 /** Does this abstract file represent something which can contain classfiles? */
137137 def isClassContainer : Boolean = isDirectory || (jpath != null && ext.isJarOrZip)
138138
139- /** Create a file on disk, if one does not exist already. */
140- def create (): Unit
141-
142- /** Delete the underlying file or directory (recursively). */
143- def delete (): Unit
144-
145139 /** Is this abstract file a directory? */
146140 def isDirectory : Boolean
147141
Original file line number Diff line number Diff line change @@ -15,7 +15,6 @@ import java.nio.file.{InvalidPathException, Paths}
1515class PlainDirectory (givenPath : Directory ) extends PlainFile (givenPath) {
1616 override val isDirectory : Boolean = true
1717 override def iterator (): Iterator [PlainFile ] = givenPath.list.filter(_.exists).map(new PlainFile (_))
18- override def delete (): Unit = givenPath.deleteRecursively()
1918}
2019
2120/** This class implements an abstract file backed by a File.
@@ -113,14 +112,6 @@ class PlainFile(val givenPath: Path) extends AbstractFile {
113112 null
114113 }
115114
116- /** Does this abstract file denote an existing file? */
117- def create (): Unit = if (! exists) givenPath.createFile()
118-
119- /** Delete the underlying file or directory (recursively). */
120- def delete (): Unit =
121- if (givenPath.isFile) givenPath.delete()
122- else if (givenPath.isDirectory) givenPath.toDirectory.deleteRecursively()
123-
124115 /** Returns a plain file with the given name. It does not
125116 * check that it exists.
126117 */
You can’t perform that action at this time.
0 commit comments