Sha256: ea79fcec618c765ddf44e807cc81f23a6dc306f179783477c7a053d7f2103760
Contents?: true
Size: 708 Bytes
Versions: 1
Compression:
Stored size: 708 Bytes
Contents
unless Object.method_defined?(:returning) Object.class_eval do def returning(value) yield(value) value end end end module Avatar # :nodoc: module Source # :nodoc: # To be included by classes that generate avatar URLs from profiles. module AbstractSource # Return an avatar URL for the person, or nil if this source cannot generate one. # Including classes <em>must</em> override this method. In general, implementations # should return nil if +person+ is nil. def avatar_url_for(person, options = {}) raise NotImplementedError.new('including class must define avatar_url_for(person, options = {})') end end end end
Version data entries
1 entries across 1 versions & 1 rubygems
Version | Path |
---|---|
avatar-0.0.3 | lib/avatar/source/abstract_source.rb |