NEW YORK (CBSNewYork/AP) — An NYPD officer was shot in the head late Saturday in Queens Village, Queens, and a suspect was later taken into custody.

Two 105th Precinct officers were in an unmarked squad car near 212th Street and 104th Avenue during the 6 p.m. hour, when they saw a man walking down the street and adjusting an object in his waistband, police Commissioner Bill Bratton said at a news conference.

Officers watched as the suspect walked south on 212th Street and turning down 104th Road, Bratton said. When they confronted him about what he was doing with his waistband, the man turned and shot one of the officers, Brian Moore, in the head as the officers sat in the squad car, Bratton said.

The other officer, Erik Jansen, radioed for assistance, and officers began canvassing the area, Bratton said. A suspect – identified by Bratton as Demetrius Blackwell, 35 – was arrested 90 minutes later in front of 104-25 212th Pl., Bratton said.

During the search, dozens of police officers, marked and unmarked cars, emergency service unit trucks, K9 units, and police helicopters flooded the scene in the Queens Village neighborhood, and officers could be seen searching house-by-house, looking in backyards, under cars and walking on top of roofs with their flashlights.

Some neighbors invited officers who were going door-to-door to check their backyards, garages and sheds for a gunman.

Officer Moore was rushed in a police cruiser to Jamaica Hospital Medical Center in Queens, the NYPD said. Police sources said Officer Moore was hit in the cheek with a fragment in his head.

Police continued to search late Saturday for the weapon involved and were using floodlights around hte neighborhood.

Surgeons would not speculate on Moore’s prognosis, but police said they are hopeful, CBS2’s Matt Kozar reported.

Officer Moore, 25, joined the force in July 2010 and lives on Long Island, Bratton said. His father and uncle are retired NYPD sergeants, and he also has a cousin on the job, Bratton said.

Officer Jansen 30 years old and joined the force in July 2011, Bratton said.

“Our hearts are with his family and loved ones. Our hearts are with his extended family and the men and women of the NYPD,” Mayor Bill de Blasio said at the news conference.

De Blasio said the shooting is “a reminder of the dangers that all of our officers face every single day.”

“It is a painful day for all of us. It is a painful day for all New Yorkers. It is a painful day for the NYPD,” de Blasio said.

Suspect Blackwell has an extensive arrest history, Bratton said. He has been arrested in the past for criminal possession of a weapon and robbery.

Police sources said Blackwell lives near the scene and worked at a tire shop in the area.

Demetrius Blackwell, 35, is apprehended in connection with a shooting that left an officer wounded in Queens Village, Queens. (Credit: NYPD)

Demetrius Blackwell, 35, is apprehended in connection with a shooting that left an officer wounded in Queens Village, Queens. (Credit: NYPD)

As CBS2’s Dave Carlin reported, neighbors near the scene of the shooting were surprised by the violence and described the area as quiet and safe. Barbara Jonas said she did not know what was happening when police swarmed the neighborhood.

“We were looking over here, and the police told us to get off the fence; do not go near, so we didn’t know what happened,” Jonas said. “I’m so sorry to know something like that happened. I’m so sorry for that family.”

“Why would somebody just do that? Why would somebody shoot somebody like that – an officer, you know what I mean?” added resident Michael Cofield. “That’s not going to help nobody.”

“Let’s keep him in prayer. Let’s keep us all in prayer,” a woman added, “because it’s just a terrible situation and time we’re living in.”

Indeed, everyone who spoke to 1010 WINS’ Gary Baumgarten was very upset by the shooting of the officer. One woman said she went to Facebook with a message.

“I said I pray for peace in the community,” she said.

The shooting, the fifth of an on-duty officer in as many months in New York, comes after two NYPD officers were shot and killed in Brooklyn.

Officers Wenjian Liu, 32, and Rafael Ramos, 40, were shot at close range as they were sitting in their patrol car Dec. 20 of last year in Bedford-Stuyvesant, Brooklyn. The suspect, 28-year-old Ismaaiyl Brinsley, then ran into a nearby subway station and fatally shot himself.

Before the ambush, Brinsley posted on an Instagram account that he was planning to shoot two “pigs” in retaliation for Garner’s death.

On Jan. 5, two plainclothes officers – Andrew Dossi, 30, and Alrio Pellerano, 38 — who were part of an anti-crime unit in the Fordham section of the Bronx were shot and wounded. Each officer survived two gunshot wounds.

Jason Polanco, 24, and Joshua Kemp, 28, were both indicted on charges of robbery, criminal possession of a weapon and criminal possession of stolen property in connection with the Bronx case.

(TM and © Copyright 2015 CBS Radio Inc. and its relevant subsidiaries. CBS RADIO and EYE Logo TM and Copyright 2015 CBS Broadcasting Inc. Used under license. All Rights Reserved. This material may not be published, broadcast, rewritten, or redistributed. The Associated Press contributed to this report.)