Dear was taken into custody at 4:52 p.m., and a law enforcement official briefed on the investigation said he immediately began discussing his motivations with investigators.

The gunman told the officers who arrested him “no more baby parts,’’ after being taken into custody, according to a law enforcement official.

The attack on the clinic was “definitely politically motivated,’’ the official — who has been briefed on the investigation and spoke on condition of anonymity because it is still unfolding — told The Washington Post.

NBC News, which first reported the comment attributed to suspect Robert Lewis Dear, said Dear also mentioned President Obama.