This source file includes following definitions.
- m_systemId
- baseURI
- nodeName
- nodeType
- cloneNode
- insertedInto
- removedFrom
#include "config.h"
#include "core/dom/DocumentType.h"
#include "core/dom/Document.h"
#include "core/dom/NamedNodeMap.h"
namespace WebCore {
DocumentType::DocumentType(Document* document, const String& name, const String& publicId, const String& systemId)
: Node(document, CreateOther)
, m_name(name)
, m_publicId(publicId)
, m_systemId(systemId)
{
ScriptWrappable::init(this);
}
KURL DocumentType::baseURI() const
{
return KURL();
}
String DocumentType::nodeName() const
{
return name();
}
Node::NodeType DocumentType::nodeType() const
{
return DOCUMENT_TYPE_NODE;
}
PassRefPtr<Node> DocumentType::cloneNode(bool )
{
return create(&document(), m_name, m_publicId, m_systemId);
}
Node::InsertionNotificationRequest DocumentType::insertedInto(ContainerNode* insertionPoint)
{
Node::insertedInto(insertionPoint);
ASSERT(parentNode()->isDocumentNode());
document().setDoctype(this);
return InsertionDone;
}
void DocumentType::removedFrom(ContainerNode* insertionPoint)
{
document().setDoctype(nullptr);
Node::removedFrom(insertionPoint);
}
}