if (((Object[]) valueToSubstract).length == 0) {
return null; //Special case. Using stringProperty-=, sets it to null.
} else { //Otherwise, occurrences of valueToSubstract are removed from the array
List list = new ArrayList();
list.addAll(Arrays.asList((Object[]) currentValue));
list.removeAll(Arrays.asList((Object[]) valueToSubstract));
return list.toArray((Object[]) getBaseArray(expectedClass.getComponentType(), list.size()));
}
} else if (expectedClass.equals(int.class)) {
return new Integer(((Integer) currentValue).intValue() - ((Integer) valueToSubstract).intValue());
} else if (expectedClass.equals(long.class)) {