summaryrefslogtreecommitdiff
path: root/lib/rss
diff options
context:
space:
mode:
authorkou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-17 00:53:21 +0000
committerkou <kou@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2006-06-17 00:53:21 +0000
commit7461f297e92c2451b62a8797dff6562e52e3f746 (patch)
tree58ed280d46280b524dab8b8a6f6f739461f97589 /lib/rss
parent88dd1e4c993e661b0d52c40d0eff567b00bf6ffd (diff)
* lib/rss, test/rss: backported from trunk. (2005-11-16 - now)
* test/rss/test_2.0.rb: added RSS 2.0 tests. * test/rss/rss-assertions.rb: extended XML stylesheet assertion. * lib/rss/0.9.rb: added initialize method. * test/rss/test_1.0.rb: cleanup. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10296 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
Diffstat (limited to 'lib/rss')
-rw-r--r--lib/rss/0.9.rb19
1 files changed, 19 insertions, 0 deletions
diff --git a/lib/rss/0.9.rb b/lib/rss/0.9.rb
index 56fdfb3618..a4b2ba9b8f 100644
--- a/lib/rss/0.9.rb
+++ b/lib/rss/0.9.rb
@@ -339,6 +339,17 @@ module RSS
install_model(name, "?")
end
+ def initialize(url=nil, title=nil, link=nil, width=nil, height=nil,
+ description=nil)
+ super()
+ @url = url
+ @title = title
+ @link = link
+ @width = width
+ @height = height
+ @description = description
+ end
+
def to_s(need_convert=true, indent=calc_indent)
rv = tag(indent) do |next_indent|
[
@@ -618,6 +629,14 @@ module RSS
install_model(name, nil)
end
+ def initialize(title=nil, description=nil, name=nil, link=nil)
+ super()
+ @title = title
+ @description = description
+ @name = name
+ @link = link
+ end
+
def to_s(need_convert=true, indent=calc_indent)
rv = tag(indent) do |next_indent|
[