MCPcopy Create free account
hub / github.com/Tripwire/tripwire-open-source / RulePointAlreadyDefined

Method RulePointAlreadyDefined

src/twparser/genreparseinfo.cpp:113–135  ·  view source on GitHub ↗

////////////////////////////////////////////////////////////////////////// RulePointAlreadyDefined -- returns true if the given name was already used as a start or stop point //////////////////////////////////////////////////////////////////////////

Source from the content-addressed store, hash-verified

111// as a start or stop point
112///////////////////////////////////////////////////////////////////////////////
113bool cGenreParseInfo::RulePointAlreadyDefined(const cFCOName& fcoName)
114{
115 bool fFound = false;
116
117 // check start points
118 for (RuleListType::iterator i = mRuleList.begin(); i != mRuleList.end(); ++i)
119 {
120 if ((*i)->GetName() == fcoName)
121 fFound = true;
122 }
123
124 // check stop points
125 if (!fFound)
126 {
127 for (StopListType::iterator j = mStopList.begin(); j != mStopList.end(); ++j)
128 {
129 if (*j == fcoName)
130 fFound = true;
131 }
132 }
133
134 return (fFound);
135}
136
137
138///////////////////////////////////////////////////////////////////////////////

Callers 1

yyparse.cppFile · 0.80

Calls 3

beginMethod · 0.80
endMethod · 0.80
GetNameMethod · 0.45

Tested by

no test coverage detected