Inferring astrophysical parameters of core-collapse supernovae from their gravitational-wave emission