vznet/mongo-jackson-mapper — pull request #21 by daymien (2012-07-03 23:18:33+00:00)
Title: Fixed - ClassCastException for generic array cast (T[])

Fixed - ClassCastException `(T[]) new Object[dbObjects.length]` because generic Array cast `T[]` isn't possible. Use `List` instead.

This exception occurs only if array is used outside:
```java
...
WriteResult result = coll.insert(new MockObject("A", "a", 1), new MockObject("B", "b", 2));
assertThat(result.getSavedIds()[0], equalTo("A"));
assertThat(result.getSavedIds()[0], equalTo("B"));
...
```