// get data object id associated to this node (if any)
if (((TCatchEvent) flowNodeJaxb).getDataOutputAssociation().size() > 0) {
// TODO: only one data object supported, see redmine #96 (minor
// task)
TDataObjectReference dataObjectReferenceJaxb = (TDataObjectReference) ((TCatchEvent) flowNodeJaxb)
.getDataOutputAssociation().get(0).getTargetRef();
TDataObject dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAOUTPUTOBJECTID, dataObjectJaxb.getId());
}
return objectIds;
// node is throwing event
} else if (flowNodeJaxb.getClass().getSuperclass()
.equals(TThrowEvent.class)) {
// get data object id associated to this node (if any)
if (((TThrowEvent) flowNodeJaxb).getDataInputAssociation().size() > 0) {
// TODO: only one data object supported, see redmine #96 (minor
// task)
TDataObjectReference dataObjectReferenceJaxb = (TDataObjectReference) ((TThrowEvent) flowNodeJaxb)
.getDataInputAssociation().get(0).getTargetRef();
TDataObject dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAINPUTOBJECTID, dataObjectJaxb.getId());
}
return objectIds;
// node is a task
} else if (flowNodeJaxb.getClass().getSuperclass().equals(TTask.class)) {
// get data object id associated to this node (if any)
if (((TTask) flowNodeJaxb).getDataInputAssociation().size() > 0
|| ((TTask) flowNodeJaxb).getDataOutputAssociation().size() > 0) {
// TODO: only one data object supported, see redmine #96 (minor
// task)
// every task must be handled in its special way
if (flowNodeJaxb.getClass().equals(TReceiveTask.class)) {
TDataObjectReference dataObjectReferenceJaxb = (TDataObjectReference) ((TReceiveTask) flowNodeJaxb)
.getDataOutputAssociation().get(0).getTargetRef();
TDataObject dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAOUTPUTOBJECTID, dataObjectJaxb.getId());
} else if (flowNodeJaxb.getClass().equals(TSendTask.class)) {
TDataObjectReference dataObjectReferenceJaxb = (TDataObjectReference) ((TSendTask) flowNodeJaxb)
.getDataInputAssociation().get(0).getTargetRef();
TDataObject dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAINPUTOBJECTID, dataObjectJaxb.getId());
}
if (flowNodeJaxb.getClass().equals(TServiceTask.class)) {
TDataObjectReference dataObjectReferenceJaxb = (TDataObjectReference) ((TServiceTask) flowNodeJaxb)
.getDataOutputAssociation().get(0).getTargetRef();
TDataObject dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAOUTPUTOBJECTID, dataObjectJaxb.getId());
dataObjectReferenceJaxb = (TDataObjectReference) ((TServiceTask) flowNodeJaxb)
.getDataInputAssociation().get(0).getTargetRef();
dataObjectJaxb = (TDataObject) dataObjectReferenceJaxb
.getDataObjectRef();
objectIds.put(DATAINPUTOBJECTID, dataObjectJaxb.getId());
}
}
return objectIds;