Self abuse is a somewhat archaic term for masturbation.
There wasn't anything, at first.

There never had been, really. He wasn't that sort of man. There was work. There were his thoughts. And there was the occasional, surreptitious self-abuse in the dark, but he was human, after all.

And then, to his great surprise, there was a man. It seemed as though he'd only blinked, then opened his eyes, and there was Watson, talking and laughing and apologizing and kindly intruding upon Holmes's life.

So then there was a friend.

And then, striking like lightning, leaving iridescent impressions behind his eyelids - to Holmes's eternal consternation, there was love.