| Flutter Impeller |

Public Member Functions | List of all members
impeller::testing::CompareFunctionUIData Class Reference

## Public Member Functions
| CompareFunctionUIData ()
const char *const * | labels () const
int | size () const
int | IndexOf (CompareFunction func) const
CompareFunction | FunctionOf (int index) const

## Detailed Description

Definition at line 1163 of file renderer_unittests.cc.

## Constructor & Destructor Documentation

## ◆ CompareFunctionUIData()

impeller::testing::CompareFunctionUIData::CompareFunctionUIData | ( |  | ) |
| inline

Definition at line 1165 of file renderer_unittests.cc.

1165 {
1166 labels_.push_back("Never");
1167 functions_.push_back(CompareFunction::kNever);
1168 labels_.push_back("Always");
1169 functions_.push_back(CompareFunction::kAlways);
1170 labels_.push_back("Less");
1171 functions_.push_back(CompareFunction::kLess);
1172 labels_.push_back("Equal");
1173 functions_.push_back(CompareFunction::kEqual);
1174 labels_.push_back("LessEqual");
1175 functions_.push_back(CompareFunction::kLessEqual);
1176 labels_.push_back("Greater");
1177 functions_.push_back(CompareFunction::kGreater);
1178 labels_.push_back("NotEqual");
1179 functions_.push_back(CompareFunction::kNotEqual);
1180 labels_.push_back("GreaterEqual");
1181 functions_.push_back(CompareFunction::kGreaterEqual);
1182 assert(labels_.size() == functions_.size());
1183 }
impeller::CompareFunction::kEqual
@ kEqual
Comparison test passes if new_value == current_value.
impeller::CompareFunction::kLessEqual
@ kLessEqual
Comparison test passes if new_value <= current_value.
impeller::CompareFunction::kGreaterEqual
@ kGreaterEqual
Comparison test passes if new_value >= current_value.
impeller::CompareFunction::kAlways
@ kAlways
Comparison test passes always passes.
impeller::CompareFunction::kLess
@ kLess
Comparison test passes if new_value < current_value.
impeller::CompareFunction::kGreater
@ kGreater
Comparison test passes if new_value > current_value.
impeller::CompareFunction::kNotEqual
@ kNotEqual
Comparison test passes if new_value != current_value.
impeller::CompareFunction::kNever
@ kNever
Comparison test never passes.

References impeller::kAlways, impeller::kEqual, impeller::kGreater, impeller::kGreaterEqual, impeller::kLess, impeller::kLessEqual, impeller::kNever, and impeller::kNotEqual.

## Member Function Documentation

## ◆ FunctionOf()

CompareFunction impeller::testing::CompareFunctionUIData::FunctionOf | ( | int | index | ) | const
| inline

Definition at line 1199 of file renderer_unittests.cc.

1199 { return functions_[index]; }

Referenced by impeller::testing::TEST_P().

## ◆ IndexOf()

int impeller::testing::CompareFunctionUIData::IndexOf | ( | CompareFunction | func | ) | const
| inline

Definition at line 1189 of file renderer_unittests.cc.

1189 {
1190 for (size_t i = 0; i < functions_.size(); i++) {
1191 if (functions_[i] == func) {
1192 return i;
1193 }
1194 }
1195 FML_UNREACHABLE();
1196 return -1;
1197 }

Referenced by impeller::testing::TEST_P().

## ◆ labels()

const char* const* impeller::testing::CompareFunctionUIData::labels | ( |  | ) | const
| inline

Definition at line 1185 of file renderer_unittests.cc.

1185 { return &labels_[0]; }

## ◆ size()

int impeller::testing::CompareFunctionUIData::size | ( |  | ) | const
| inline

Definition at line 1187 of file renderer_unittests.cc.

1187 { return labels_.size(); }

The documentation for this class was generated from the following file:

- impeller/renderer/renderer_unittests.cc