object JsDomConversions extends YaidomToJsDomConversions with JsDomToYaidomConversions
Conversions between yaidom nodes and JS DOM nodes.
- Alphabetic
- By Inheritance
- JsDomConversions
- JsDomToYaidomConversions
- ConverterToDocument
- YaidomToJsDomConversions
- DocumentConverter
- ElemConverter
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
convertComment(comment: Comment, doc: Document): Comment
Converts a yaidom
Comment
to a DOMComment
.Converts a yaidom
Comment
to a DOMComment
. A DOM document is passed as node factory.- Definition Classes
- YaidomToJsDomConversions
-
final
def
convertDocument(document: Document): DocumentProducer
Converts a yaidom
Document
to a function from DOM documents (as node factories) to (filled) DOM documentsConverts a yaidom
Document
to a function from DOM documents (as node factories) to (filled) DOM documents- Definition Classes
- YaidomToJsDomConversions → DocumentConverter
-
final
def
convertElem(elm: Elem, doc: Document, parentScope: Scope): Element
Converts a yaidom
Elem
to a DOM element.Converts a yaidom
Elem
to a DOM element. A DOM document is passed as node factory. The passed parent scope is used as follows: the namespace declarations on the result DOM element are:parentScope.relativize(elm.scope)
.- Definition Classes
- YaidomToJsDomConversions
-
final
def
convertElem(elm: Elem): ElementProducer
Same as
{ doc => convertElem(elm, doc, Scope.Empty) }
Same as
{ doc => convertElem(elm, doc, Scope.Empty) }
- Definition Classes
- YaidomToJsDomConversions → ElemConverter
-
final
def
convertNode(node: Node, doc: Document, parentScope: Scope): Node
Converts a yaidom node to a DOM node.
Converts a yaidom node to a DOM node. A DOM document is passed as node factory. If the node is an element, the passed parent scope is used as in
convertElem(e, doc, parentScope)
.- Definition Classes
- YaidomToJsDomConversions
-
final
def
convertProcessingInstruction(processingInstruction: ProcessingInstruction, doc: Document): ProcessingInstruction
Converts a yaidom
ProcessingInstruction
to a DOMProcessingInstruction
.Converts a yaidom
ProcessingInstruction
to a DOMProcessingInstruction
. A DOM document is passed as node factory.- Definition Classes
- YaidomToJsDomConversions
-
final
def
convertText(text: Text, doc: Document): Text
Converts a yaidom
Text
to a DOMText
.Converts a yaidom
Text
to a DOMText
. A DOM document is passed as node factory.- Definition Classes
- YaidomToJsDomConversions
-
final
def
convertToComment(v: Comment): Comment
Converts an
org.scalajs.dom.raw.Comment
to aeu.cdevreeze.yaidom.simple.Comment
Converts an
org.scalajs.dom.raw.Comment
to aeu.cdevreeze.yaidom.simple.Comment
- Definition Classes
- JsDomToYaidomConversions
-
final
def
convertToDocument(v: Document): Document
Converts an
org.scalajs.dom.raw.Document
to aeu.cdevreeze.yaidom.simple.Document
.Converts an
org.scalajs.dom.raw.Document
to aeu.cdevreeze.yaidom.simple.Document
.- Definition Classes
- JsDomToYaidomConversions → ConverterToDocument
-
final
def
convertToElem(v: Element, parentScope: Scope): Elem
Given a parent scope, converts an
org.scalajs.dom.raw.Element
to aeu.cdevreeze.yaidom.simple.Elem
.Given a parent scope, converts an
org.scalajs.dom.raw.Element
to aeu.cdevreeze.yaidom.simple.Elem
.The result
Elem
gets ScopeparentScope.resolve(extractNamespaceDeclarations(v.getAttributes))
.Be careful: the namespaces inherited by the passed DOM element, if any, are ignored! In other words, the ancestry of the passed DOM element is entirely ignored. This may cause an exception to be thrown, if there are indeed such namespaces, unless they are a subset of the passed parent scope.
- Definition Classes
- JsDomToYaidomConversions
-
final
def
convertToNodeOption(v: Node, parentScope: Scope): Option[Node]
Given a parent scope, converts an
org.scalajs.dom.raw.Node
to an optionaleu.cdevreeze.yaidom.simple.Node
.Given a parent scope, converts an
org.scalajs.dom.raw.Node
to an optionaleu.cdevreeze.yaidom.simple.Node
.In case of an element, the result
Elem
(wrapped in an Option) gets ScopeparentScope.resolve(extractNamespaceDeclarations(v.getAttributes))
.Be careful: the namespaces inherited by the passed DOM node, if any, are ignored! In other words, the ancestry of the passed DOM node is entirely ignored. This may cause an exception to be thrown, if there are indeed such namespaces, unless they are a subset of the passed parent scope.
- Definition Classes
- JsDomToYaidomConversions
-
final
def
convertToProcessingInstruction(v: ProcessingInstruction): ProcessingInstruction
Converts an
org.scalajs.dom.raw.ProcessingInstruction
to aeu.cdevreeze.yaidom.simple.ProcessingInstruction
Converts an
org.scalajs.dom.raw.ProcessingInstruction
to aeu.cdevreeze.yaidom.simple.ProcessingInstruction
- Definition Classes
- JsDomToYaidomConversions
-
final
def
convertToText(v: Text): Text
Converts an
org.scalajs.dom.raw.Text
to aeu.cdevreeze.yaidom.simple.Text
Converts an
org.scalajs.dom.raw.Text
to aeu.cdevreeze.yaidom.simple.Text
- Definition Classes
- JsDomToYaidomConversions
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
extractAttributes(domAttributes: NamedNodeMap): IndexedSeq[(QName, String)]
Converts a
NamedNodeMap
to animmutable.IndexedSeq[(QName, String)]
.Converts a
NamedNodeMap
to animmutable.IndexedSeq[(QName, String)]
. Namespace declarations are skipped.- Definition Classes
- JsDomToYaidomConversions
-
final
def
extractNamespaceDeclaration(v: Attr): (Option[String], String)
Extracts (optional) prefix and namespace.
Extracts (optional) prefix and namespace. Call only if
isNamespaceDeclaration(v)
, since otherwise an exception is thrown.- Definition Classes
- JsDomToYaidomConversions
-
final
def
extractNamespaceDeclarations(domAttributes: NamedNodeMap): Declarations
Converts the namespace declarations in a
NamedNodeMap
to aDeclarations
Converts the namespace declarations in a
NamedNodeMap
to aDeclarations
- Definition Classes
- JsDomToYaidomConversions
-
final
def
extractResolvedAttributes(domAttributes: NamedNodeMap): IndexedSeq[(EName, String)]
Converts a
NamedNodeMap
to animmutable.IndexedSeq[(EName, String)]
.Converts a
NamedNodeMap
to animmutable.IndexedSeq[(EName, String)]
. Namespace declarations are skipped.- Definition Classes
- JsDomToYaidomConversions
-
def
finalize(): Unit
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native()
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
final
def
isNamespaceDeclaration(v: Attr): Boolean
Returns true if the
org.scalajs.dom.raw.Attr
is a namespace declarationReturns true if the
org.scalajs.dom.raw.Attr
is a namespace declaration- Definition Classes
- JsDomToYaidomConversions
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
nodeListToIndexedSeq(nodeList: NodeList): IndexedSeq[Node]
Helper method that converts a
NodeList
to anIndexedSeq[org.scalajs.dom.raw.Node]
Helper method that converts a
NodeList
to anIndexedSeq[org.scalajs.dom.raw.Node]
- Definition Classes
- JsDomToYaidomConversions
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
final
def
toEName(v: Attr)(implicit enameProvider: ENameProvider): EName
Extracts the
EName
of anorg.scalajs.dom.raw.Attr
.Extracts the
EName
of anorg.scalajs.dom.raw.Attr
. If theAttr
is a namespace declaration, an exception is thrown.- Definition Classes
- JsDomToYaidomConversions
-
final
def
toEName(v: Element)(implicit enameProvider: ENameProvider): EName
Extracts the
EName
of anorg.scalajs.dom.raw.Element
Extracts the
EName
of anorg.scalajs.dom.raw.Element
- Definition Classes
- JsDomToYaidomConversions
-
final
def
toQName(v: Attr)(implicit qnameProvider: QNameProvider): QName
Extracts the
QName
of anorg.scalajs.dom.raw.Attr
.Extracts the
QName
of anorg.scalajs.dom.raw.Attr
. If theAttr
is a namespace declaration, an exception is thrown.- Definition Classes
- JsDomToYaidomConversions
-
final
def
toQName(v: Element)(implicit qnameProvider: QNameProvider): QName
Extracts the
QName
of anorg.scalajs.dom.raw.Element
Extracts the
QName
of anorg.scalajs.dom.raw.Element
- Definition Classes
- JsDomToYaidomConversions
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()