Class: Slaw::ZA::Act::BlocklistItem
- Inherits:
-
Treetop::Runtime::SyntaxNode
- Object
- Treetop::Runtime::SyntaxNode
- Slaw::ZA::Act::BlocklistItem
- Defined in:
- lib/slaw/za/act_nodes.rb
Instance Method Summary collapse
Instance Method Details
#content ⇒ Object
312 313 314 315 |
# File 'lib/slaw/za/act_nodes.rb', line 312 def content # TODO this really seems a bit odd item_content.content.text_value if respond_to? :item_content and item_content.respond_to? :content end |
#num ⇒ Object
308 309 310 |
# File 'lib/slaw/za/act_nodes.rb', line 308 def num blocklist_item_prefix.text_value end |
#to_xml(b, idprefix) ⇒ Object
317 318 319 320 321 322 |
# File 'lib/slaw/za/act_nodes.rb', line 317 def to_xml(b, idprefix) b.item(id: idprefix + num.gsub(/[()]/, '')) { |b| b.num(num) b.p(content) if content } end |