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

Function arrayComponentInfoMatches

Common/ExecutionModel/vtkAlgorithm.cxx:65–72  ·  view source on GitHub ↗

Returns true if the FIELD_ATTRIBUTE_COMPONENT() of \a info matches \a component. This includes testing whether the key is present or absent as well as its value.

Source from the content-addressed store, hash-verified

63// Returns true if the FIELD_ATTRIBUTE_COMPONENT() of \a info matches \a component.
64// This includes testing whether the key is present or absent as well as its value.
65bool arrayComponentInfoMatches(vtkInformation* info, int component)
66{
67 if (info->Has(vtkDataObject::FIELD_ATTRIBUTE_COMPONENT()))
68 {
69 return info->Get(vtkDataObject::FIELD_ATTRIBUTE_COMPONENT()) == component;
70 }
71 return component == vtkArrayComponents::AllComponents;
72}
73
74// Set or unset the vtkDataObject::FIELD_ATTRIBUTE_COMPONENT() value of \a info.
75void setArrayComponentInfo(vtkInformation* info, int component)

Callers 1

Calls 2

HasMethod · 0.45
GetMethod · 0.45

Tested by

no test coverage detected