The legal process differs greatly depending upon whether you were charged with a felony, misdemeanor, or an infraction. It's good to be aware of the differences between the three categories.
The definition of a felony means that punishment for the offense is, at a minimum, one year of confinement. Whether you face a sentence of more than a year in custody traditionally meant the difference between serving a sentence in state prison versus local county jail. In other words, if the crime you were convicted of required more than 1 year custody, that meant you were going to state prison; conversely, if you were punished for a crime that prescribed less than a year's worth of confinement, you would serve your sentence locally in county jail.
Very frequently I hear folks refer to jail as prison and prison as jail. It's not a big deal, but if you want to be technically correct about it, understand that prison (aka state prison) only applies for serious felonies where punishment comes in the form of years, not days or months. As a simple and generic reminder:
felonies = state prison; misdemeanors = local jail.
However, due to MAJOR legislative changes in the last five years, punishment for felonies no longer means necessarily confinement in state prison. In a nutshell, folks aren't getting sent to state prison generally unless they committed a serious or violent felony. In fact, many convicted felons now serve their sentences in local jail. Though serving in local jail, the time technically counts as "prison" time, which is why these punishments are often referred to as "local prison" (and a variety of other names). So, for example, someone convicted of selling cocaine (a violation of Health and Safety Code section 11351), which is a felony, would serve his sentence locally in county jail rather than state prison because this particular offense is not considered serious or violent. Now that folks can serve sentences of more than a year in county jail, it complicates matters. It's a significant and controversial shift. County jails get packed, local resources can get strained, and county probation officers assume state parole duties. Also, county jails house a much rougher crowd these days.
So, to slightly modify my previous reminder for you to use when figuring out whether to say prison or jail correctly in a sentence, go with this generalization:
serious or violent felonies = state prison; everything else = local jail.
Misdemeanors, by definition, mean any offense where the punishment is 364 days or less in local jail. In other words, if the maximum punishment is more than a year, it cannot by law be a misdemeanor. As you've now learned, that means jail, not prison. Again, generally, you only go to prison (state or "local prison") by committing serious or violent felonies.
Lastly, infractions are offenses that are punished by fines only; no jail time is permitted. A speeding ticket is the classic example of an infraction. So, if a run a stop sign, assuming you didn't hit anyone in the process, you can breathe easy; you won't be getting locked up. At worst you're facing a fine.