diff options
author | Adriaan Moors <adriaan.moors@typesafe.com> | 2013-06-18 18:57:05 -0700 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@typesafe.com> | 2013-06-20 15:46:25 -0700 |
commit | 1a1d09ce961e318f06ed52dd74b250b11358d050 (patch) | |
tree | 347ce3ea03de5993caded6d2e7573682b88576ad /src/library/scala/sys | |
parent | e2aaf80aea2fc1a2ebc6f9a91163b346cb9882ee (diff) | |
download | scala-1a1d09ce961e318f06ed52dd74b250b11358d050.tar.gz scala-1a1d09ce961e318f06ed52dd74b250b11358d050.tar.bz2 scala-1a1d09ce961e318f06ed52dd74b250b11358d050.zip |
Remove dependency on xml in sys.process.
Added deprecated conversions in xml.Elem to preserve source compatibility.
Diffstat (limited to 'src/library/scala/sys')
-rw-r--r-- | src/library/scala/sys/process/Process.scala | 17 | ||||
-rw-r--r-- | src/library/scala/sys/process/package.scala | 5 |
2 files changed, 1 insertions, 21 deletions
diff --git a/src/library/scala/sys/process/Process.scala b/src/library/scala/sys/process/Process.scala index 402183a1f0..dcd06c89e9 100644 --- a/src/library/scala/sys/process/Process.scala +++ b/src/library/scala/sys/process/Process.scala @@ -127,15 +127,6 @@ trait ProcessCreation { */ def apply(url: URL): URLBuilder = new URLImpl(url) - /** Creates a [[scala.sys.process.ProcessBuilder]] from a Scala XML Element. - * This can be used as a way to template strings. - * - * @example {{{ - * apply(<x> {dxPath.absolutePath} --dex --output={classesDexPath.absolutePath} {classesMinJarPath.absolutePath}</x>) - * }}} - */ - def apply(command: scala.xml.Elem): ProcessBuilder = apply(command.text.trim) - /** Creates a [[scala.sys.process.ProcessBuilder]] from a `Boolean`. This can be * to force an exit value. */ @@ -220,14 +211,6 @@ trait ProcessImplicits { */ implicit def urlToProcess(url: URL): URLBuilder = apply(url) - /** Implicitly convert a [[scala.xml.Elem]] into a - * [[scala.sys.process.ProcessBuilder]]. This is done by obtaining the text - * elements of the element, trimming spaces, and then converting the result - * from string to a process. Importantly, tags are completely ignored, so - * they cannot be used to separate parameters. - */ - implicit def xmlToProcess(command: scala.xml.Elem): ProcessBuilder = apply(command) - /** Implicitly convert a `String` into a [[scala.sys.process.ProcessBuilder]]. */ implicit def stringToProcess(command: String): ProcessBuilder = apply(command) diff --git a/src/library/scala/sys/process/package.scala b/src/library/scala/sys/process/package.scala index 902543665f..d68cd004f8 100644 --- a/src/library/scala/sys/process/package.scala +++ b/src/library/scala/sys/process/package.scala @@ -80,10 +80,7 @@ package scala.sys { * spaces -- no escaping of spaces is possible -- or out of a * [[scala.collection.Seq]], where the first element represents the command * name, and the remaining elements are arguments to it. In this latter case, - * arguments may contain spaces. One can also implicitly convert - * [[scala.xml.Elem]] and `java.lang.ProcessBuilder` into a `ProcessBuilder`. - * In the introductory example, the strings were converted into - * `ProcessBuilder` implicitly. + * arguments may contain spaces. * * To further control what how the process will be run, such as specifying * the directory in which it will be run, see the factories on |