MetaData

abstract class MetaData extends AbstractIterable[MetaData] with Iterable[MetaData] with Equality with Serializable

This class represents an attribute and at the same time a linked list of attributes. Every instance of this class is either

  • an instance of UnprefixedAttribute key,value or
  • an instance of PrefixedAttribute namespace_prefix,key,value or
  • `Null, the empty attribute list.

Namespace URIs are obtained by using the namespace scope of the element owning this attribute (see getNamespace).

Companion:
object

Value members

Abstract methods

def apply(key: String): Seq[Node]

Gets value of unqualified (unprefixed) attribute with given key, null if not found

Gets value of unqualified (unprefixed) attribute with given key, null if not found

Returns:

value as Seq[Node] if key is found, null otherwise

def apply(namespace_uri: String, scp: NamespaceBinding, k: String): Seq[Node]

Gets value of prefixed attribute with given key and namespace, null if not found

Gets value of prefixed attribute with given key and namespace, null if not found

Value parameters:
k

to be looked for

namespace_uri

namespace uri of key

scp

a namespace scp (usually of the element owning this attribute list)

Returns:

value as Seq[Node] if key is found, null otherwise

def copy(next: MetaData): MetaData

returns a copy of this MetaData item with next field set to argument.

returns a copy of this MetaData item with next field set to argument.

def getNamespace(owner: Node): String

if owner is the element of this metadata item, returns namespace

if owner is the element of this metadata item, returns namespace

def key: String

returns key of this MetaData item

returns key of this MetaData item

returns Null or the next MetaData item

returns Null or the next MetaData item

def remove(namespace: String, scope: NamespaceBinding, key: String): MetaData
def value: Seq[Node]

returns value of this MetaData item

returns value of this MetaData item

Concrete methods

def append(updates: MetaData, scope: NamespaceBinding): MetaData

Updates this MetaData with the MetaData given as argument. All attributes that occur in updates are part of the resulting MetaData. If an attribute occurs in both this instance and updates, only the one in updates is part of the result (avoiding duplicates). For prefixed attributes, namespaces are resolved using the given scope, which defaults to TopScope.

Updates this MetaData with the MetaData given as argument. All attributes that occur in updates are part of the resulting MetaData. If an attribute occurs in both this instance and updates, only the one in updates is part of the result (avoiding duplicates). For prefixed attributes, namespaces are resolved using the given scope, which defaults to TopScope.

Value parameters:
updates

MetaData with new and updated attributes

Returns:

a new MetaData instance that contains old, new and updated attributes

final def apply(namespace_uri: String, owner: Node, key: String): Seq[Node]

convenience method, same as apply(namespace, owner.scope, key).

convenience method, same as apply(namespace, owner.scope, key).

Value parameters:
key

the attribute key

namespace_uri

namespace uri of key

owner

the element owning this attribute list

Returns a Map containing the attributes stored as key/value pairs.

Returns a Map containing the attributes stored as key/value pairs.

override def canEqual(other: Any): Boolean
Definition Classes
override def filter(f: MetaData => Boolean): MetaData

filters this sequence of meta data

filters this sequence of meta data

Definition Classes
final def get(key: String): Option[Seq[Node]]

Gets value of unqualified (unprefixed) attribute with given key, None if not found

Gets value of unqualified (unprefixed) attribute with given key, None if not found

Returns:

value in Some(Seq[Node]) if key is found, None otherwise

final def get(uri: String, owner: Node, key: String): Option[Seq[Node]]

same as get(uri, owner.scope, key)

same as get(uri, owner.scope, key)

final def get(uri: String, scope: NamespaceBinding, key: String): Option[Seq[Node]]

gets value of qualified (prefixed) attribute with given key.

gets value of qualified (prefixed) attribute with given key.

Value parameters:
key

to be looked fore

scope

a namespace scp (usually of the element owning this attribute list)

uri

namespace of key

Returns:

value as Some[Seq[Node]] if key is found, None otherwise

def length: Int
def length(i: Int): Int

Returns a String containing "prefix:key" if the first key is prefixed, and "key" otherwise.

Returns a String containing "prefix:key" if the first key is prefixed, and "key" otherwise.

final def remove(namespace: String, owner: Node, key: String): MetaData
override def strict_==(other: Equality): Boolean
Definition Classes
override def toString(): String
Definition Classes
Iterable -> Any

Inherited methods

final def ++[B >: MetaData](suffix: IterableOnce[B]): Iterable[B]
Inherited from:
IterableOps
Inherited from:
IterableOnceOps
Inherited from:
IterableOps
def concat[B >: MetaData](suffix: IterableOnce[B]): Iterable[B]
Inherited from:
IterableOps
def copyToArray[B >: MetaData](xs: Array[B], start: Int, len: Int): Int
Inherited from:
IterableOnceOps
@deprecatedOverriding(message = "This should always forward to the 3-arg version of this method", since = "2.13.4")
def copyToArray[B >: MetaData](xs: Array[B], start: Int): Int
Inherited from:
IterableOnceOps
@deprecatedOverriding(message = "This should always forward to the 3-arg version of this method", since = "2.13.4")
def copyToArray[B >: MetaData](xs: Array[B]): Int
Inherited from:
IterableOnceOps
def corresponds[B](that: IterableOnce[B])(p: (MetaData, B) => Boolean): Boolean
Inherited from:
IterableOnceOps
Inherited from:
IterableOnceOps
Inherited from:
IterableOps
Inherited from:
IterableOps
override def empty: Iterable[MetaData]
override def equals(other: Any): Boolean
Definition Classes
Equality -> Equals -> Any
Inherited from:
Equality
Inherited from:
IterableOnceOps
Inherited from:
IterableOps
Inherited from:
IterableOnceOps
Inherited from:
IterableOps
def flatten[B](implicit asIterable: MetaData => IterableOnce[B]): Iterable[B]
Inherited from:
IterableOps
def fold[A1 >: MetaData](z: A1)(op: (A1, A1) => A1): A1
Inherited from:
IterableOnceOps
def foldLeft[B](z: B)(op: (B, MetaData) => B): B
Inherited from:
IterableOnceOps
def foldRight[B](z: B)(op: (MetaData, B) => B): B
Inherited from:
IterableOnceOps
Inherited from:
IterableOnceOps
def foreach[U](f: MetaData => U): Unit
Inherited from:
IterableOnceOps
def groupBy[K](f: MetaData => K): Map[K, Iterable[MetaData]]
Inherited from:
IterableOps
def groupMap[K, B](key: MetaData => K)(f: MetaData => B): Map[K, Iterable[B]]
Inherited from:
IterableOps
def groupMapReduce[K, B](key: MetaData => K)(f: MetaData => B)(reduce: (B, B) => B): Map[K, B]
Inherited from:
IterableOps
Inherited from:
IterableOps
override def hashCode(): Int

It's be nice to make these final, but there are probably people out there subclassing the XML types, especially when it comes to equals. However WE at least can pretend they are final since clearly individual classes cannot be trusted to maintain a semblance of order.

It's be nice to make these final, but there are probably people out there subclassing the XML types, especially when it comes to equals. However WE at least can pretend they are final since clearly individual classes cannot be trusted to maintain a semblance of order.

Definition Classes
Equality -> Any
Inherited from:
Equality
Inherited from:
IterableOps
Inherited from:
IterableOps
Inherited from:
IterableOnceOps
Definition Classes
Inherited from:
IterableOps
Inherited from:
IterableOnce
Inherited from:
IterableOps
Inherited from:
Iterable
def map[B](f: MetaData => B): Iterable[B]
Inherited from:
IterableOps
def max[B >: MetaData](implicit ord: Ordering[B]): MetaData
Inherited from:
IterableOnceOps
def maxBy[B](f: MetaData => B)(implicit cmp: Ordering[B]): MetaData
Inherited from:
IterableOnceOps
def maxByOption[B](f: MetaData => B)(implicit cmp: Ordering[B]): Option[MetaData]
Inherited from:
IterableOnceOps
def maxOption[B >: MetaData](implicit ord: Ordering[B]): Option[MetaData]
Inherited from:
IterableOnceOps
def min[B >: MetaData](implicit ord: Ordering[B]): MetaData
Inherited from:
IterableOnceOps
def minBy[B](f: MetaData => B)(implicit cmp: Ordering[B]): MetaData
Inherited from:
IterableOnceOps
def minByOption[B](f: MetaData => B)(implicit cmp: Ordering[B]): Option[MetaData]
Inherited from:
IterableOnceOps
def minOption[B >: MetaData](implicit ord: Ordering[B]): Option[MetaData]
Inherited from:
IterableOnceOps
final def mkString: String
Inherited from:
IterableOnceOps
final def mkString(sep: String): String
Inherited from:
IterableOnceOps
final def mkString(start: String, sep: String, end: String): String
Inherited from:
IterableOnceOps
@deprecatedOverriding(message = "nonEmpty is defined as !isEmpty; override isEmpty instead", since = "2.13.0")
Inherited from:
IterableOnceOps
def partitionMap[A1, A2](f: MetaData => Either[A1, A2]): (Iterable[A1], Iterable[A2])
Inherited from:
IterableOps
def product[B >: MetaData](implicit num: Numeric[B]): B
Inherited from:
IterableOnceOps
def reduce[B >: MetaData](op: (B, B) => B): B
Inherited from:
IterableOnceOps
def reduceLeft[B >: MetaData](op: (B, MetaData) => B): B
Inherited from:
IterableOnceOps
def reduceLeftOption[B >: MetaData](op: (B, MetaData) => B): Option[B]
Inherited from:
IterableOnceOps
def reduceOption[B >: MetaData](op: (B, B) => B): Option[B]
Inherited from:
IterableOnceOps
def reduceRight[B >: MetaData](op: (MetaData, B) => B): B
Inherited from:
IterableOnceOps
def reduceRightOption[B >: MetaData](op: (MetaData, B) => B): Option[B]
Inherited from:
IterableOnceOps
protected def reversed: Iterable[MetaData]
Inherited from:
IterableOnceOps
def scan[B >: MetaData](z: B)(op: (B, B) => B): Iterable[B]
Inherited from:
IterableOps
def scanLeft[B](z: B)(op: (B, MetaData) => B): Iterable[B]
Inherited from:
IterableOps
def scanRight[B](z: B)(op: (MetaData, B) => B): Iterable[B]
Inherited from:
IterableOps
def size: Int
Inherited from:
IterableOnceOps
def sizeCompare(that: Iterable[_]): Int
Inherited from:
IterableOps
def sizeCompare(otherSize: Int): Int
Inherited from:
IterableOps
Inherited from:
IterableOps
def slice(from: Int, until: Int): Iterable[MetaData]
Inherited from:
IterableOps
def sliding(size: Int, step: Int): Iterator[Iterable[MetaData]]
Inherited from:
IterableOps
Inherited from:
IterableOps
override def splitAt(n: Int): (Iterable[MetaData], Iterable[MetaData])
Definition Classes
Inherited from:
IterableOps
def stepper[S <: Stepper[_]](implicit shape: StepperShape[MetaData, S]): S
Inherited from:
IterableOnce
Inherited from:
Equality
def sum[B >: MetaData](implicit num: Numeric[B]): B
Inherited from:
IterableOnceOps
Inherited from:
IterableOps
Inherited from:
IterableOps
Inherited from:
IterableOps
override def tapEach[U](f: MetaData => U): Iterable[MetaData]
Definition Classes
Inherited from:
IterableOps
def to[C1](factory: Factory[MetaData, C1]): C1
Inherited from:
IterableOnceOps
Inherited from:
IterableOnceOps
final def toBuffer[B >: MetaData]: Buffer[B]
Inherited from:
IterableOnceOps
final def toIterable: MetaData
Inherited from:
Iterable
Inherited from:
IterableOnceOps
def toMap[K, V](implicit ev: MetaData <:< (K, V)): Map[K, V]
Inherited from:
IterableOnceOps
Inherited from:
IterableOnceOps
def toSet[B >: MetaData]: Set[B]
Inherited from:
IterableOnceOps
def transpose[B](implicit asIterable: MetaData => Iterable[B]): Iterable[Iterable[B]]
Inherited from:
IterableOps
def unzip[A1, A2](implicit asPair: MetaData => (A1, A2)): (Iterable[A1], Iterable[A2])
Inherited from:
IterableOps
def unzip3[A1, A2, A3](implicit asTriple: MetaData => (A1, A2, A3)): (Iterable[A1], Iterable[A2], Iterable[A3])
Inherited from:
IterableOps
Inherited from:
IterableOps
final def xml_!=(other: Any): Boolean
Inherited from:
Equality
final def xml_==(other: Any): Boolean
Inherited from:
Equality
def zip[B](that: IterableOnce[B]): Iterable[(MetaData, B)]
Inherited from:
IterableOps
def zipAll[A1 >: MetaData, B](that: Iterable[B], thisElem: A1, thatElem: B): Iterable[(A1, B)]
Inherited from:
IterableOps

Deprecated and Inherited methods

@deprecated(message = "Use ++ instead of ++: for collections of type Iterable", since = "2.13.0")
def ++:[B >: MetaData](that: IterableOnce[B]): Iterable[B]
Deprecated
[Since version 2.13.0] Use ++ instead of ++: for collections of type Iterable
Inherited from:
IterableOps
@inline @deprecated(message = "Use foldLeft instead of /:", since = "2.13.0")
final def /:[B](z: B)(op: (B, MetaData) => B): B
Deprecated
[Since version 2.13.0] Use foldLeft instead of /:
Inherited from:
IterableOnceOps
@inline @deprecated(message = "Use foldRight instead of :\\", since = "2.13.0")
final def :\[B](z: B)(op: (MetaData, B) => B): B
Deprecated
[Since version 2.13.0] Use foldRight instead of :\\
Inherited from:
IterableOnceOps
@deprecated(message = "`aggregate` is not relevant for sequential collections. Use `foldLeft(z)(seqop)` instead.", since = "2.13.0")
def aggregate[B](z: => B)(seqop: (B, MetaData) => B, combop: (B, B) => B): B
Deprecated
[Since version 2.13.0] `aggregate` is not relevant for sequential collections. Use `foldLeft(z)(seqop)` instead.
Inherited from:
IterableOnceOps
@inline @deprecatedOverriding(message = "Use iterableFactory instead", since = "2.13.0") @deprecated(message = "Use iterableFactory instead", since = "2.13.0")
Deprecated
[Since version 2.13.0] Use iterableFactory instead
Inherited from:
IterableOps
@inline @deprecated(message = "Use `dest ++= coll` instead", since = "2.13.0")
final def copyToBuffer[B >: MetaData](dest: Buffer[B]): Unit
Deprecated
[Since version 2.13.0] Use `dest ++= coll` instead
Inherited from:
IterableOnceOps
@deprecated(message = "Check .knownSize instead of .hasDefiniteSize for more actionable information (see scaladoc for details)", since = "2.13.0")
Deprecated
[Since version 2.13.0] Check .knownSize instead of .hasDefiniteSize for more actionable information (see scaladoc for details)
Inherited from:
IterableOnceOps
@deprecated(message = "Use coll instead of repr in a collection implementation, use the collection value itself from the outside", since = "2.13.0")
final def repr: Iterable[MetaData]
Deprecated
[Since version 2.13.0] Use coll instead of repr in a collection implementation, use the collection value itself from the outside
Inherited from:
IterableOps
@deprecated(message = "Iterable.seq always returns the iterable itself", since = "2.13.0")
Deprecated
[Since version 2.13.0] Iterable.seq always returns the iterable itself
Inherited from:
Iterable
@inline @deprecated(message = "Use .iterator instead of .toIterator", since = "2.13.0")
Deprecated
[Since version 2.13.0] Use .iterator instead of .toIterator
Inherited from:
IterableOnceOps
@inline @deprecated(message = "Use .to(LazyList) instead of .toStream", since = "2.13.0")
Deprecated
[Since version 2.13.0] Use .to(LazyList) instead of .toStream
Inherited from:
IterableOnceOps
@deprecated(message = "Use toIterable instead", since = "2.13.0")
Deprecated
[Since version 2.13.0] Use toIterable instead
Inherited from:
IterableOps
@deprecated(message = "Use .view.slice(from, until) instead of .view(from, until)", since = "2.13.0")
def view(from: Int, until: Int): View[MetaData]
Deprecated
[Since version 2.13.0] Use .view.slice(from, until) instead of .view(from, until)
Inherited from:
IterableOps