module FeedBurner::Configurable

Attributes

api_key[RW]

Public Instance Methods

configure() { |self| ... } click to toggle source
# File lib/feed_burner/configurable.rb, line 5
def configure
  yield self
  validate_key_type!
end

Private Instance Methods

validate_key_type!() click to toggle source
# File lib/feed_burner/configurable.rb, line 12
def validate_key_type!
  if !api_key.nil?
    unless api_key.is_a?(String) || api_key.is_a?(Symbol)
      raise ArgumentError, "Invalid api_key specified: #{api_key} must be a string or symbol."
    end
  end
end