Creates a digest based on: CLASS:EXCLUDE?:FIRST:LAST where EXCLUDE? is a boolean value whether the Range excludes the last value (i.e. 1...100) and FIRST and LAST are the values returned by Range#first and Range#last. e.g.
(1..100) => Range:false:1:100 => 54506352 (1...100) => Range:true:1:100 => f0cad8cc
To use use method in other classes simply:
class ClassLikeRange include Gibbler::Range end
Creates a digest for the current state of self.
# File lib/gibbler.rb, line 593 def __gibbler(digest_type=nil) klass = self.class if self.nil? first, last, exclude = "\00"", "\00"", "\00"" else first, last, exclude = self.first, self.last, self.exclude_end? end a = Gibbler.digest "%s:%s:%s:%s" % [klass, exclude, first, last], digest_type gibbler_debug klass, a, [klass, exclude, first, last] a end
Generated with the Darkfish Rdoc Generator 2.