It's not always necessary to create a special environment to get your fish to reproduce. Some, such as guppies, platys, and swordtails, will breed in almost any setup, including community tanks. As long as the fish you're trying to breed don't require specialized spawning conditions (such as a higher- or lower-than-normal temperature) that would clash with the needs of their tankmates, you can simply leave them in your community tank and let them do what comes naturally.
You may need to add specific items, however, such as a spawning grate or extra plants, to encourage the fish to breed or to prevent the fry from being cannibalized by tankmates or their own parents. Alternatively, if you're breeding livebearers and are present when the fry are born, you can catch and transfer them to a rearing tank.
Pros: Your breeding pairs aren't stressed by being netted and transferred to another tank; in addition, you don't have to go to the time and expense of setting up and maintaining another tank. If you simply want the fun of breeding a few fish once in a while, this setup might be a good one for you. It works particularly well for livebearers and other easy-to-breed species such as Zebra Danios, as long as you have a way to protect the eggs and/or fry. In addition, mouthbrooders are sometimes bred in community settings, since they hold on to their fry until they're big enough to survive on their own.
Cons: You'll have far fewer surviving fry-in some cases, only a couple-since other fish in your tank will consider both eggs and fry to be tasty tidbits. (In fact, when a livebearing fish goes into labor, tankmates often cluster around her, waiting for fry to emerge so they can gobble them up.) You can save most of the babies by putting the female in a breeding trap shortly before she delivers. Providing a thicket of real or silk plants or even floating plastic plants will also enable some of the fry to hide from their tankmates, but many of them may inevitably be eaten anyway, so you should check the tank daily for fry and remove them to a rearing tank for their own safety. In a community setting with several males and females of the same species, you'll have less control over which fish mate with one another, so if you're trying to selectively breed fish to emphasize certain traits, such as color or fin shape, then the community-tank approach isn't for you.