mdc/lib/domain/presentation.rb
##
# Create a digest of the content with the given length
# @param [Fixnum] length length of the digest in characters
# @return [String] a digest of the presentation, i.e. the first length characters
Create a digest of the content with the given length
Create a digest of the content with the given length
def digest(length)
      digest = ''
      @chapters.each { |chapter| digest << chapter.digest }
      digest.delete!("\n")
      digest.delete!('_')
      digest.delete!('*')
      digest.squeeze!(' ')
      digest[0...length]
    end
def digest ( length ) digest = '' @chapters . each { | chapter | digest << chapter . digest } digest . delete! ( "\n" ) digest . delete! ( '_' ) digest . delete! ( '*' ) digest . squeeze! ( ' ' ) digest [ 0 ... length ] end
Create a digest of the content with the given length
Create a digest of the content with the given length
a digest of the presentation, i.e. the first length characters
a digest of the presentation i . e . the first length characters
String
length
<not_specific>
<not_specific>
length length of the digest in characters
length length of the digest in characters