It is narrated from Sayyiduna Anas bin Malik (may Allah be pleased with him) that a woman asked the Messenger of Allah (peace and blessings be upon him) about a woman who sees in her sleep what a man sees. He (peace and blessings be upon him) said: "If what happens to a man happens to her, then she should perform ghusl."
Hadith Referenceالسنن الكبرى للبيهقي / كتاب الطهارة / 795