method

to_s

ruby latest stable - Class: Encoding
to_s()
public

Returns the name of the encoding.

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