diff options
author | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-02-02 13:00:31 +0000 |
---|---|---|
committer | kou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e> | 2005-02-02 13:00:31 +0000 |
commit | bd4fd26fda94d3a0d75a130a025ea5b7b85a4f55 (patch) | |
tree | 275abf275db1fe9fba4cbedad8bfdad39051588d /lib/rss/1.0.rb | |
parent | ab2b03033ad19b0c936cff6387700e46c3fac0be (diff) | |
download | ruby-bd4fd26fda94d3a0d75a130a025ea5b7b85a4f55.tar.gz |
* lib/rss/rss.rb (RSS::Element#convert): added.
* lib/rss/rss.rb: convert -> need_convert.
* lib/rss/1.0.rb: ditto.
* lib/rss/0.9.rb: ditto.
* lib/rss/2.0.rb: ditto.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@7863 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rss/1.0.rb')
-rw-r--r-- | lib/rss/1.0.rb | 48 |
1 files changed, 24 insertions, 24 deletions
diff --git a/lib/rss/1.0.rb b/lib/rss/1.0.rb index 0e3e66ea95..86c19afc70 100644 --- a/lib/rss/1.0.rb +++ b/lib/rss/1.0.rb @@ -60,7 +60,7 @@ module RSS tag_name_with_prefix(PREFIX) end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent, ns_declarations) do |next_indent| [ channel_element(false, next_indent), @@ -70,7 +70,7 @@ module RSS other_element(false, next_indent), ] end - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -118,11 +118,11 @@ module RSS @li = li end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) tag(indent) do |next_indent| [ - li_elements(convert, next_indent), - other_element(convert, next_indent), + li_elements(need_convert, next_indent), + other_element(need_convert, next_indent), ] end end @@ -177,9 +177,9 @@ module RSS tag_name_with_prefix(PREFIX) end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -204,7 +204,7 @@ module RSS end - [ + [ ["about", URI, true] ].each do |name, uri, required| install_get_attribute(name, uri, required) @@ -234,7 +234,7 @@ module RSS @about = about end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) do |next_indent| [ title_element(false, next_indent), @@ -246,8 +246,8 @@ module RSS other_element(false, next_indent), ] end - rv = @converter.convert(rv) if convert and @converter - rv + rv = convert(rv) if need_convert + rv end private @@ -305,9 +305,9 @@ module RSS @resource = resource end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -342,9 +342,9 @@ module RSS @resource = resource end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -384,11 +384,11 @@ module RSS @Seq = seq end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) do |next_indent| [ - Seq_element(convert, next_indent), - other_element(convert, next_indent), + Seq_element(need_convert, next_indent), + other_element(need_convert, next_indent), ] end end @@ -448,7 +448,7 @@ module RSS @about = about end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) do |next_indent| [ title_element(false, next_indent), @@ -457,7 +457,7 @@ module RSS other_element(false, next_indent), ] end - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -518,7 +518,7 @@ module RSS @about = about end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) do |next_indent| [ title_element(false, next_indent), @@ -527,7 +527,7 @@ module RSS other_element(false, next_indent), ] end - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end @@ -589,7 +589,7 @@ module RSS @about = about end - def to_s(convert=true, indent=calc_indent) + def to_s(need_convert=true, indent=calc_indent) rv = tag(indent) do |next_indent| [ title_element(false, next_indent), @@ -599,7 +599,7 @@ module RSS other_element(false, next_indent), ] end - rv = @converter.convert(rv) if convert and @converter + rv = convert(rv) if need_convert rv end |