added the preliminary (and C-ported) asSerialCollection class