| 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 1177 of file renderer_unittests.cc.

## Constructor & Destructor Documentation

## ◆ CompareFunctionUIData()

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

Definition at line 1179 of file renderer_unittests.cc.

1179 {
1180 labels_.push_back("Never");
1181 functions_.push_back(CompareFunction::kNever);
1182 labels_.push_back("Always");
1183 functions_.push_back(CompareFunction::kAlways);
1184 labels_.push_back("Less");
1185 functions_.push_back(CompareFunction::kLess);
1186 labels_.push_back("Equal");
1187 functions_.push_back(CompareFunction::kEqual);
1188 labels_.push_back("LessEqual");
1189 functions_.push_back(CompareFunction::kLessEqual);
1190 labels_.push_back("Greater");
1191 functions_.push_back(CompareFunction::kGreater);
1192 labels_.push_back("NotEqual");
1193 functions_.push_back(CompareFunction::kNotEqual);
1194 labels_.push_back("GreaterEqual");
1195 functions_.push_back(CompareFunction::kGreaterEqual);
1196 assert(labels_.size() == functions_.size());
1197 }
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 1213 of file renderer_unittests.cc.

1213 { return functions_[index]; }

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

## ◆ IndexOf()

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

Definition at line 1203 of file renderer_unittests.cc.

1203 {
1204 for (size_t i = 0; i < functions_.size(); i++) {
1205 if (functions_[i] == func) {
1206 return i;
1207 }
1208 }
1209 FML_UNREACHABLE();
1210 return -1;
1211 }

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

## ◆ labels()

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

Definition at line 1199 of file renderer_unittests.cc.

1199 { return &labels_[0]; }

## ◆ size()

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

Definition at line 1201 of file renderer_unittests.cc.

1201 { return labels_.size(); }

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

- impeller/renderer/renderer_unittests.cc