$:.unshift(File.dirname(__FILE__)) require 'templatelets/href' require 'templatelets/attribute' require 'templatelets/each' require 'templatelets/include' require 'templatelets/link' require 'templatelets/text' require 'templatelets/when' module REXML class Element def attribute_value!(name) value = attribute_value(name) raise "attribute #{name} not found" unless value return value end def attribute_value(name) return attributes[name] end end end