MCPcopy Create free account
hub / github.com/Kitware/VTK / IsVariableName

Method IsVariableName

Common/Misc/vtkFunctionParser.cxx:896–916  ·  view source on GitHub ↗

------------------------------------------------------------------------------

Source from the content-addressed store, hash-verified

894
895//------------------------------------------------------------------------------
896int vtkFunctionParser::IsVariableName(int currentIndex)
897{
898 for (int i = 0, max = this->GetNumberOfScalarVariables(); i < max; i++)
899 {
900 if (strncmp(this->ScalarVariableNames[i].c_str(), &this->Function[currentIndex],
901 this->ScalarVariableNames[i].size()) == 0)
902 {
903 return 1;
904 }
905 }
906 for (int i = 0, max = this->GetNumberOfVectorVariables(); i < max; i++)
907 {
908 if (strncmp(this->VectorVariableNames[i].c_str(), &this->Function[currentIndex],
909 this->VectorVariableNames[i].size()) == 0)
910 {
911 return 1;
912 }
913 }
914
915 return 0;
916}
917
918//------------------------------------------------------------------------------
919int vtkFunctionParser::IsElementaryOperator(int op)

Callers 1

CheckExpressionMethod · 0.95

Calls 2

c_strMethod · 0.45
sizeMethod · 0.45

Tested by

no test coverage detected