How can I determine if a property is a kind of array.
Example:
public bool IsPropertyAnArray(PropertyInfo property) { // return true if type is I
Excluding String class as it qualifies as a collection because it implements IEnumerable.
String
IEnumerable
public bool IsPropertyACollection(this PropertyInfo property) { return (!typeof(String).Equals(property.PropertyType) && typeof(IEnumerable).IsAssignableFrom(property.PropertyType)); }