Pluralization Services

Recently as part of my work with the Entity Framework (EF) I came across a very interesting feature that could be leveraged in many other areas beyond the EF: The Pluralization Services. As you may be aware of, the EF has a feature that pluralizes the name of an entity when making entity sets. In order to pluralize the name it uses the Pluralization Services through which it figures what name to assign to the set.

You can access the PluralizationService at the System.Data.Entity.Design.PluralizationServices namespace:


Keep in mind this is an abstract class so you’ll need to use the static CreateService method on the class to access the different services. Thus far though the only culture implemented is: “en-us”.

If you want to see some examples on how to manually use this class as well as to how to add your own mappings (How you would like for a word to be pluralized) you can visit this page: Entity Framework 4.0: Pluralization

You may also like...

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: