The dog's life was saved by the quick actions of Linda Tobin, a crossing guard who spotted the dog laying in the middle of the tracks during her early morning shift.
But when Tobin got closer to the dog, she realized it was still alive.
"And then we noticed it started growling and stuff so, it had the will to live, that's all I know," Tobin said.
With the help of a nearby resident, Tobin carried the dog away and called the sheriff's department.
Riverside County Animal Services had to amputate the terrier's leg, but she is expected to make a full recovery.
Veterinary technician Katherine Buff is nursing the dog back to health. Since she was found without tags, she'll be placed up for adoption in about six weeks. The timeframe is dependent on the amount of surgeries the dog requires, Buff said.
So, what is the dog's name? Animal services came up with an appropriate one, since she now has only three legs.
"We went ahead with Trinity," Buff said. "It was pretty and not cliché and everybody liked it, so Trinity it is."