Constructs a QDomImplementation object.
*/
QDomImplementation::QDomImplementation()
+ : impl(Q_NULLPTR)
{
- impl = 0;
}
/*!
Constructs a copy of \a x.
*/
QDomImplementation::QDomImplementation(const QDomImplementation &x)
+ : impl(x.impl)
{
- impl = x.impl;
if (impl)
impl->ref.ref();
}
QDomImplementation::QDomImplementation(QDomImplementationPrivate *p)
+ : impl(p)
{
// We want to be co-owners, so increase the reference count
- impl = p;
if (impl)
impl->ref.ref();
}
Constructs a \link isNull() null\endlink node.
*/
QDomNode::QDomNode()
+ : impl(Q_NULLPTR)
{
- impl = 0;
}
/*!
cloneNode().
*/
QDomNode::QDomNode(const QDomNode &n)
+ : impl(n.impl)
{
- impl = n.impl;
if (impl)
impl->ref.ref();
}
Constructs a new node for the data \a n.
*/
QDomNode::QDomNode(QDomNodePrivate *n)
+ : impl(n)
{
- impl = n;
if (impl)
impl->ref.ref();
}
*/
bool QDomNode::isNull() const
{
- return (impl == 0);
+ return (impl == Q_NULLPTR);
}
/*!
{
if (impl && !impl->ref.deref())
delete impl;
- impl = 0;
+ impl = Q_NULLPTR;
}
/*!
Constructs an empty named node map.
*/
QDomNamedNodeMap::QDomNamedNodeMap()
+ : impl(Q_NULLPTR)
{
- impl = 0;
}
/*!
Constructs a copy of \a n.
*/
QDomNamedNodeMap::QDomNamedNodeMap(const QDomNamedNodeMap &n)
+ : impl(n.impl)
{
- impl = n.impl;
if (impl)
impl->ref.ref();
}
QDomNamedNodeMap::QDomNamedNodeMap(QDomNamedNodeMapPrivate *n)
+ : impl(n)
{
- impl = n;
if (impl)
impl->ref.ref();
}
/*!
Creates an empty QDomDocumentType object.
*/
-QDomDocumentType::QDomDocumentType() : QDomNode()
+QDomDocumentType::QDomDocumentType()
+ : QDomNode()
{
}
Constructs an empty document fragment.
*/
QDomDocumentFragment::QDomDocumentFragment()
+ : QDomNode()
{
}
Constructs an empty character data object.
*/
QDomCharacterData::QDomCharacterData()
+ : QDomNode()
{
}
Constructs an empty attribute.
*/
QDomAttr::QDomAttr()
+ : QDomNode()
{
}
Constructs an empty document.
*/
QDomDocument::QDomDocument()
+ : QDomNode()
{
- impl = 0;
}
/*!
name.
*/
QDomDocument::QDomDocument(const QString& name)
+ : QDomNode(new QDomDocumentPrivate(name)) // We take over ownership
{
- // We take over ownership
- impl = new QDomDocumentPrivate(name);
}
/*!
\sa QDomImplementation::createDocumentType()
*/
QDomDocument::QDomDocument(const QDomDocumentType& doctype)
+ : QDomNode(new QDomDocumentPrivate((QDomDocumentTypePrivate*)(doctype.impl)))
{
- impl = new QDomDocumentPrivate((QDomDocumentTypePrivate*)(doctype.impl));
}
/*!