for (Object instance : instances) {
individualTwo = (RDFIndividual) instance;
String stateName = individualTwo.getBrowserText();
/* case 1: booleans states */
if (stateName.equals("true")) {
StateLink link = domainResidentNode
.addPossibleValueLink(getMebn()
.getBooleanStatesEntityContainer()
.getTrueStateEntity());
List<String> globallyObjects = getMapBooleanStateGloballyObjects()
.get("true");
if (globallyObjects.contains(domainResidentNode
.getName())) {
link.setGloballyExclusive(true);
} else {
link.setGloballyExclusive(false);
}
domainResidentNode
.setTypeOfStates(IResidentNode.BOOLEAN_RV_STATES);
} else {
if (stateName.equals("false")) {
StateLink link = domainResidentNode
.addPossibleValueLink(getMebn()
.getBooleanStatesEntityContainer()
.getFalseStateEntity());
List<String> globallyObjects = getMapBooleanStateGloballyObjects()
.get("false");
if (globallyObjects.contains(domainResidentNode
.getName())) {
link.setGloballyExclusive(true);
} else {
link.setGloballyExclusive(false);
}
domainResidentNode
.setTypeOfStates(IResidentNode.BOOLEAN_RV_STATES);
} else {
if (stateName.equals("absurd")) {
StateLink link = domainResidentNode
.addPossibleValueLink(getMebn()
.getBooleanStatesEntityContainer()
.getAbsurdStateEntity());
List<String> globallyObjects = getMapBooleanStateGloballyObjects()
.get("absurd");
if (globallyObjects.contains(domainResidentNode
.getName())) {
link.setGloballyExclusive(true);
} else {
link.setGloballyExclusive(false);
}
domainResidentNode
.setTypeOfStates(IResidentNode.BOOLEAN_RV_STATES);
} else {
if (getMapTypes().get(stateName) != null) {
/* case 2:object entities */
StateLink link = domainResidentNode
.addPossibleValueLink(getMapTypes()
.get(stateName));
domainResidentNode
.setTypeOfStates(IResidentNode.OBJECT_ENTITY);
} else {
/* case 3: categorical states */
try {
state = getMebn()
.getCategoricalStatesEntityContainer()
.getCategoricalState(
individualTwo
.getBrowserText());
StateLink link = domainResidentNode
.addPossibleValueLink(state);
List<String> globallyObjects = getMapCategoricalStateGloballyObjects()
.get(state.getName());
if (globallyObjects
.contains(domainResidentNode
.getName())) {
link.setGloballyExclusive(true);
} else {
link.setGloballyExclusive(false);
}
domainResidentNode
.setTypeOfStates(IResidentNode.CATEGORY_RV_STATES);
} catch (CategoricalStateDoesNotExistException e) {
// TODO Auto-generated catch block