XmlZoom

object XmlZoom

XmlZoom is a powerful system that allow to "zoom" inside a NodeSeq and select one or more elements keeping all step list and return a monadic value to handle possible errors.

==== HOW TO USE ====

XmlZoom is based on three types:

<b>XmlZoom</b> Is the representation of unbind zoom instance. It contains only the list of the actions to run on a NodeSeq.

<b>BindedXmlZoom</b> Is the representation of binded zoom instance. Binded because it contains both ZoomAction and NodeSeq target.

<b>XmlZoomResult</b> Is the result of the XmlZoom, that contains selected NodeSeq and his parents.

Companion
class
trait Sum
trait Mirror
class Object
trait Matchable
class Any

Type members

Classlikes

final case class AtIndex(idx: Int) extends FilterZoomAction
final case class Down(value: String) extends ZoomAction
final case class Filter(p: XmlPredicate) extends FilterZoomAction
sealed trait FilterZoomAction extends ZoomAction
final case class Find(p: XmlPredicate) extends FilterZoomAction
case object Head extends FilterZoomAction
case object Last extends FilterZoomAction
sealed trait ZoomAction
Companion
object
object ZoomAction
Companion
class

Inherited types

type MirroredElemLabels <: Tuple

The names of the product elements

The names of the product elements

Inherited from
Mirror
type MirroredLabel <: String

The name of the type

The name of the type

Inherited from
Mirror

Value members

Concrete methods

def $(document: NodeSeq): BindedXmlZoom

Just a binded alias for root, to use when you are building and XmlZoom that not starts from the root for the document. It's exists just to clarify the code. If your XmlZoom starts for the root of the document please use root

Just a binded alias for root, to use when you are building and XmlZoom that not starts from the root for the document. It's exists just to clarify the code. If your XmlZoom starts for the root of the document please use root

def apply(actions: List[ZoomAction]): XmlZoom

Create a new unbinded XmlZoom with specified actions.

Create a new unbinded XmlZoom with specified actions.

Value Params
actions

actions list for the zooming action

Returns

new instance of unbinded XmlZoom

def root(document: NodeSeq): BindedXmlZoom

Just a binded alias for XmlZoom, to use when you are building and XmlZoom that starts from the root.

Just a binded alias for XmlZoom, to use when you are building and XmlZoom that starts from the root.

Concrete fields

lazy val $: XmlZoom

Just an alias for Root, to use when you are building and XmlZoom that not starts from the root for the document. It's exists just to clarify the code. If your XmlZoom starts for the root of the document please use root

Just an alias for Root, to use when you are building and XmlZoom that not starts from the root for the document. It's exists just to clarify the code. If your XmlZoom starts for the root of the document please use root

lazy val empty: XmlZoom

Empty unbinded XmlZoom instance, without any ZoomAction

Empty unbinded XmlZoom instance, without any ZoomAction

lazy val root: XmlZoom

Just an alias for XmlZoom, to use when you are building and XmlZoom that starts from the root.

Just an alias for XmlZoom, to use when you are building and XmlZoom that starts from the root.