A prosecutor accused Bill Cosby of a "lifetime of sexual assault on young women," while defense lawyers ripped into the memories of his accusers at a key hearing that will decide who can testify at the comedian's trial this summer.

Prosecutors want to put 13 women on the stand to show a pattern of behavior by Cosby, who is charged with drugging and molesting Andrea Constand during an encounter at his Pennsylvania house in 2004.

Cosby denies any wrongdoing. His attorney, Brian McMonagle, argued that the women's claims are "ancient, remote, incredible, uncorroborated," dredged up by attorneys "who had the agenda of bringing down an American icon."

High-profile lawyer Gloria Allred, who represents many of the women, "duped" prosecutors into buying her clients' stories, another Cosby attorney, Angela Agrusa, argued in court.

The defense went through the women's accounts one by one, highlighting references to drugs or alcohol that was consumed, vagueness about dates or details, or continued contact with the TV star after alleged assaults, including one "20-year affair."

The arguments provided a preview of the tough cross-examination those witnesses could face if the judge lets them testify at the trial.

Related: Fireworks Erupt at Cosby Sexual Assault Hearing

In the case of one woman, defense lawyer Angela Agrusa noted that she could not remember if she was in her 20s or early 30s when Cosby allegedly assaulted her and admitted she was "into drugs.'

Agrusa zeroed in on the drug history of another woman, who has been sober for 19 years, and noted that a different accuser was photographed while pregnant in a sweatshirt Cosby gave her after the alleged assault.

Andrea Constand, who accuses Bill Cosby of sexually assaulting her, walks in a park in Toronto, December 30, 2015. MARK BLINCH / Reuters

Cosby's lawyers said that in some cases, the timeline of an incident was so fuzzy that it was impossible to defend it. One woman alleged being assaulted sometime in a three-year period in the 1980s.

"The only way you could have an alibi for that one is if you were in a coma for three years," McMonagle said.

He said the only similarity in the claims is that they were made after Constand's civil suit in 2005 or after the scandal exploded last year.

"Not one report to police," McMonagle said. "Pattern."

Prosecutors faulted Cosby's lawyers for attacking the credibility of the 13 women.

"This is 'Hey, let’s trash these victims,’” Montgomery County District Attorney Kevin Steele said.

Steele said common threads running through the women's accounts, which span decades, show Cosby acted with deliberation, and that the reason their memories aren't perfectly clear is because they were drugged.

"In each case, it’s a young woman," he said. "All of the victims met the defendant through her employment, he acted as a mentor to each of the victims. ... The defendant used his fame and notoriety to instill trust in the victims."

"In each case, he gives the victim an intoxicant," Steele added. “In many of the cases the victim refuses the drinks or pills.

"These intoxicants that are given to the victims are so powerful they become incapacitated," the DA continued. "None of these women consent to what he has done."

The accounts are so alike, Steele said, that "the proof of one tends to establish the proof of another."

"This is a lifetime of sexual assault on young women," he said.

Judge Steven O'Neill did not issue a ruling from the bench. When he does, legal experts say, his decision is likely to be the most important one of the case.