Metonymy and synecdoche
Synecdoche, wherein a specific part of something is used to refer to the whole, is usually understood as a specific kind of metonymy. Sometimes, however, people make an absolute distinction between a metonym and a synecdoche, treating metonymy as different from rather than inclusive of synecdoche. There is a similar problem with the usage of simile and metaphor.
When the distinction is made, it is the following: when A is used to refer to B, it is a synecdoche if A is a component of B and a metonym if A is commonly associated with B but not actually part of its whole.
Thus, "The White House said" would be a metonym for the president and his staff, because the White House (A) is not part of the president or his staff (B) but is closely associated with them. On the other hand, "20,000 hungry mouths to feed" is a synecdoche because mouths (A) are a part of the people (B) actually referred to.
One example of a single sentence that displays synecdoche, metaphor, and metonymy is: "Fifty keels ploughed the deep", where "keels" is the synecdoche as it names the whole (the ship) after a particular part (of the ship); "ploughed" is the metaphor as it substitutes the concept of ploughing a field for moving through the ocean; and "the deep" is the metonym, as "depth" is an attribute associated with the ocean.