What is the meaning of Synecdoche?

A figure of speech that uses the name of a part of something to represent the whole, or the whole to represent a part, or a specific kind or instance to represent the general category, or the general category to represent a specific kind or instance, or the constituent material to represent the thing made from it.

The use of this figure of speech.

synecdoche

the putting of a whole for a part

synecdoche (certain type of metaphor)

Source: wiktionary.org