mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
rdoc update.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@19134 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
6ce3230881
commit
0406b0f154
1 changed files with 18 additions and 13 deletions
31
transcode.c
31
transcode.c
|
@ -2326,24 +2326,29 @@ make_dummy_encoding(const char *name)
|
||||||
/*
|
/*
|
||||||
* call-seq:
|
* call-seq:
|
||||||
* Encoding::Converter.new(source_encoding, destination_encoding)
|
* Encoding::Converter.new(source_encoding, destination_encoding)
|
||||||
* Encoding::Converter.new(source_encoding, destination_encoding, opthash)
|
* Encoding::Converter.new(source_encoding, destination_encoding, opt)
|
||||||
*
|
*
|
||||||
* possible opthash elements:
|
* possible options elements:
|
||||||
* :universal_newline_decoder => true # convert CRLF and CR to LF at last
|
* hash form:
|
||||||
* :crlf_newline_encoder => true # convert LF to CRLF at first
|
* :universal_newline_decoder => true # convert CRLF and CR to LF at last
|
||||||
* :cr_newline_encoder => true # convert LF to CR at first
|
* :crlf_newline_encoder => true # convert LF to CRLF at first
|
||||||
* :invalid => nil # error on invalid byte sequence (default)
|
* :cr_newline_encoder => true # convert LF to CR at first
|
||||||
* :invalid => :replace # replace invalid byte sequence
|
* :invalid => nil # error on invalid byte sequence (default)
|
||||||
* :undef => nil # error on undefined conversion (default)
|
* :invalid => :replace # replace invalid byte sequence
|
||||||
* :undef => :replace # replace undefined conversion
|
* :undef => nil # error on undefined conversion (default)
|
||||||
* :replace => string # replacement string ("?" or "\uFFFD" if not specified)
|
* :undef => :replace # replace undefined conversion
|
||||||
|
* :replace => string # replacement string ("?" or "\uFFFD" if not specified)
|
||||||
|
* integer form:
|
||||||
|
* Encoding::Converter::UNIVERSAL_NEWLINE_DECODER
|
||||||
|
* Encoding::Converter::CRLF_NEWLINE_ENCODER
|
||||||
|
* Encoding::Converter::CR_NEWLINE_ENCODER
|
||||||
*
|
*
|
||||||
* Encoding::Converter.new creates an instance of Encoding::Converter.
|
* Encoding::Converter.new creates an instance of Encoding::Converter.
|
||||||
*
|
*
|
||||||
* source_encoding and destination_encoding should be a string or
|
* source_encoding and destination_encoding should be a string or
|
||||||
* Encoding object.
|
* Encoding object.
|
||||||
*
|
*
|
||||||
* flags should be an integer.
|
* opt should be nil, a hash or an integer.
|
||||||
*
|
*
|
||||||
* example:
|
* example:
|
||||||
* # UTF-16BE to UTF-8
|
* # UTF-16BE to UTF-8
|
||||||
|
@ -2566,7 +2571,7 @@ econv_result_to_symbol(rb_econv_result_t res)
|
||||||
* nil means unlimited.
|
* nil means unlimited.
|
||||||
* If it is omitted, nil is assumed.
|
* If it is omitted, nil is assumed.
|
||||||
*
|
*
|
||||||
* flags should be an integer or nil.
|
* opt should be nil, a hash or an integer.
|
||||||
* nil means no flags.
|
* nil means no flags.
|
||||||
* If it is omitted, nil is assumed.
|
* If it is omitted, nil is assumed.
|
||||||
*
|
*
|
||||||
|
@ -2733,7 +2738,7 @@ econv_primitive_convert(int argc, VALUE *argv, VALUE self)
|
||||||
* convert source_string and return destination_string.
|
* convert source_string and return destination_string.
|
||||||
*
|
*
|
||||||
* source_string is assumed as a part of source.
|
* source_string is assumed as a part of source.
|
||||||
* i.e. Encoding::Converter::PARTIAL_INPUT is used internally.
|
* i.e. :partial_input=>true is specified internally.
|
||||||
* finish method should be used at last.
|
* finish method should be used at last.
|
||||||
*
|
*
|
||||||
* ec = Encoding::Converter.new("utf-8", "euc-jp")
|
* ec = Encoding::Converter.new("utf-8", "euc-jp")
|
||||||
|
|
Loading…
Reference in a new issue