code: private static List<Object> mergeReferenceValues(AttributeDefinition attrDef, Object... values) {
          List<Object> merged = new ArrayList<Object>();
          for (Object value : values) {
              if (value instanceof String) {
                  merged.addAll(getAsList((String) value, attrDef));
              } else if (value instanceof List<?>) {
                  for (Object ce : (List<?>) value) {
                      if (ce instanceof ConfigElement) {
                          // Get the ID for this ConfigElement. If it's specified, remove the ID from the merged list.
                          // This gets rid of ref attributes that point to a nested element
                          String id = (String) ((ConfigElement) ce).getAttribute("id");
                          if (id != null) {
                              merged.remove(id);
                          }
                          merged.add(ce);
                      } else if (ce instanceof ConfigElement.Reference) {
                          merged.add(ce);
                      } else if (ce instanceof String) {
                          if (!merged.contains(ce))
                              merged.add(ce);
                      }
                  }
  
              }
          }
  
          return merged;
      }
docs: /*
  Only called when ibm:type=pid and cardinality != 0