Iterator<ISelector> psi = parent.getShowProperties().iterator();
while (psi.hasNext()) {
ISelector check = psi.next();
if (check.canSelect(in, r.getParent().getOrigin(), r.getOrigin())) {
if (check instanceof PropertyDescription) {
PropertyDescription pd = (PropertyDescription) check;
if (pd.isGroupUse()) {
// pick which format to use...
Group groupFormats = (Group) pd.getUse();
Iterator<Format> fi = groupFormats.getFormats().iterator();
while (fi.hasNext()) {
Format potential = fi.next();
for (Iterator<ISelector> di = potential.getDomainSet().iterator(); di.hasNext(); ) {
ISelector potentialCheck = di.next();
if (potentialCheck.canSelect(getModel(), r.getParent().getOrigin(), r.getOrigin())) {
format = potential;
break;
}
}
}
} else {
if (null != pd.getUse()) {
format = (Format) pd.getUse();
break;
}
}
}
}