Class: Rubyfocus::Folder

Inherits:
RankedItem show all
Includes:
Parser
Defined in:
lib/rubyfocus/items/folder.rb

Instance Attribute Summary

Attributes inherited from RankedItem

#rank

Attributes inherited from NamedItem

#name

Attributes inherited from Item

#added, #document, #id, #modified

Class Method Summary collapse

Instance Method Summary collapse

Methods included from Parser

included, parse

Methods inherited from RankedItem

#ancestry, #contained_within?

Methods inherited from NamedItem

#to_s

Methods inherited from Item

#initialize, #inspect, #to_serial

Methods included from ConditionalExec

#conditional_set

Methods included from IDRef

included

Constructor Details

This class inherits a constructor from Rubyfocus::Item

Class Method Details

.matches_node?(node) ⇒ Boolean

Returns:

  • (Boolean)


3
4
5
# File 'lib/rubyfocus/items/folder.rb', line 3

def self.matches_node?(node)
	return (node.name == "folder")
end

Instance Method Details

#apply_xml(n) ⇒ Object



7
8
9
10
# File 'lib/rubyfocus/items/folder.rb', line 7

def apply_xml(n)
	super(n)
	conditional_set(:container_id, n.at_xpath("xmlns:folder")){ |e| e["idref"] }
end