An end of life directive specifies that you don't want life extending medical care if you'll have no quality of life.
Do doctors actually obey end of life directives if you attempt suicide?
It depends on a lot of things, especially your jurisdiction. If you're serious about these kinds of questions, you can do some research and/or get an estate attorney do do up your documents and ask him these kinds of questions. (I did, and no one looked at me funny for being a physically healthy 30-something getting a will and estate planning documents done up... that made it seem like a waste to come up with a cover story about stage 4 pancreatic cancer and do a bunch of research on that, but whatever.)
Where I live, some hospitals (mostly the ones run by religious organizations) won't honor a DNR (do not resuccitate) directive under any circumstance, and I'm told paramedics are the same way. Even if I have my DNR pinned to my chest, paramedics have to attempt to revive me, and the religous-based hospitals will ignore it. There are also legal limits to what conditions medical care can legally be withheld for - if I'm braindead (persistent vegetative state), they can legally take me off artificial life support, if I'm comatose, they can legally remove or withhold IV nutrition and feeding tubes, but, if I slice open an artery and say "let me bleed out", medical staff are legally prohibited from listening to me. The approximate standard around here is two doctors agreeing that the patient is in a permanent comatose or vegetative state before life-sustaining artificial care can be withheld.
And it gets worse. My "living will" is not legally binding, it merely informs the person who holds my medical power of attorney about my wishes. So, even though I have a DNR and a living will stating I do not wish to be kept alive by artificial means, the executor of my estate (who is a close relative) can, and probably would, keep me on life support forever if I eff up my attempt and end up a vegetable. So, I better get it right.
The legal situation varies wildly from country to country and even inside some countries (different states or provinces often have different rules), so you'll want to do your own research and consult a qualified lawyer in your jurisdiction if it matters to you, but as a general rule, anything resembling a right to die is rare and usually pretty weak where it exists at all. (Otherwise we wouldn't need this forum, would we?)