serialize and size()