A Dedham man was sentenced Tuesday to nine years in prison with all but four years suspended for inflicting serious, permanent injuries on a 2-year-old in May 2020.

Jason T. Brown, 24, pleaded guilty to Class A aggravated assault on a child under the age of 6 just before he was sentenced, according to the Penobscot County District Attorney’s office.

In addition to prison time, Brown was sentenced to 5½ years of probation. If he were to violate the terms of his probation, Brown could be sent back to prison for up to five years. He also was ordered to pay more than $3,000 in restitution.

The sentence was the result of a plea agreement, according to Assistant District Attorney Joanne Lewis, who prosecuted the case. In exchange for Brown’s guilty plea, a Class B aggravated assault charge was dismissed, she said Wednesday.

Brown had no prior criminal history.

Defense attorney Jeffrey Silverstein of Bangor said Wednesday that Brown wanted to “spare all involved the stress of a trial” and was pleased the case had been resolved.

“The incident was unfortunate in so far as he did not mean to cause the injuries he did,” Silverstein said. “He accepted responsibility and demonstrated sufficient remorse before the court that the [judge] accepted the parties’ joint sentence recommendation.”

Brown, who is not related to the victim, was living with her mother in Orrington when the injuries were inflicted, according to Lewis.

Brown inflicted a “catastrophic head injury” that left the child “with permanent physical, intellectual and behavioral deficits, visual dysfunction, serious mobility dysfunction, and cognitive dysfunction,” the prosecutor said.

The child “presented with a constellation of injuries indicative of battered child syndrome including both old and new extensive bruising, significant intracranial trauma, a broken arm and evidence of prior adult bites,” Lewis said.

Brown, who remains free on bail, was ordered to begin serving his sentence on Jan. 28, according to Lewis.