In short and plain terms, rehabilitation basically means the path to restore a criminal to a useful existence in society. This path is often paved with hundreds of hours of therapy, pertinent education and more.
To truly restore a perpetrator to good condition so he or she can operate efficiently in the real world again requires time and a lot of analysis. The right decisions need to be made from the start with regards to the proposed rehab plan. The main assumption made by the advocates of rehabilitation is that a person is not criminally inclined for life, and that it just takes the right process or processes to straighten out the mind of the convicted person.
The main purpose of rehab, then, is to prevent the recurrence of a crime that has previously been committed. This prevention of habitual offending is the cure that is likely to allow the state in which the convict is situated to present the man or woman back to society with a confident outlook. Being able to once again contribute to himself or herself as well as the greater society is the achievement that is to be expected (or at least hoped for) after lengthy rehabilitation schedules.
Where does punishment fit into all this? There are two schools of thought on this note. The first is that certain punishment, such as community service, probation orders and any other forms of punishment are complementary to the rehab plans ordered by the court and sanctioned by the state.
The other side of the coin is the exact opposite. It could actually be bad for the convicted person to be subjected to a lengthy jail term that is much longer than the schedule for rehab. Think about it - the likelihood of a prisoner coming out of a penitentiary after 15 years in confinement with rosy cheeks and a smile on his face is pretty slim, isn't it? More likely, he has it in for society now, no longer being on the same wavelength as the people in the real world he left behind many years ago. This is the danger of long prison terms for non-violent crimes. For violent offenders, the longer the jail time the better - at least this is how many people see it.
For more information on rehabilitation law, check your local library for your city's past criminal cases and the resultant jail terms and rehab schedules. This will be the best resource to understand the law in your local area.