Context.h file Reference
Skittle Color Sorter

file Context.h

(Global Variables) This file is to provide access to some of the useful macros and global variables. This static class is the base class for all the components used in this project.


  • Calibrated Skittle's Colors. All the colors are defined here. This macro will later be used to populate some arrays by changing the COLOR_DEF to retrive only needed data.
  • This macro is retrive only the Identifier from the colors definition to generate the enum colorResult.
  • The size of the color list. This is also equal to the number of items in the enum colorResult.
  • A macro function to check if the result is a valid color.


  • colorResult
  • This type represents a color's result. Note it not only can be a valid Skittle's color, but it also can be some invalid values.