Unlike the traditional association of the sun with hope, triumph, and glory, John Donne portrays the sun as an annoyance in "The Sun Rising." His main method of doing so is personification. Personification is when a writer gives human qualities to a nonhuman, like an animal or abstract concept.
Here, the sun is characterized as a puritanical killjoy. The speaker is chiding the sun for rising, since with the coming of dawn, he and his lover have to leave their bed. The speaker demands that the sun go bother other people:
Saucy pedantic wretch, go chide
Late school boys and sour prentices,
Go tell court huntsmen that the king will ride,
Call country ants to harvest offices.
The speaker's use of the adjective pedantic as well as the evocation of schoolchildren and apprentices paint the sun as a kind of schoolmarm figure: severe, punishing, and irritating. The reference to courtiers beholden to a king or ants beholden to their duty to the colony also present the sun as a force of obligation. It is as though the sun is nagging people into going to their jobs.
The speaker also paints the sun as self-important:
Thy beams, so reverend and strong
Why shouldst thou think?
I could eclipse and cloud them with a wink.
He is mocking the sun's light by saying it can be extinguished so long as he closes his eyes! Here, the sun takes on the aspect of a blustering tyrant, unable to rouse the speaker from his bed.
The speaker presents himself and his lover as the sun's opposite. Unlike the sun, which in this context represents order and duty, love is something that "no season knows nor clime, / Nor hours, days, months, which are the rags of time." This conception of love as above all else turns the lovers into romantic, rebellious figures and the speaker into a hero who defies societal expectation (represented by the sun) to spend more time with his beloved. Instead of obeying the sun, the speaker demands the sun serve the lovers by keeping their bed warm and then requiring nothing more of them. The poem ends with the sense that the speaker regards the sun as little more than a pesky fly, shooing it away contemptuously.