Closed
Description
object Test extends App {
def getNs(v: String) = s"http://schemas.sample.com/sample/$v"
def getNs2(v: String, dummy: String) = s"http://schemas.sample.com/sample/$v"
val x0 = <sample><id>1</id></sample>
val x1 = <sample xmlns:foo="bar"><id xmlns="baz">1</id></sample>
val x2 = <sample xmlns={getNs("v1")}><id>1</id></sample>
val x3 = <sample xmlns={getNs2("v1", "dummy")}><id>1</id></sample>
println(List(x0, x1, x2, x3) mkString "\n")
}
x2
is assigned the namspace "v1".