diff options
author | michelou <michelou@epfl.ch> | 2005-09-15 14:11:58 +0000 |
---|---|---|
committer | michelou <michelou@epfl.ch> | 2005-09-15 14:11:58 +0000 |
commit | 90942ba0614a623789b2829612d99af5a8af6b4c (patch) | |
tree | 9bbec3028ff4f1023c288af51f20a767c1c4251f | |
parent | 2f8d5228ca7edecc4bfdbd5342fe1ec64b9396c0 (diff) | |
download | scala-90942ba0614a623789b2829612d99af5a8af6b4c.tar.gz scala-90942ba0614a623789b2829612d99af5a8af6b4c.tar.bz2 scala-90942ba0614a623789b2829612d99af5a8af6b4c.zip |
- changed formatting.
-rw-r--r-- | sources/scala/xml/Elem.scala | 19 |
1 files changed, 12 insertions, 7 deletions
diff --git a/sources/scala/xml/Elem.scala b/sources/scala/xml/Elem.scala index d4dc0c8ab9..bb799884bb 100644 --- a/sources/scala/xml/Elem.scala +++ b/sources/scala/xml/Elem.scala @@ -1,12 +1,13 @@ /* __ *\ ** ________ ___ / / ___ Scala API ** -** / __/ __// _ | / / / _ | (c) 2002-2004, LAMP/EPFL ** +** / __/ __// _ | / / / _ | (c) 2002-2005, LAMP/EPFL ** ** __\ \/ /__/ __ |/ /__/ __ | ** ** /____/\___/_/ |_/____/_/ | | ** ** |/ ** -** $Id$ \* */ +// $Id$ + package scala.xml; import scala.collection.mutable.ArrayBuffer; @@ -21,12 +22,16 @@ import scala.collection.mutable.ArrayBuffer; * @author Burak Emir */ // "val" is redundant for non-overriding arguments -case class Elem(override val prefix:String, val label: String, override val attributes: MetaData, override val scope: NamespaceBinding, val child: Node*) extends Node { +case class Elem(override val prefix: String, + val label: String, + override val attributes: MetaData, + override val scope: NamespaceBinding, + val child: Node*) extends Node { - if(prefix != null && 0 == prefix.length()) + if (prefix != null && 0 == prefix.length()) error("prefix of zero length, use null instead"); - if(null == scope) + if (null == scope) error("scope is null"); //@todo: copy the children, @@ -39,7 +44,7 @@ case class Elem(override val prefix:String, val label: String, override val attr //final val labelIntern = label$$.intern(); //final def label = labelIntern; - final override def typeTag$:Int = 0; + final override def typeTag$: Int = 0; /** Return a new element with updated attributes * @@ -51,6 +56,6 @@ case class Elem(override val prefix:String, val label: String, override val attr label, attrs.append(attributes), scope, - child:_*) ; + child:_*); } |