Forcing Google to host content against their will is pretty close. I guess in this case it's better than nationalizing though, Google has to pay for the hosting, and you get to tell Google they're not allowed to delete videos.
No one is holding a gun to YouTube’s head and telling them they have to serve video content to Germans. They want to be in Germany serving video content, so it’s only fair and just that they should listen to the Germans and do what they say or leave.
Germany could probably tell Google not to host any videos from the opposition political party under penalty of fine or expulsion. Hopefully we agree that that would be bad?
We can agree that bad things are bad, but that doesn’t really gives us much insight.
It is entirely possible for countries to do things which are against their constitution.
If they want to diminish the impact legally and profitably, they can just drown it in in more intrusive ads.