Better ArrayCollection encoding