slice!

slice!(*args) Instance Public methods Works like like String#slice!, but returns an instance of Chars, or nil if the string was not modified.

reverse

reverse() Instance Public methods Reverses all characters in the string. 'Café'.mb_chars.reverse.to_s # => 'éfaC'

respond_to_missing?

respond_to_missing?(method, include_private) Instance Public methods Returns true if obj responds to the given method. Private methods are included in the search only if the optional second parameter evaluates to true.

normalize

normalize(form = nil) Instance Public methods Returns the KC normalization of the string by default. NFKC is considered the best normalization form for passing strings to databases and validations. form - The form you want to normalize in. Should be one of the following: :c, :kc, :d, or :kd. Default is ActiveSupport::Multibyte::Unicode#default_normalization_form

method_missing

method_missing(method, *args, &block) Instance Public methods Forward all undefined methods to the wrapped string.

limit

limit(limit) Instance Public methods Limits the byte size of the string to a number of bytes without breaking characters. Usable when the storage for a string is limited for some reason. 'ããã«ã¡ã¯'.mb_chars.limit(7).to_s # => "ãã"

grapheme_length

grapheme_length() Instance Public methods Returns the number of grapheme clusters in the string. 'à¤à¥à¤·à¤¿'.mb_chars.length # => 4 'à¤à¥à¤·à¤¿'.mb_chars.grapheme_length # => 3

downcase

downcase() Instance Public methods Converts characters in the string to lowercase. 'VÄDA A VÃZKUM'.mb_chars.downcase.to_s # => "vÄda a výzkum"

decompose

decompose() Instance Public methods Performs canonical decomposition on all the characters. 'é'.length # => 2 'é'.mb_chars.decompose.to_s.length # => 3

compose

compose() Instance Public methods Performs composition on all the characters. 'é'.length # => 3 'é'.mb_chars.compose.to_s.length # => 2