support serializing arrays