method

name

ruby latest stable - Class: Encoding
name()
public

Returns the name of the encoding.

Encoding::UTF_8.name      #=> "UTF-8"