added support for array of object. primitive array are not working yet.