Java String Pluralize pluralize(long count, String singularFormat, String pluralFormat)

Here you can find the source of pluralize(long count, String singularFormat, String pluralFormat)

Description

pluralize

License

Open Source License

Declaration

public static String pluralize(long count, String singularFormat, String pluralFormat) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static String pluralize(long count, String singularFormat, String pluralFormat) {
        return Math.abs(count) == 1 ? String.format(singularFormat, count) : String.format(pluralFormat, count);
    }/*from  w  w w.j  av a  2  s . c  om*/
}

Related

  1. pluralize(int count, String singular, String plural)
  2. pluralize(int count, String singular, String plural)
  3. pluralize(int count, String word)
  4. Pluralize(int quantity, String units)
  5. pluralize(int value, CharSequence singularForm, CharSequence pluralForm)
  6. pluralize(long strictlyPositiveCount, String singular, String plural)
  7. pluralize(long val, String singular, String plural)
  8. pluralize(String base, int quantity)
  9. pluralize(String input)