Updated

Police announced Friday they caught a federal officer wanted in connection with three shootings in Maryland that killed a total of three people, including his estranged wife, ending a hunt that left many people in the suburbs of Washington, DC on edge.

Officers arrested 62-year-old Eulalio Tordil, who was wanted on a first-degree murder charge, after they spotted him in his car in an Aspen Hill parking lot. Investigators said Tordil, an officer working for the Federal Protective Service, shot and killed his wife, a chemistry teacher, outside their children's school in Beltsville Thursday.

tordil custody 56b

(Fox 5)

Then on Friday morning, two more shootings unfolded -- one at a mall parking lot in Bethesda, and one outside a supermarket in Aspen Hill roughly 30 minutes later. Police said they had "reason to believe" Tordil was the gunman in those shootings as well. They also warned he'd threatened to "commit suicide by cop."

Tordil ate lunch "calmly" at a Boston Market in Aspen Hill for about an hour after the Friday shootings, a witness told WJLA. Police said they had him under surveillance and caught him in his car after he left a Dunkin' Donuts not far from the supermarket shooting scene. TV news cameras showed him walking out of the car with his hands up.

Initially, one person was shot outside Westfield Montgomery Mall after some kind of confrontation, Montgomery County Assistant Police Chief Darryl McSwain said. He added that two others were shot after they rushed to the first person's aid. Paramedics rushed the three people shot -- two men and one woman -- to nearby Surburban Hospital, which briefly went on lockdown.

One of the men died in the hospital. The other man was in critical condition, and police said they expected the woman who was shot to survive.

The shooting near the Giant Food supermarket in Aspen Hill left one woman dead. Investigators said it was unclear whether the suspect knew any of the people shot on Friday. "It's tragic we were not able to intervene before other individuals were harmed," Prince George's County Police Chief Hank Stawinski told reporters.

Police said Eulalio Tordil followed his wife, 44-year-old Gladys Tordil, to High Point High School and shot her Thursday, also wounding a man who tried to intervene. Officials said the bystander had injuries that were not life-threatening.

Gladys Tordil had filed a protective order against her husband in March, claiming he abused one of her children and forced others to endure "intense-military-like discipline" including detention in a dark closet, The Washington Post reported. The wife also reportedly accused her husband of slapping her so hard that her glasses broke on her face, saying he kept as many as five guns at home.

The Federal Protective Service said it put the officer on administrative duties after a civil court issued that protective order. His duty weapon, badge, and credentials were taken. He was subsequently placed on administrative leave.

The Federal Protective Service provides security at federal properties.

A witness at the mall, Jose Mauricio Gomez, told the Post he heard six to eight shots. He said an officer rushed to the woman who was wounded. “That’s when blood shot out of the hole in her shoulder and he sat her back down.”

Police closed off large parts of the mall's parking lot, with clothing and other debris strewn on the ground outside the Macy's there.

All Montgomery County schools and recreation centers went on lockdown for part of the day, Fox 5 reported. However, some parts of the mall remained open.

The grocery store in Aspen Hill is a few hundred feet from a Michaels craft store that was first target by D.C. sniper John Allen Muhammad in 2002. Muhammad's shot into the store did not hit anyone, but he killed a man about a mile away less than an hour later, kicking off a three-week killing spree that left 10 dead.

Fox News' Jake Gibson and The Associated Press contributed to this report.

Click for more from Fox 5.