The head of the union that represents New York City police officers assailed local leaders Thursday for “holding back our police” moments after an officer was released from a hospital to a hero’s welcome after being shot three times the night before.