この関数は、指定した構文エレメントの次の (右の) 兄弟を構文解析します。 これは、現行の構文エレメントの次の (右の) 兄弟エレメントが必要な場合に、ブローカーによって呼び出されます。
定義されている場所 | タイプ | メンバー |
---|---|---|
CPI_VFT | 必須 | iFpParseNextSibling |
void cpiParseNextSibling(
CciParser* parser,
CciContext* context,
CciElement* currentElement);
なし。
この例は、サンプル・パーサー・ファイル BipSampPluginParser.c から取られています。
void cpiParseNextSibling(
CciParser* parser,
CciContext* context,
CciElement* element
){
PARSER_CONTEXT_ST* pc = (PARSER_CONTEXT_ST *)context ;
int rc;
while ((!cpiElementCompleteNext(&rc, cpiParent(&rc, element))) &&
(!cpiNextSibling(&rc, element)) &&
(pc->iCurrentElement))
{
pc->iCurrentElement = parseNextItem(parser, context, pc->iCurrentElement);
}
if (pc->trace) {
fprintf(pc->tracefile, "PLUGIN: <- cpiParseNextSibling()¥n");
fflush(pc->tracefile);
}
return;
}