Class: Array

Inherits:
Object
  • Object
show all
Defined in:
lib/gepub/meta_array.rb

Direct Known Subclasses

SortedArray

Instance Method Summary collapse

Instance Method Details

#sort_as_metaObject


2
3
4
5
6
7
8
9
# File 'lib/gepub/meta_array.rb', line 2

def sort_as_meta
  i = 0
  sort_by {
      |v|
      seq = v.display_seq
      [ seq && seq.to_s.to_i || 2 ** (0.size * 8 - 2) - 1, i += 1]
  }
end