in scala/xml/transform
trait BasicTransformer

trait BasicTransformer()
extends (Node) => Node
with ScalaObject
Implementing classes or objects:
class RewriteRule()
class RuleTransformer(rules: RewriteRule*)

a trait for XML transformations

Method Summary
  def apply(n: Node): Node
protected def buffer(pos: Int, ns: Seq[Node]): NodeBuffer
     returns a new node buffer with the first pos elements from ns
protected def freeze(nb: NodeBuffer): Seq[Node]
     turns a nodebuffer into a sequence, so hashcode works
protected def single(ns: Seq[Node]): Boolean
  def transform(it: Iterator[Node], nb: NodeBuffer): Seq[Node]
     call transform(Node) for each node in ns, append results to NodeBuffer
  def transform(ns: Seq[Node]): Seq[Node]
     call transform(Node) to each node in ns, yield ns if nothing changes, otherwise a new sequence of concatenated results
  def transform(n: Node): Seq[Node]
protected def unchanged(n: Node, ns: Seq[Node]): Boolean

Methods inherited from java/lang/Object-class
clone, eq, equals, finalize, getClass, hashCode, ne, notify, notifyAll, synchronized, toString, wait, wait, wait

Methods inherited from scala/Any-class
!=, ==, asInstanceOf, isInstanceOf, match

Methods inherited from scala/ScalaObject-class
getScalaType

Class Summary
protected case class NeedsCopy(result: Seq[Node])

Method Detail

buffer

  protected def buffer(pos: Int, ns: Seq[Node]): NodeBuffer
returns a new node buffer with the first pos elements from ns

freeze

  protected def freeze(nb: NodeBuffer): Seq[Node]
turns a nodebuffer into a sequence, so hashcode works

single

  protected def single(ns: Seq[Node]): Boolean

unchanged

  protected def unchanged(n: Node, ns: Seq[Node]): Boolean

transform

  def transform(it: Iterator[Node], nb: NodeBuffer): Seq[Node]
call transform(Node) for each node in ns, append results to NodeBuffer

transform

  def transform(ns: Seq[Node]): Seq[Node]
call transform(Node) to each node in ns, yield ns if nothing changes, otherwise a new sequence of concatenated results

transform

  def transform(n: Node): Seq[Node]

apply

  def apply(n: Node): Node