Fixed for null values(Issue reported by Deepak).
Now generated classes have wrapper classes instead of primitives...Integer instead of int.