The first scene of act 1 in The Importance of Being Earnest opens with the lines:
ALGERNON: Did you hear what I was playing, Lane?
LANE: I didn’t think it polite to listen, sir.
This sets the tone for the rest of the dialogue between master and servant. Wilde critiques the relations between the upper classes and the servant class, showing Lane to be more astute and intelligent than his master. He also critiques the absurdly rigid and arbitrary code of etiquette that prevailed in Victorian England.
The humor, as is often the case with Wilde, comes from taking a convention and exaggerating it to the point where it is obviously ludicrous. It is regarded as impolite to listen to private conversations, but Lane takes this rule to the extreme lengths of refusing to listen to his master playing the piano. However, it becomes clear later in the scene that Lane's scruples do not prevent him from stealing. When asked why the servants in bachelor establishments drink the champagne, he replies drily:
I attribute it to the superior quality of the wine, sir. I have often observed that in married households the champagne is rarely of a first-rate brand.
Throughout the scene, one of the chief ironies is that Lane and Algernon are both so scrupulous in matters of etiquette, without observing the commonest rules of morality.