} else if (obj instanceof Task) { return ITEM_TYPE_TASK; } else if (obj instanceof Asset) { return ITEM_TYPE_ASSET; } else if (obj instanceof Workflow) { return ITEM_TYPE_WORKFLOW; } else { return ITEM_TYPE_OTHER;
  private static int getItemType(Object obj) {    if (obj instanceof PlanElement) {      if (obj instanceof Allocation) {        return ITEM_TYPE_ALLOCATION;      } else if (obj instanceof Expansion) {        return ITEM_TYPE_EXPANSION;      } else if (obj instanceof Aggregation) {        return ITEM_TYPE_AGGREGATION;      } else if (obj instanceof Disposition) {        return ITEM_TYPE_DISPOSITION;      } else if (obj instanceof AssetTransfer) {        return ITEM_TYPE_ASSET_TRANSFER;      } else {        return ITEM_TYPE_OTHER;      }    } else if (obj instanceof Task) {      return ITEM_TYPE_TASK;    } else if (obj instanceof Asset) {      return ITEM_TYPE_ASSET;    } else if (obj instanceof Workflow) {      return ITEM_TYPE_WORKFLOW;    } else {      return ITEM_TYPE_OTHER;    }  }