Arguably the most famous phrase in the English language, used, and abused, almost since the moment
The Bard composed them.
Hamlet is the archetypal intellectual: he is unable to do, only to be. In so many ways, this soliloquy sums up the drama of the play.
Hamlet is caught between the cycles, and waves of a tradition that requires him to avenge the murder of his father--who has no name--by his Uncle Claudius. This is represented by the low, menacing repetition of "Remember Me," beneath the floor boards by the ghost of Hamlet, Sr., for lack of a better name.
The duration of the play is the duration of Hamlet's deliberation, as a good university student, and intellectual. This is the "not to be".
Ultimately, he succumbs to the tides of history--this is the "to be".
Clearly, the reason this play, if not most of Shakespeare is not popular, and is considered boring--how many people think, or think enough to fight what instinct, and eveyone around them, tells them what to be?