com.codecommit.antixml

Converter

class Converter [A] extends AnyRef

Pimp container for the explicit conversions into Anti-XML types. Out of the box, conversions are provided from scala.xml types. However, this mechanism is very extensible due to the use of a typeclass (XMLConvertable) to represent the actual conversion. Thus, it is possible to add conversions by defining an implicit instance of the typeclass and having it in scope. It is even possible to override the built-in conversions for scala.xml types simply by shadowing the conversions for types like scala.xml.Elem. The built-in conversions are defined in such a way that Scala's implicit resolution will give precedence to almost anything you define, as long as it is somehow in scope.

Source
conversion.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. Hide All
  2. Show all
  1. Converter
  2. AnyRef
  3. Any
Visibility
  1. Public
  2. All

Instance Constructors

  1. new Converter (a: A)

Value Members

  1. def != (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  2. def != (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  3. def ## (): Int

    Attributes
    final
    Definition Classes
    AnyRef → Any
  4. def == (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  5. def == (arg0: Any): Boolean

    Attributes
    final
    Definition Classes
    Any
  6. def asInstanceOf [T0] : T0

    Attributes
    final
    Definition Classes
    Any
  7. def clone (): AnyRef

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  8. def convert : Node

    [use case] Converts a target type A into some result type B (presumably in the Anti-XML API).

    [use case]

    Converts a target type A into some result type B (presumably in the Anti-XML API). Technically, this function is not just restricted to converting into Anti-XML types. However, it would probably minimize confusion if it were exclusively used for this purpose. This generality comes from the fact that the convert function itself doesn't perform any conversion, but merely delegates directly to the apply method on whatever instance of XMLConvertable it happens to be passed.

    Attributes
    abstract
  9. def convert [B] (implicit conversion: XMLConvertable[A, B]): B

    Converts a target type A into some result type B (presumably in the Anti-XML API).

    Converts a target type A into some result type B (presumably in the Anti-XML API). Technically, this function is not just restricted to converting into Anti-XML types. However, it would probably minimize confusion if it were exclusively used for this purpose. This generality comes from the fact that the convert function itself doesn't perform any conversion, but merely delegates directly to the apply method on whatever instance of XMLConvertable it happens to be passed.

    Note: If no conversion is available for the target type, then the compiler will reject this method call. Similarly, if more than one conversion is in scope and neither has implicit precedence over the other, then the compiler will reject this method call as ambiguous. In such cases, it is always possible to pass the conversion explicitly.

    See also

    XMLConvertable

  10. def eq (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  11. def equals (arg0: Any): Boolean

    Definition Classes
    AnyRef → Any
  12. def finalize (): Unit

    Attributes
    protected[lang]
    Definition Classes
    AnyRef
    Annotations
    @throws()
  13. def getClass (): java.lang.Class[_]

    Attributes
    final
    Definition Classes
    AnyRef
  14. def hashCode (): Int

    Definition Classes
    AnyRef → Any
  15. def isInstanceOf [T0] : Boolean

    Attributes
    final
    Definition Classes
    Any
  16. def ne (arg0: AnyRef): Boolean

    Attributes
    final
    Definition Classes
    AnyRef
  17. def notify (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  18. def notifyAll (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
  19. def synchronized [T0] (arg0: ⇒ T0): T0

    Attributes
    final
    Definition Classes
    AnyRef
  20. def toString (): String

    Definition Classes
    AnyRef → Any
  21. def wait (): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  22. def wait (arg0: Long, arg1: Int): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()
  23. def wait (arg0: Long): Unit

    Attributes
    final
    Definition Classes
    AnyRef
    Annotations
    @throws()

Inherited from AnyRef

Inherited from Any