You don't drink coffee, you drink caffeine, which is what I was saying, the drug isn't coffee but a component of it and it is shared by all of the caffeinated drinks (as much as the definition of caffeinated presupposes caffeine.)
You might be thinking of methadone which is similar in structure to heroin and is sometimes used to reduce dependency on it due to the way high doses of it result in reduced heroin effects, (as well as being similar to morphine making it an analgesic).