A black mangrove is an example of a halophyte.
A halophyte is a plant that grows in soils that have a high content of various salts. Depending on their tolerance and demands for sodium salts, a distinction is made between obligate and facultative halophytes. Obligatory means that they need some salt, facultative means they can live also under freshwater conditions.
Further divisions are hydrohalophytes and xerohalophytes. Hydrohalophytes grow in aquatic conditions or on wet soil. Most mangroves and saltmarsh species along coastlines are hydrohalophytes. Xerohalophytes may grow in habitats where the soil is always saline but where the soil may dry out so much as to cause problems with water availability for the plant.