import typing

import java
import java.lang

class Attr(Node):
    def getName(self) -> str: ...
    def getOwnerElement(self) -> Element: ...
    def getSchemaTypeInfo(self) -> TypeInfo: ...
    def getSpecified(self) -> bool: ...
    def getValue(self) -> str: ...
    def isId(self) -> bool: ...
    def setValue(self, arg1: str | java.lang.String, /) -> None: ...

class CDATASection(Text): ...

class CharacterData(Node):
    def appendData(self, arg1: str | java.lang.String, /) -> None: ...
    def deleteData(self, arg1: int | java.jint | java.lang.Integer, arg2: int | java.jint | java.lang.Integer, /) -> None: ...
    def getData(self) -> str: ...
    def getLength(self) -> int: ...
    def insertData(self, arg1: int | java.jint | java.lang.Integer, arg2: str | java.lang.String, /) -> None: ...
    def replaceData(self, arg1: int | java.jint | java.lang.Integer, arg2: int | java.jint | java.lang.Integer, arg3: str | java.lang.String, /) -> None: ...
    def setData(self, arg1: str | java.lang.String, /) -> None: ...
    def substringData(self, arg1: int | java.jint | java.lang.Integer, arg2: int | java.jint | java.lang.Integer, /) -> str: ...

class Comment(CharacterData): ...

class DOMConfiguration(java.lang.Object):
    def canSetParameter(self, arg1: str | java.lang.String, arg2: java.lang.Object | int | bool | float | str, /) -> bool: ...
    def getParameter(self, arg1: str | java.lang.String, /) -> java.lang.Object: ...
    def getParameterNames(self) -> DOMStringList: ...
    def setParameter(self, arg1: str | java.lang.String, arg2: java.lang.Object | int | bool | float | str, /) -> None: ...

class DOMError(java.lang.Object):
    SEVERITY_ERROR: typing.ClassVar[int] = ...
    SEVERITY_FATAL_ERROR: typing.ClassVar[int] = ...
    SEVERITY_WARNING: typing.ClassVar[int] = ...
    def getLocation(self) -> DOMLocator: ...
    def getMessage(self) -> str: ...
    def getRelatedData(self) -> java.lang.Object: ...
    def getRelatedException(self) -> java.lang.Object: ...
    def getSeverity(self) -> int: ...
    def getType(self) -> str: ...

class DOMErrorHandler(java.lang.Object):
    def handleError(self, arg1: DOMError, /) -> bool: ...

class DOMException(java.lang.RuntimeException):
    DOMSTRING_SIZE_ERR: typing.ClassVar[int] = ...
    HIERARCHY_REQUEST_ERR: typing.ClassVar[int] = ...
    INDEX_SIZE_ERR: typing.ClassVar[int] = ...
    INUSE_ATTRIBUTE_ERR: typing.ClassVar[int] = ...
    INVALID_ACCESS_ERR: typing.ClassVar[int] = ...
    INVALID_CHARACTER_ERR: typing.ClassVar[int] = ...
    INVALID_MODIFICATION_ERR: typing.ClassVar[int] = ...
    INVALID_STATE_ERR: typing.ClassVar[int] = ...
    NAMESPACE_ERR: typing.ClassVar[int] = ...
    NOT_FOUND_ERR: typing.ClassVar[int] = ...
    NOT_SUPPORTED_ERR: typing.ClassVar[int] = ...
    NO_DATA_ALLOWED_ERR: typing.ClassVar[int] = ...
    NO_MODIFICATION_ALLOWED_ERR: typing.ClassVar[int] = ...
    SYNTAX_ERR: typing.ClassVar[int] = ...
    TYPE_MISMATCH_ERR: typing.ClassVar[int] = ...
    VALIDATION_ERR: typing.ClassVar[int] = ...
    WRONG_DOCUMENT_ERR: typing.ClassVar[int] = ...
    code: int = ...
    def __init__(self, code: int | java.jshort | java.lang.Short, message: str | java.lang.String, /) -> None: ...

class DOMImplementation(java.lang.Object):
    def createDocument(self, arg1: str | java.lang.String, arg2: str | java.lang.String, arg3: DocumentType, /) -> Document: ...
    def createDocumentType(self, arg1: str | java.lang.String, arg2: str | java.lang.String, arg3: str | java.lang.String, /) -> DocumentType: ...
    def getFeature(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> java.lang.Object: ...
    def hasFeature(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> bool: ...

class DOMImplementationList(java.lang.Object):
    def getLength(self) -> int: ...
    def item(self, arg1: int | java.jint | java.lang.Integer, /) -> DOMImplementation: ...

class DOMImplementationSource(java.lang.Object):
    def getDOMImplementation(self, arg1: str | java.lang.String, /) -> DOMImplementation: ...
    def getDOMImplementationList(self, arg1: str | java.lang.String, /) -> DOMImplementationList: ...

class DOMLocator(java.lang.Object):
    def getByteOffset(self) -> int: ...
    def getColumnNumber(self) -> int: ...
    def getLineNumber(self) -> int: ...
    def getRelatedNode(self) -> Node: ...
    def getUri(self) -> str: ...
    def getUtf16Offset(self) -> int: ...

class DOMStringList(java.lang.Object):
    def contains(self, arg1: str | java.lang.String, /) -> bool: ...
    def getLength(self) -> int: ...
    def item(self, arg1: int | java.jint | java.lang.Integer, /) -> str: ...

class Document(Node):
    def adoptNode(self, arg1: Node, /) -> Node: ...
    def createAttribute(self, arg1: str | java.lang.String, /) -> Attr: ...
    def createAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> Attr: ...
    def createCDATASection(self, arg1: str | java.lang.String, /) -> CDATASection: ...
    def createComment(self, arg1: str | java.lang.String, /) -> Comment: ...
    def createDocumentFragment(self) -> DocumentFragment: ...
    def createElement(self, arg1: str | java.lang.String, /) -> Element: ...
    def createElementNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> Element: ...
    def createEntityReference(self, arg1: str | java.lang.String, /) -> EntityReference: ...
    def createProcessingInstruction(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> ProcessingInstruction: ...
    def createTextNode(self, arg1: str | java.lang.String, /) -> Text: ...
    def getDoctype(self) -> DocumentType: ...
    def getDocumentElement(self) -> Element: ...
    def getDocumentURI(self) -> str: ...
    def getDomConfig(self) -> DOMConfiguration: ...
    def getElementById(self, arg1: str | java.lang.String, /) -> Element: ...
    def getElementsByTagName(self, arg1: str | java.lang.String, /) -> NodeList: ...
    def getElementsByTagNameNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> NodeList: ...
    def getImplementation(self) -> DOMImplementation: ...
    def getInputEncoding(self) -> str: ...
    def getStrictErrorChecking(self) -> bool: ...
    def getXmlEncoding(self) -> str: ...
    def getXmlStandalone(self) -> bool: ...
    def getXmlVersion(self) -> str: ...
    def importNode(self, arg1: Node, arg2: bool | java.jboolean | java.lang.Boolean, /) -> Node: ...
    def normalizeDocument(self) -> None: ...
    def renameNode(self, arg1: Node, arg2: str | java.lang.String, arg3: str | java.lang.String, /) -> Node: ...
    def setDocumentURI(self, arg1: str | java.lang.String, /) -> None: ...
    def setStrictErrorChecking(self, arg1: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setXmlStandalone(self, arg1: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setXmlVersion(self, arg1: str | java.lang.String, /) -> None: ...

class DocumentFragment(Node): ...

class DocumentType(Node):
    def getEntities(self) -> NamedNodeMap: ...
    def getInternalSubset(self) -> str: ...
    def getName(self) -> str: ...
    def getNotations(self) -> NamedNodeMap: ...
    def getPublicId(self) -> str: ...
    def getSystemId(self) -> str: ...

class Element(Node):
    def getAttribute(self, arg1: str | java.lang.String, /) -> str: ...
    def getAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> str: ...
    def getAttributeNode(self, arg1: str | java.lang.String, /) -> Attr: ...
    def getAttributeNodeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> Attr: ...
    def getElementsByTagName(self, arg1: str | java.lang.String, /) -> NodeList: ...
    def getElementsByTagNameNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> NodeList: ...
    def getSchemaTypeInfo(self) -> TypeInfo: ...
    def getTagName(self) -> str: ...
    def hasAttribute(self, arg1: str | java.lang.String, /) -> bool: ...
    def hasAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> bool: ...
    def removeAttribute(self, arg1: str | java.lang.String, /) -> None: ...
    def removeAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> None: ...
    def removeAttributeNode(self, arg1: Attr, /) -> Attr: ...
    def setAttribute(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> None: ...
    def setAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, arg3: str | java.lang.String, /) -> None: ...
    def setAttributeNode(self, arg1: Attr, /) -> Attr: ...
    def setAttributeNodeNS(self, arg1: Attr, /) -> Attr: ...
    def setIdAttribute(self, arg1: str | java.lang.String, arg2: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setIdAttributeNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, arg3: bool | java.jboolean | java.lang.Boolean, /) -> None: ...
    def setIdAttributeNode(self, arg1: Attr, arg2: bool | java.jboolean | java.lang.Boolean, /) -> None: ...

class Entity(Node):
    def getInputEncoding(self) -> str: ...
    def getNotationName(self) -> str: ...
    def getPublicId(self) -> str: ...
    def getSystemId(self) -> str: ...
    def getXmlEncoding(self) -> str: ...
    def getXmlVersion(self) -> str: ...

class EntityReference(Node): ...

class NameList(java.lang.Object):
    def contains(self, arg1: str | java.lang.String, /) -> bool: ...
    def containsNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> bool: ...
    def getLength(self) -> int: ...
    def getName(self, arg1: int | java.jint | java.lang.Integer, /) -> str: ...
    def getNamespaceURI(self, arg1: int | java.jint | java.lang.Integer, /) -> str: ...

class NamedNodeMap(java.lang.Object):
    def getLength(self) -> int: ...
    def getNamedItem(self, arg1: str | java.lang.String, /) -> Node: ...
    def getNamedItemNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> Node: ...
    def item(self, arg1: int | java.jint | java.lang.Integer, /) -> Node: ...
    def removeNamedItem(self, arg1: str | java.lang.String, /) -> Node: ...
    def removeNamedItemNS(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> Node: ...
    def setNamedItem(self, arg1: Node, /) -> Node: ...
    def setNamedItemNS(self, arg1: Node, /) -> Node: ...

class Node(java.lang.Object):
    ATTRIBUTE_NODE: typing.ClassVar[int] = ...
    CDATA_SECTION_NODE: typing.ClassVar[int] = ...
    COMMENT_NODE: typing.ClassVar[int] = ...
    DOCUMENT_FRAGMENT_NODE: typing.ClassVar[int] = ...
    DOCUMENT_NODE: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_CONTAINED_BY: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_CONTAINS: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_DISCONNECTED: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_FOLLOWING: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC: typing.ClassVar[int] = ...
    DOCUMENT_POSITION_PRECEDING: typing.ClassVar[int] = ...
    DOCUMENT_TYPE_NODE: typing.ClassVar[int] = ...
    ELEMENT_NODE: typing.ClassVar[int] = ...
    ENTITY_NODE: typing.ClassVar[int] = ...
    ENTITY_REFERENCE_NODE: typing.ClassVar[int] = ...
    NOTATION_NODE: typing.ClassVar[int] = ...
    PROCESSING_INSTRUCTION_NODE: typing.ClassVar[int] = ...
    TEXT_NODE: typing.ClassVar[int] = ...
    def appendChild(self, arg1: Node, /) -> Node: ...
    def cloneNode(self, arg1: bool | java.jboolean | java.lang.Boolean, /) -> Node: ...
    def compareDocumentPosition(self, arg1: Node, /) -> int: ...
    def getAttributes(self) -> NamedNodeMap: ...
    def getBaseURI(self) -> str: ...
    def getChildNodes(self) -> NodeList: ...
    def getFeature(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> java.lang.Object: ...
    def getFirstChild(self) -> Node: ...
    def getLastChild(self) -> Node: ...
    def getLocalName(self) -> str: ...
    def getNamespaceURI(self) -> str: ...
    def getNextSibling(self) -> Node: ...
    def getNodeName(self) -> str: ...
    def getNodeType(self) -> int: ...
    def getNodeValue(self) -> str: ...
    def getOwnerDocument(self) -> Document: ...
    def getParentNode(self) -> Node: ...
    def getPrefix(self) -> str: ...
    def getPreviousSibling(self) -> Node: ...
    def getTextContent(self) -> str: ...
    def getUserData(self, arg1: str | java.lang.String, /) -> java.lang.Object: ...
    def hasAttributes(self) -> bool: ...
    def hasChildNodes(self) -> bool: ...
    def insertBefore(self, arg1: Node, arg2: Node, /) -> Node: ...
    def isDefaultNamespace(self, arg1: str | java.lang.String, /) -> bool: ...
    def isEqualNode(self, arg1: Node, /) -> bool: ...
    def isSameNode(self, arg1: Node, /) -> bool: ...
    def isSupported(self, arg1: str | java.lang.String, arg2: str | java.lang.String, /) -> bool: ...
    def lookupNamespaceURI(self, arg1: str | java.lang.String, /) -> str: ...
    def lookupPrefix(self, arg1: str | java.lang.String, /) -> str: ...
    def normalize(self) -> None: ...
    def removeChild(self, arg1: Node, /) -> Node: ...
    def replaceChild(self, arg1: Node, arg2: Node, /) -> Node: ...
    def setNodeValue(self, arg1: str | java.lang.String, /) -> None: ...
    def setPrefix(self, arg1: str | java.lang.String, /) -> None: ...
    def setTextContent(self, arg1: str | java.lang.String, /) -> None: ...
    def setUserData(self, arg1: str | java.lang.String, arg2: java.lang.Object | int | bool | float | str, arg3: UserDataHandler, /) -> java.lang.Object: ...

class NodeList(java.lang.Object):
    def getLength(self) -> int: ...
    def item(self, arg1: int | java.jint | java.lang.Integer, /) -> Node: ...

class Notation(Node):
    def getPublicId(self) -> str: ...
    def getSystemId(self) -> str: ...

class ProcessingInstruction(Node):
    def getData(self) -> str: ...
    def getTarget(self) -> str: ...
    def setData(self, arg1: str | java.lang.String, /) -> None: ...

class Text(CharacterData):
    def getWholeText(self) -> str: ...
    def isElementContentWhitespace(self) -> bool: ...
    def replaceWholeText(self, arg1: str | java.lang.String, /) -> Text: ...
    def splitText(self, arg1: int | java.jint | java.lang.Integer, /) -> Text: ...

class TypeInfo(java.lang.Object):
    DERIVATION_EXTENSION: typing.ClassVar[int] = ...
    DERIVATION_LIST: typing.ClassVar[int] = ...
    DERIVATION_RESTRICTION: typing.ClassVar[int] = ...
    DERIVATION_UNION: typing.ClassVar[int] = ...
    def getTypeName(self) -> str: ...
    def getTypeNamespace(self) -> str: ...
    def isDerivedFrom(self, arg1: str | java.lang.String, arg2: str | java.lang.String, arg3: int | java.jint | java.lang.Integer, /) -> bool: ...

class UserDataHandler(java.lang.Object):
    NODE_ADOPTED: typing.ClassVar[int] = ...
    NODE_CLONED: typing.ClassVar[int] = ...
    NODE_DELETED: typing.ClassVar[int] = ...
    NODE_IMPORTED: typing.ClassVar[int] = ...
    NODE_RENAMED: typing.ClassVar[int] = ...
    def handle(self, arg1: int | java.jshort | java.lang.Short, arg2: str | java.lang.String, arg3: java.lang.Object | int | bool | float | str, arg4: Node, arg5: Node, /) -> None: ...
