Information-theoretical interpretation of level populations and charge distribution in beam-foil spectroscopy