Skip to content

Commit 9add97a

Browse files
committed
Create DOM Level 1 Classes (but not implemented)
1 parent 429bc3e commit 9add97a

22 files changed

+83
-0
lines changed

python/dom/NotImplemented/Attr.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Attr:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class CDATASection:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class CharacterData:
2+
pass

python/dom/NotImplemented/Comment.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Comment:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class DOMException:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class DOMImplementation:
2+
pass
+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class DOMString:
2+
pass

python/dom/NotImplemented/Document.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Document:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class DocumentFragment:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class DocumentType:
2+
pass

python/dom/NotImplemented/Element.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Element:
2+
pass

python/dom/NotImplemented/Entity.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Entity:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class EntityReference:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class NamedNodeMap:
2+
pass

python/dom/NotImplemented/Node.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Node:
2+
pass

python/dom/NotImplemented/NodeList.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class NodeList:
2+
pass

python/dom/NotImplemented/Notation.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Notation:
2+
pass
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class ProcessingInstruction:
2+
pass

python/dom/NotImplemented/Text.py

+2
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
class Text:
2+
pass

python/dom/NotImplemented/__init__.py

+21
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
from __future__ import absolute_import
2+
3+
from python.dom.NotImplemented.Attr import Attr
4+
from python.dom.NotImplemented.CDATASection import CDATASection
5+
from python.dom.NotImplemented.CharacterData import CharacterData
6+
from python.dom.NotImplemented.Comment import Comment
7+
from python.dom.NotImplemented.Document import Document
8+
from python.dom.NotImplemented.DocumentFragment import DocumentFragment
9+
from python.dom.NotImplemented.DocumentType import DocumentType
10+
from python.dom.NotImplemented.DOMException import DOMException
11+
from python.dom.NotImplemented.DOMImplementation import DOMImplementation
12+
from python.dom.NotImplemented.DOMString import DOMString
13+
from python.dom.NotImplemented.Element import Element
14+
from python.dom.NotImplemented.Entity import Entity
15+
from python.dom.NotImplemented.EntityReference import EntityReference
16+
from python.dom.NotImplemented.NamedNodeMap import NamedNodeMap
17+
from python.dom.NotImplemented.Node import Node
18+
from python.dom.NotImplemented.NodeList import NodeList
19+
from python.dom.NotImplemented.Notation import Notation
20+
from python.dom.NotImplemented.ProcessingInstruction import ProcessingInstruction
21+
from python.dom.NotImplemented.Text import Text

python/dom/__init__.py

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
from __future__ import absolute_import

python/dom/type_checking.py

+23
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
from __future__ import absolute_import
2+
3+
from typing import Union, TYPE_CHECKING
4+
5+
if TYPE_CHECKING:
6+
from python.dom.NotImplemented import *
7+
8+
AnyNode = Union[
9+
Node,
10+
# Ordered by NodeType
11+
Element,
12+
Attr,
13+
Text,
14+
CDATASection,
15+
EntityReference,
16+
Entity,
17+
ProcessingInstruction,
18+
Comment,
19+
Document,
20+
DocumentType,
21+
DocumentFragment,
22+
Notation,
23+
]

0 commit comments

Comments
 (0)