What does the quote First they came for the Jews mean?

That is the beginning of a popular quote by Martin Niemoller. Here is the full quote:

First they came for the communists, and I did not speak out--

because I was not a communist;

Then they came for the socialists, and I did not speak out--

because I was not a socialist;

Then they came for the trade unionists, and I did not speak out--

because I was not a trade unionist;

Then they came for the Jews, and I did not speak out--

because I was not a Jew;

Then they came for me--

and there was no one left to speak out for me.

There are many variations including these:

When the Nazis came for the communists, I said nothing; I was, of course, no communist.

When they locked up the Social Democrats, I said nothing; I was, of course, no Social Democrat.

When they came for the trade unionists, I said nothing; I was, of course, no trade unionist.

When they came for me, there was no one left who could protest.

And this:

"When Hitler attacked the Jews

I was not a Jew, therefore I was not concerned.

And when Hitler attacked the Catholics,

I was not a Catholic, and therefore, I was not concerned.

And when Hitler attacked the unions and the industrialists,

I was not a member of the unions and I was not concerned.

Then Hitler attacked me and the Protestant church --

and there was nobody left to be concerned."