Create And Move Files And Directories
Demonstrate creating simple paths and moving them withing the filesystem and to other filesystems
Not Directory Exception
Since the underlying filesystem could change to safely use the PathSet API it is recommended to handle the NotDirectoryException
import scalax.file.{Path, NotDirectoryException}
import scala.util.control.Exception._
catching (classOf[NotDirectoryException]) opt {
Path ("/tmp/dir").children() map ( _.name)
} match {
case None => println ("Not a direcory")
case Some(names) => println ("files names = "+names)
}