If you're accused of using or selling drugs but didn't fight an arrest or get caught with a weapon, you'll likely be named a non-violent offender. That means that you have a better chance of avoiding traditional court and the penalties and punishments that a full trial could lead to.
A drug court is completely different than a traditional court, because it deals with non-violent drug-related offenses outside the traditional criminal justice prosecution tactics. The programs provide judicial oversight and monitoring while also aiming to get the drug offender substance abuse treatment and placing them on probation. That means that if you're struggling with drug abuse, instead of being put into prison or jail with other offenders, you may get the addiction treatment you need instead.
The goal of a drug court is generally to help the offenders increase the likelihood of rehabilitation and to reduce recidivism and substance abuse in offenders. Essentially, these courts want to help non-violent offenders get the drug treatment they need to stay sober and to potentially stay out of trouble in the future. This helps them become stronger members of society who cause less trouble in the long term for the police and courts.
In California, one benefit of drug court is that a pre-plea diversion program can allow any criminal trials to be suspended while the offender goes through drug treatment programs, counseling, drug testing, and other requirements. Once those requirements are met, the offender may find that the criminal charges they once faced have been dropped due to their work and success in rehabilitation programs.
Source: California Courts, "Drug Courts," accessed July 01, 2015