To be more precise, for example in XI/XII century. Did common peasants, or lower rank nobles ever get to eat cake or some kind of candy, or was it solely king's delicacy?
Sweet confections were quite rare especially in the Xth and XIth centuries, hard to get by and expensive : on the other hand sweet fruits (especially raisins and figs) and honey were comparatively more easily accessible and widespread in Mediterranean Europe (Christian as Islamic)
Sugar cane was a rarity in Europe at this point, even in al-Andalus (although definitely less so in Islamic Sicily).
Fruits juices were used as sweet drinks or sweet ingredients for mixed drinks or sweetening meals. Fruits could be as well used to producing must, such as arrope or petimezi for a similar use.
Pastries and confections were more readily available for upper classes, especially around towns where such a trade was common enough : nougats, beignets, honeyed pastries, etc. It was still fairly rarer than in later centuries, especially before Crusades where a good part of the nobility couldn't afford or even know about it.