Measurement of the resonant and CP components in (B)over-bar(0) -> J/psi pi(+)pi(-) decays