One, If you want better, more consistent brake performance in all conditions and don't really care if it weighs a little more or costs a little more, choose disc brakes over rim brakes.
Two, if you want the lightest set-up you can have, and are willing to accept small variances in brake performance, or if a low price is really important, choose rim brakes over disc brakes.
In a little more detail. Mountain bike rim brakes have gone through several design changes over the years. They started with the original cantilever brakes, went through the dark U-Brake years, and are now known as V-Brakes. V-Brakes work well in most conditions.
Rim brakes have some drawbacks. They require straight un-damaged rims to perform their best. Rim brakes perform poorly in wet or muddy conditions. Over time, Rim brakes can wear right through the side of your rim literally causing the side of the rim to blow off (I've seen this happen and its not pretty.).
Disc brakes have been around for a long time in cars but weren't seriously used on bikes until the mid to late 90's. There were definitely some issues with some of the earlier models but the disc brakes of today, cable actuated or hydraulic, perform quite well.
The performance of disc brakes is considerably better than rim brakes. Especially in wet or muddy conditions. Disc brakes usually require less force to apply and aren't effected by rim/wheel condition.
The biggest downside to disc brakes is the added weight. By the time you add everything in, including front and rear brakes and the added weight of the disc specific hubs, you end up with around 150 to 350 grams additional weight to the whole bike. This weight number greatly depends on the wheels, rims, hubs, and disc brake system you choose.
Cost is certainly an issue as well. Disk brake systems are usually more expensive compared to rim brakes. Mechanical or cable actuated disc brakes are a closer match but will still cost a little more. Hydraulic disc brake systems can cost significantly more.
To switch from one system to the other you will in most cases not only have to buy the new set of brakes but you will have to buy a new wheelset as well. Disc rims usually cannot be used with rim brakes and the standard hubs that are used with rim brake wheels usually cannot be used with discs.
The trend in the industry is certainly towards discs and the technoloy is improving every year.
Personally, I will never go back to rim brakes on my own bike. For me, the consistent performance and non-rim-dependent nature of discs is well worth the added weight.