Java API for plural forms of English words

前端 未结 7 827
忘掉有多难
忘掉有多难 2020-12-01 10:54

Are there any Java API(s) which will provide plural form of English words (e.g. cacti for cactus)?

7条回答
  •  挽巷
    挽巷 (楼主)
    2020-12-01 11:22

    I know there is simple pluralize() function in Ruby on Rails, maybe you could get that through JRuby. The problem really isn't easy, I saw pages of rules on how to pluralize and it wasn't even complete. Some rules are not algorithmic - they depend on stem origin etc. which isn't easily obtained. So you have to decide how perfect you want to be.

提交回复
热议问题