Skip to main content

The DocXRefItem Class Reference

Node representing an item of a cross-referenced list. More...

Declaration

class DocXRefItem { ... }

Included Headers

#include <src/docnode.h>

Base class

classDocCompoundNode

Base class for nodes with children. More...

Public Constructors Index

DocXRefItem (DocParser *parser, DocNodeVariant *parent, int id, const QCString &key)

Public Member Functions Index

QCStringfile () const
QCStringanchor () const
QCStringtitle () const
QCStringrelPath () const
QCStringkey () const
boolparse ()

Private Member Attributes Index

intm_id = 0
QCStringm_key
QCStringm_file
QCStringm_anchor
QCStringm_title
QCStringm_relPath

Description

Node representing an item of a cross-referenced list.

Definition at line 620 of file docnode.h.

Public Constructors

DocXRefItem()

DocXRefItem::DocXRefItem (DocParser * parser, DocNodeVariant * parent, int id, const QCString & key)

Declaration at line 623 of file docnode.h, definition at line 473 of file docnode.cpp.

References DocCompoundNode::DocCompoundNode, key, m_id, m_key, m_relPath, DocNode::parent, DocNode::parser and relPath.

Public Member Functions

anchor()

file()

key()

QCString DocXRefItem::key ()
inline

Definition at line 628 of file docnode.h.

628 QCString key() const { return m_key; }

Reference m_key.

Referenced by DocXRefItem and HtmlDocVisitor::operator().

parse()

bool DocXRefItem::parse ()

Declaration at line 629 of file docnode.h, definition at line 478 of file docnode.cpp.

479{
481 if (refList && refList->isEnabled())
482 {
483 RefItem *item = refList->find(m_id);
484 ASSERT(item!=nullptr);
485 if (item)
486 {
487 if (parser()->context.memberDef && parser()->context.memberDef->name().at(0)=='@')
488 {
489 m_file = "@"; // can't cross reference anonymous enum
490 m_anchor = "@";
491 }
492 else
493 {
494 m_file = refList->fileName();
495 m_anchor = item->anchor();
496 }
497 m_title = refList->sectionTitle();
498 //printf("DocXRefItem: file=%s anchor=%s title=%s\n",
499 // qPrint(m_file),qPrint(m_anchor),qPrint(m_title));
500
501 if (!item->text().isEmpty())
502 {
505 parser()->popContext();
506 }
507 }
508 return TRUE;
509 }
510 return FALSE;
511}

References RefItem::anchor, ASSERT, DocCompoundNode::children, FALSE, RefList::fileName, LinkedMap< T, Hash, KeyEqual, Map >::find, RefList::find, RefListManager::instance, DocParser::internalValidatingParseDoc, QCString::isEmpty, RefList::isEnabled, m_anchor, m_file, m_id, m_key, m_title, DocNode::parser, DocParser::popContext, DocParser::pushContext, RefList::sectionTitle, RefItem::text, DocNode::thisVariant and TRUE.

relPath()

QCString DocXRefItem::relPath ()
inline

Definition at line 627 of file docnode.h.

627 QCString relPath() const { return m_relPath; }

Reference m_relPath.

Referenced by DocXRefItem and HtmlDocVisitor::operator().

title()

Private Member Attributes

m_anchor

QCString DocXRefItem::m_anchor

Definition at line 635 of file docnode.h.

Referenced by anchor and parse.

m_file

QCString DocXRefItem::m_file

Definition at line 634 of file docnode.h.

Referenced by file and parse.

m_id

int DocXRefItem::m_id = 0

Definition at line 632 of file docnode.h.

632 int m_id = 0;

Referenced by DocXRefItem and parse.

m_key

QCString DocXRefItem::m_key

Definition at line 633 of file docnode.h.

Referenced by DocXRefItem, key and parse.

m_relPath

QCString DocXRefItem::m_relPath

Definition at line 637 of file docnode.h.

Referenced by DocXRefItem and relPath.

m_title

QCString DocXRefItem::m_title

Definition at line 636 of file docnode.h.

Referenced by parse and title.


The documentation for this class was generated from the following files:


Generated via doxygen2docusaurus by Doxygen 1.14.0.