ruby-changes:19592
From: drbrain <ko1@a...>
Date: Thu, 19 May 2011 06:07:47 +0900 (JST)
Subject: [ruby-changes:19592] drbrain:r31634 (trunk): * lib/cgi/util.rb: Improve documentation. Patch by Clinton Nixon.
drbrain 2011-05-19 06:07:13 +0900 (Thu, 19 May 2011) New Revision: 31634 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=31634 Log: * lib/cgi/util.rb: Improve documentation. Patch by Clinton Nixon. [Ruby 1.9 - Bug #4733] * lib/cgi/core.rb: ditto * lib/cgi/cookie.rb: ditto Modified files: trunk/ChangeLog trunk/lib/cgi/cookie.rb trunk/lib/cgi/core.rb trunk/lib/cgi/util.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 31633) +++ ChangeLog (revision 31634) @@ -1,3 +1,10 @@ +Thu May 19 06:06:07 2011 Eric Hodel <drbrain@s...> + + * lib/cgi/util.rb: Improve documentation. Patch by Clinton Nixon. + [Ruby 1.9 - Bug #4733] + * lib/cgi/core.rb: ditto + * lib/cgi/cookie.rb: ditto + Thu May 19 06:02:21 2011 Eric Hodel <drbrain@s...> * lib/tempfile.rb: Document Dir.mkdir and Dir.rmdir. Patch by Clinton Index: lib/cgi/util.rb =================================================================== --- lib/cgi/util.rb (revision 31633) +++ lib/cgi/util.rb (revision 31634) @@ -83,9 +83,13 @@ end end end + + # Synonym for CGI.escapeHTML. def CGI::escape_html(str) escapeHTML(str) end + + # Synonym for CGI.unescapeHTML. def CGI::unescape_html(str) unescapeHTML(str) end @@ -134,9 +138,13 @@ string end end + + # Synonym for CGI.escapeElement. def CGI::escape_element(str) escapeElement(str) end + + # Synonym for CGI.unescapeElement. def CGI::unescape_element(str) unescapeElement(str) end Index: lib/cgi/core.rb =================================================================== --- lib/cgi/core.rb (revision 31633) +++ lib/cgi/core.rb (revision 31634) @@ -46,14 +46,17 @@ # :startdoc: + # Synonym for ENV. def env_table ENV end + # Synonym for $stdin. def stdinput $stdin end + # Synonym for $stdout. def stdoutput $stdout end @@ -705,14 +708,17 @@ @@accept_charset="UTF-8" + # Return the accept character set for all new CGI instances. def self.accept_charset @@accept_charset end + # Set the accept character set for all new CGI instances. def self.accept_charset=(accept_charset) @@accept_charset=accept_charset end + # Return the accept character set for this CGI instance. attr_reader :accept_charset # Create a new CGI instance. Index: lib/cgi/cookie.rb =================================================================== --- lib/cgi/cookie.rb (revision 31633) +++ lib/cgi/cookie.rb (revision 31634) @@ -104,10 +104,12 @@ # True if this cookie is secure; false otherwise attr_reader("secure") + # Returns the value or list of values for this cookie. def value self end + # Replaces the value of this cookie with a new value or list of values. def value=(val) replace(Array(val)) end -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/