//List<BuildStatus> configuredBuildStatiMatches = new ArrayList<BuildStatus>();
BuildStatus[] result = new BuildStatus[projects.size()];
Iterator<IProject> projectIter = projects.iterator();
// this iteration is done is a bit different than usual...
for (int i = 0; projectIter.hasNext(); i++) {
IProject pro = projectIter.next();
try {
IProjectState proState = pro.obtainProjectState();
// use the iteration index to fil the result array
result[i] = proState.getProjectColor();
} catch (NullPointerException npe){
// in case the project state could not be determined
return StatusAction.OFF;