Rafael Martinez Jr., the now-former Camden County cop who had a sexual relationship and fathered a child with a girl when she was 15, was quiet at his sentencing Friday.

Judge Edward McBride accepted a negotiated plea to sentence Martinez to five years probation. As part of the agreement, Martinez pleaded to endangering the welfare of a child.

In mid-August 2017, the teen gave birth at Cooper University Hospital in Camden and was interviewed by a social worker there, according to court documents.

The girl told the social worker that Martinez, 33, was the father, which was later confirmed with DNA evidence.

Deputy First Assistant Prosecutor Grace MacAulay revealed that Martinez claimed he did not know the girl was underage, and that she told him she was 18.

"Saying the child told me she was 18, that is inexcusable and unacceptable for any person in our society, but especially for a law enforcement officer," MacAulay said. "They are held to a higher standard."

Deputy First Assistant Prosecutor Grace MacAulay and defense attorney Dan Rybeck at Martinez's sentencing. (Joe Warner | For NJ Advance Media)

Dan Rybeck said his client Martinez would like to be admitted to the County Supplemental Labor Service Program on weekends. According to the county website, offenders in this program report to the county correctional facility and receive an assignment that usually involves cleaning county parks or roads.

In sentencing Martinez, McBride noted that "his conduct is the result of circumstances that are unlikely to recur" and that the cop had no prior contact with the criminal justice system (besides being part of it).

Martinez was previously suspended without pay until the adjudication of his case, a police department spokesman said. He was required to forfeit his present employment on Friday.

Joe Brandt can be reached at jbrandt@njadvancemedia.com. Follow him on Twitter @JBrandt_NJ. Find NJ.com on Facebook.

Have a tip? Tell us. nj.com/tips