Sha256: 38ed05498b926a27fb0c7ec239870e6eb94bbcbdf6607b51e6a598f08bc647e9

Contents?: true

Size: 269 Bytes

Versions: 9

Compression:

Stored size: 269 Bytes

Contents

# Copyright 2012 Twitter, Inc
# http://www.apache.org/licenses/LICENSE-2.0

class TwitterCldr.PluralRules
  @rules = `{{{rules}}}`

  @all: ->
    return @rules.keys

  @rule_for: (number) ->
    try
      return @rules.rule(number)
    catch error
      return "other"

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
twitter_cldr_js-2.3.2 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.3.1 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.3.0 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.2.4 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.2.3 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.2.2 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.2.0 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.1.0 lib/twitter_cldr/js/mustache/plurals/rules.coffee
twitter_cldr_js-2.0.0 lib/twitter_cldr/js/mustache/plurals/rules.coffee