Class: ODDB::PointerArray

Inherits:
Array show all
Defined in:
src/util/pointerarray.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Methods inherited from Array

#obj_path

Constructor Details

- (PointerArray) initialize(values, pointer)

A new instance of PointerArray



7
8
9
10
11
12
13
# File 'src/util/pointerarray.rb', line 7

def initialize(values, pointer)
  super()
  values.each { |val|
    self << val
  }
  @pointer = pointer
end

Instance Attribute Details

- (Object) pointer

Returns the value of attribute pointer



6
7
8
# File 'src/util/pointerarray.rb', line 6

def pointer
  @pointer
end

Instance Method Details

- (Object) sort_by(*args, &block)



14
15
16
17
# File 'src/util/pointerarray.rb', line 14

def sort_by(*args, &block)
  result = super
  PointerArray.new(result, @pointer)
end