Doxygen
DocXRefItem类 参考

Node representing an item of a cross-referenced list 更多...

#include <docparser.h>

+ 类 DocXRefItem 继承关系图:
+ DocXRefItem 的协作图:

Public 成员函数

 DocXRefItem (DocParser &parser, DocNode *parent, int id, const QCString &key)
 
Kind kind () const override
 
QCString file () const
 
QCString anchor () const
 
QCString title () const
 
QCString relPath () const
 
QCString key () const
 
bool parse ()
 
- Public 成员函数 继承自 CompAccept< DocXRefItem >
 CompAccept (DocParser &parser)
 
void accept (DocVisitor *v) override
 
const DocNodeListchildren () const
 
DocNodeListchildren ()
 
- Public 成员函数 继承自 DocNode
 DocNode (DocParser &parser)
 
virtual ~DocNode ()
 
DocNodeparent () const
 
void setParent (DocNode *parent)
 
bool isPreformatted () const
 

Private 属性

int m_id = 0
 
QCString m_key
 
QCString m_file
 
QCString m_anchor
 
QCString m_title
 
QCString m_relPath
 

额外继承的成员函数

- Public 类型 继承自 DocNode
enum  Kind {
  Kind_Root = 0, Kind_Word = 1, Kind_WhiteSpace = 2, Kind_Para = 3,
  Kind_AutoList = 4, Kind_AutoListItem = 5, Kind_Symbol = 6, Kind_URL = 7,
  Kind_StyleChange = 8, Kind_SimpleSect = 9, Kind_Title = 10, Kind_SimpleList = 11,
  Kind_SimpleListItem = 12, Kind_Section = 13, Kind_Verbatim = 14, Kind_XRefItem = 15,
  Kind_HtmlList = 16, Kind_HtmlListItem = 17, Kind_HtmlDescList = 18, Kind_HtmlDescData = 19,
  Kind_HtmlDescTitle = 20, Kind_HtmlTable = 21, Kind_HtmlRow = 22, Kind_HtmlCell = 23,
  Kind_HtmlCaption = 24, Kind_LineBreak = 25, Kind_HorRuler = 26, Kind_Anchor = 27,
  Kind_IndexEntry = 28, Kind_Internal = 29, Kind_HRef = 30, Kind_Include = 31,
  Kind_IncOperator = 32, Kind_HtmlHeader = 33, Kind_Image = 34, Kind_DotFile = 35,
  Kind_Link = 36, Kind_Ref = 37, Kind_Formula = 38, Kind_SecRefItem = 39,
  Kind_SecRefList = 40, Kind_SimpleSectSep = 41, Kind_LinkedWord = 42, Kind_ParamSect = 43,
  Kind_ParamList = 44, Kind_InternalRef = 45, Kind_Copy = 46, Kind_Text = 47,
  Kind_MscFile = 48, Kind_HtmlBlockQuote = 49, Kind_VhdlFlow = 50, Kind_ParBlock = 51,
  Kind_DiaFile = 52, Kind_Emoji = 53, Kind_Sep = 54
}
 
- Protected 类型 继承自 DocNode
enum  RefType { Unknown, Anchor, Section, Table }
 
- Protected 成员函数 继承自 DocNode
void setInsidePreformatted (bool p)
 
- Protected 属性 继承自 CompAccept< DocXRefItem >
DocNodeList m_children
 
- Protected 属性 继承自 DocNode
DocNodem_parent = 0
 
DocParserm_parser
 

详细描述

Node representing an item of a cross-referenced list

在文件 docparser.h749 行定义.

构造及析构函数说明

◆ DocXRefItem()

DocXRefItem::DocXRefItem ( DocParser parser,
DocNode parent,
int  id,
const QCString key 
)

在文件 docparser.cpp2118 行定义.

2118  :
2120 {
2121  m_parent = parent;
2122 }

引用了 DocNode::m_parent , 以及 DocNode::parent().

成员函数说明

◆ anchor()

QCString DocXRefItem::anchor ( ) const
inline

◆ file()

QCString DocXRefItem::file ( ) const
inline

◆ key()

QCString DocXRefItem::key ( ) const
inline

在文件 docparser.h758 行定义.

758 { return m_key; }

引用了 m_key.

被这些函数引用 HtmlDocVisitor::visitPre().

◆ kind()

Kind DocXRefItem::kind ( ) const
inlineoverridevirtual

Returns the kind of node. Provides runtime type information

实现了 DocNode.

在文件 docparser.h753 行定义.

753 { return Kind_XRefItem; }

引用了 DocNode::Kind_XRefItem.

◆ parse()

bool DocXRefItem::parse ( )

在文件 docparser.cpp2124 行定义.

2125 {
2127  if (refList && refList->isEnabled())
2128  {
2129  RefItem *item = refList->find(m_id);
2130  ASSERT(item!=0);
2131  if (item)
2132  {
2134  {
2135  m_file = "@"; // can't cross reference anonymous enum
2136  m_anchor = "@";
2137  }
2138  else
2139  {
2140  m_file = refList->fileName();
2141  m_anchor = item->anchor();
2142  }
2143  m_title = refList->sectionTitle();
2144  //printf("DocXRefItem: file=%s anchor=%s title=%s\n",
2145  // qPrint(m_file),qPrint(m_anchor),qPrint(m_title));
2146 
2147  if (!item->text().isEmpty())
2148  {
2151  m_parser.popContext();
2152  }
2153  }
2154  return TRUE;
2155  }
2156  return FALSE;
2157 }

引用了 RefItem::anchor(), ASSERT, QCString::at(), DocParser::context, FALSE, RefList::fileName(), LinkedMap< T, Hash, KeyEqual, Map >::find(), RefList::find(), RefListManager::instance(), DocParser::internalValidatingParseDoc(), QCString::isEmpty(), RefList::isEnabled(), m_anchor, CompAccept< DocXRefItem >::m_children, m_file, m_id, m_key, DocNode::m_parser, m_title, DocParserContext::memberDef, Definition::name(), DocParser::popContext(), DocParser::pushContext(), RefList::sectionTitle(), RefItem::text() , 以及 TRUE.

被这些函数引用 DocPara::handleXRefItem().

◆ relPath()

QCString DocXRefItem::relPath ( ) const
inline

在文件 docparser.h757 行定义.

757 { return m_relPath; }

引用了 m_relPath.

被这些函数引用 HtmlDocVisitor::visitPre().

◆ title()

类成员变量说明

◆ m_anchor

QCString DocXRefItem::m_anchor
private

在文件 docparser.h765 行定义.

被这些函数引用 anchor() , 以及 parse().

◆ m_file

QCString DocXRefItem::m_file
private

在文件 docparser.h764 行定义.

被这些函数引用 file() , 以及 parse().

◆ m_id

int DocXRefItem::m_id = 0
private

在文件 docparser.h762 行定义.

被这些函数引用 parse().

◆ m_key

QCString DocXRefItem::m_key
private

在文件 docparser.h763 行定义.

被这些函数引用 key() , 以及 parse().

◆ m_relPath

QCString DocXRefItem::m_relPath
private

在文件 docparser.h767 行定义.

被这些函数引用 relPath().

◆ m_title

QCString DocXRefItem::m_title
private

在文件 docparser.h766 行定义.

被这些函数引用 parse() , 以及 title().


该类的文档由以下文件生成:
RefItem::text
QCString text() const
Definition: reflist.h:44
DocParser::popContext
void popContext()
Definition: docparser.cpp:222
RefListManager::instance
static RefListManager & instance()
Definition: reflist.h:120
DocParser::context
DocParserContext context
Definition: docparser.cpp:175
DocParserContext::relPath
QCString relPath
Definition: docparser.cpp:111
CompAccept< DocXRefItem >
DocParser::internalValidatingParseDoc
int internalValidatingParseDoc(DocNode *parent, DocNodeList &children, const QCString &doc)
Definition: docparser.cpp:1742
QCString::isEmpty
bool isEmpty() const
Returns TRUE iff the string is empty
Definition: qcstring.h:144
DocXRefItem::m_key
QCString m_key
Definition: docparser.h:763
RefItem
This struct represents an item in the list of references.
Definition: reflist.h:30
QCString::at
char & at(size_t i)
Returns a reference to the character at index i.
Definition: qcstring.h:477
DocXRefItem::m_id
int m_id
Definition: docparser.h:762
DocParserContext::memberDef
const MemberDef * memberDef
Definition: docparser.cpp:117
RefList
List of cross-referenced items
Definition: reflist.h:78
RefList::find
RefItem * find(int itemId)
Definition: reflist.cpp:40
DocXRefItem::m_title
QCString m_title
Definition: docparser.h:766
Definition::name
virtual QCString name() const =0
DocNode::m_parser
DocParser & m_parser
Definition: docparser.h:184
TRUE
#define TRUE
Definition: qcstring.h:36
LinkedMap::find
const T * find(const std::string &key) const
Find an object given the key.
Definition: linkedmap.h:60
DocParser::pushContext
void pushContext()
Definition: docparser.cpp:208
RefItem::anchor
QCString anchor() const
Definition: reflist.h:45
DocXRefItem::m_file
QCString m_file
Definition: docparser.h:764
DocNode::Kind_XRefItem
@ Kind_XRefItem
Definition: docparser.h:115
RefList::isEnabled
bool isEnabled() const
Definition: reflist.cpp:46
DocXRefItem::m_anchor
QCString m_anchor
Definition: docparser.h:765
DocXRefItem::key
QCString key() const
Definition: docparser.h:758
ASSERT
#define ASSERT(x)
Definition: qcstring.h:44
DocNode::parent
DocNode * parent() const
Definition: docparser.h:166
RefList::sectionTitle
QCString sectionTitle() const
Definition: reflist.h:103
DocXRefItem::m_relPath
QCString m_relPath
Definition: docparser.h:767
CompAccept< DocXRefItem >::m_children
DocNodeList m_children
Definition: docparser.h:211
DocNode::m_parent
DocNode * m_parent
Definition: docparser.h:182
FALSE
#define FALSE
Definition: qcstring.h:33
RefList::fileName
QCString fileName() const
Definition: reflist.h:101