The following works for any type of dry bean (e.g., chickpeas, white beans, black-eyed peas, black beans, etc.). Cooking time may vary depending on the size/type of bean.
I prefer my beans al dente so they have a little bite/texture to them, unlike the mushy versions you find in bottled or canned beans. Once you try beans this way, you'll never go back to canned or bottled beans. They taste much better and are much cheaper.
Put the beans in a bowl at least 4 times the volume of the beans.
Add water up to about an inch or so below the rim.
Allow the beans to soak on the counter overnight (at least 6 hours)
Rinse the beans and place in a large pot.
Put the pot on the stovetop at medium heat and cook the beans for about an hour until they are al dente. After about 30 minutes, check the beans every 5 to 10 minutes (and skim the foam that accumulates) until al dente. The water should be simmering. You don't want it to boil.
Once cooked, rinse the beans and put in an ice bath to stop the cooking process.
After 10 minutes or so in the ice bath, drain in a colander and let sit to air dry.
Finish drying with a towel.
Use them in a recipe or store them for up to a week (depending on the type of bean).
To store, keep in a tupperware/rubbermaid container with a dry towel on the bottom.