Measurement of branching fractions and charge asymmetries for exclusive B decays to charmonium