Approximate Bayesian computation via the energy statistic