Package

scales.xml

xpath

Permalink

package xpath

Visibility
  1. Public
  2. All

Type Members

  1. class Ancestors extends Iterable[xml.XmlPath]

    Permalink

    Returns the ancestors / parents of the path

  2. trait AttributeAxis extends Axis

    Permalink

    The * and @ must be swapped otherwise its an annotation

  3. case class AttributePath(attribute: Attribute, parent: xml.XmlPath) extends Product with Serializable

    Permalink

    Simple container for keeping relationship between the parent and attribute

  4. case class AttributePathComparisoms(path: AttributePath) extends Product with Serializable

    Permalink
  5. case class AttributePaths[PT <: Iterable[xml.XmlPath]](attributes: Iterable[AttributePath], path: XPathInfo, cbf: CanBuildFrom[PT, xml.XmlPath, PT])(implicit helper: BuilderHelper[xml.XmlPath, PT]) extends Product with Serializable

    Permalink

    Attributes that have been selected

  6. trait Axis extends AnyRef

    Permalink

    Base trait for XPath Axis, also provides common functionality

  7. class DIF extends AnyRef

    Permalink

    Dummy implicit filler for easing interface issues

  8. class DirectXPath[PT <: Iterable[xml.XmlPath]] extends XPath[PT]

    Permalink

    Pos and filter for a direct access does not flatmap.

    Pos and filter for a direct access does not flatmap. The next / breaks the chain

  9. trait DocumentSplitters extends Axis

    Permalink

    Following and preceding split the document in two

  10. trait ElementStep extends Axis

    Permalink
  11. class Following extends Iterable[xml.XmlPath]

    Permalink

    Iterates over paths using the document order as per the following_:: axis.

  12. trait FunctionImplicits extends TextImplicits with NamesImplicits

    Permalink
  13. trait Functions extends NameFunctions with TextFunctions

    Permalink

    Collects all type class based xpath functions, exposed via Functions in package

    Collects all type class based xpath functions, exposed via Functions in package

    Also adds aliases for the common functions

  14. trait NameFunctions extends AnyRef

    Permalink

    Functions providing access to QNames

  15. trait Names[T] extends AnyRef

    Permalink

    Type class representing Xml objects which provide qnames.

    Type class representing Xml objects which provide qnames. Most of the functions allow for implicit scope to ease use in xpaths.

  16. trait NamesImplicits extends AnyRef

    Permalink

    Name type classes

  17. trait OtherNodeTypes extends Axis

    Permalink

    Little depature from standard, rather than duplicate all of the \ and \\ nodes, just a simple \\*() comment() will do

    Little depature from standard, rather than duplicate all of the \ and \\ nodes, just a simple \\*() comment() will do

    NOTE these have a large performance hit as the must sort and filter the results in order to get doc order. Better to use specific nodes avoiding \\ etc, then use the s for simple functions, sutext etc for simple useful. Additionally using the non simple versions incurs the cost of adding adjacent text node processing as per standard datamodel (all adjacent text nodes are joined and any resulting nodes that are "the zero-length string" are removed).

    TODO xpath adjacent text node handling

  18. class Preceding extends Iterable[xml.XmlPath]

    Permalink

    Iterates over paths using reverse document order and, as per the preceding_:: axis, skips all ancestors.

  19. trait SiblingsAxis extends Axis

    Permalink

    Unlike XPath spec no reverse axis are directly provided by the dsl

  20. trait TextFunctions extends AnyRef

    Permalink
  21. trait TextImplicits extends AnyRef

    Permalink
  22. trait TextValue[T] extends AnyRef

    Permalink

    Type class for text values

  23. class XPath[PT <: Iterable[xml.XmlPath]] extends ElementStep with OtherNodeTypes with AttributeAxis with SiblingsAxis with DocumentSplitters

    Permalink

    In contrast to the specs reverse axis are not supported.

    In contrast to the specs reverse axis are not supported. This puts an extra effort on the user for translating, but I don't agree with the design anyway. It adds both ambiguity for an embedded dsl:

    //a:ShouldRedeclare/../text()[5]/preceding-sibling::text()[1]

    is in reverse order (above is previousSibling in Path), whereas

    (//a:ShouldRedeclare/../text()[5]/preceding-sibling::text())[1]

    is in doc order (the first text child of the parent). Such an arbritary decision does nothing but irritate. A simpler design as found in this implementation is that the user can simply use full scala data functions to reverse as needed.

    (Temptation is to provide the base type as SeqLike instead of Iterable as it should be in a sequence with a defined order, also then providing .reverse and friends)

  24. case class XPathInfo(nodes: Iterable[Iterable[xml.XmlPath]], mustBeSorted: Boolean = false, filterDuplicates: Boolean = false, initialNode: Boolean = false, eager: Boolean = false, direct: Boolean = false) extends Product with Serializable

    Permalink

    XPaths need sorting upon unions etc, and duplicate filtering on \^ parents

  25. case class XmlPathComparisoms(path: xml.XmlPath) extends Product with Serializable

    Permalink
  26. trait XmlPathImplicits extends AnyRef

    Permalink
  27. trait XmlPaths extends AnyRef

    Permalink

Value Members

  1. object AQNameNames extends Names[xml.AttributeQName]

    Permalink
  2. object AttributeNames extends Names[Attribute]

    Permalink
  3. object AttributePathNames extends Names[AttributePath]

    Permalink
  4. object AttributePathText extends TextValue[AttributePath]

    Permalink
  5. object AttributePathsNames extends Names[AttributePaths[_]]

    Permalink
  6. object AttributePathsText extends TextValue[AttributePaths[_]]

    Permalink
  7. object AttributeText extends TextValue[Attribute]

    Permalink
  8. object Axis

    Permalink
  9. object DIF

    Permalink
  10. object DslNames extends Names[DslBuilder]

    Permalink
  11. object DslText extends TextValue[DslBuilder]

    Permalink
  12. object ElemNames extends Names[Elem]

    Permalink
  13. object EmptyQName

    Permalink

    Represents an empty qname for those cases that should return empty string

    Represents an empty qname for those cases that should return empty string

    Attributes
    protected[scales.xml]
  14. object ItemOrElemText extends TextValue[xml.ItemOrElem]

    Permalink
  15. object PositionalEquals

    Permalink
  16. object QNameNames extends Names[QName]

    Permalink
  17. object XPathNames extends Names[XPath[_]]

    Permalink
  18. object XPathText extends TextValue[XPath[_]]

    Permalink
  19. object XmlItemText extends TextValue[XmlItem]

    Permalink
  20. object XmlPathNames extends Names[xml.XmlPath]

    Permalink
  21. object XmlPathText extends TextValue[xml.XmlPath]

    Permalink
  22. object XmlTreeNames extends Names[xml.XmlTree]

    Permalink
  23. object XmlTreeText extends TextValue[xml.XmlTree]

    Permalink

Ungrouped