Show / Hide Table of Contents

Class Plural

Manages the plural information.

Inheritance
Object
Plural
Inherited Members
Object.ToString()
Object.Equals(Object)
Object.Equals(Object, Object)
Object.ReferenceEquals(Object, Object)
Object.GetHashCode()
Object.GetType()
Object.MemberwiseClone()
Namespace: Sepia.Globalization.Plurals
Assembly: Sepia.Globalization.dll
Syntax
public class Plural

Properties

| Improve this Doc View Source

Locale

The source for localisation information.

Declaration
public Locale Locale { get; set; }
Property Value
Type Description
Locale

Methods

| Improve this Doc View Source

Category(Decimal)

Gets the plural category of the specified number.

Declaration
public string Category(decimal value)
Parameters
Type Name Description
Decimal value

The number to examine.

Returns
Type Description
String

"zero", "one", "two", "few", "many" or "other".

Remarks

The category is only a mnemonic; the name does noy necessarily imply the exact contents of the category. For example, for both English and French the number 1 has the category "one" (singular). In English, every other number has a plural form, and is given the category "other". French is similar, except that the number 0 has the category "one" and not "other" or "zero", because the form of units qualified by 0 is also singular.

| Improve this Doc View Source

Create(Locale)

Creates or reuses plural informmation for the specified Locale.

Declaration
public static Plural Create(Locale locale)
Parameters
Type Name Description
Locale locale

The locale.

Returns
Type Description
Plural

The best for the locale.

  • Improve this Doc
  • View Source
Back to top Generated by DocFX