SAN FRANCISCO -- A man was detained in connection with a shooting Thursday in San Francisco's Outer Mission District that elicited a SWAT team response when he barricaded himself inside an RV.

The suspect, who has not been identified, was taken into custody about 8:30 a.m. after hostage negotiators talked him into leaving the trailer, San Francisco police Sgt. Danielle Newman said.

He is suspected of shooting a man about 3:10 a.m. on Farragut Avenue and then fleeing to the RV parked nearby at a business in the 2800 block of Alemany Boulevard, police said.

The shooting victim, a man in his 30s, was taken to San Francisco General Hospital and is expected to survive, Newman said. Police have not released a motive in the shooting.

Contact Rick Hurd at rhurd@bayareanewsgroup.com. Contact Erin Ivie at eivie@bayareanewsgroup.com