Class: Descriptor::MergePoint

Inherits:
Object
  • Object
show all
Defined in:
lib/rui/descriptor.rb

Defined Under Namespace

Classes: List

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(position, count = -1)) ⇒ MergePoint

Returns a new instance of MergePoint.



201
202
203
204
205
# File 'lib/rui/descriptor.rb', line 201

def initialize(position, count = -1)
  @position = position
  @count = count
  raise "Creating invalid merge point" if @count == 0
end

Instance Attribute Details

#countObject

Returns the value of attribute count.



170
171
172
# File 'lib/rui/descriptor.rb', line 170

def count
  @count
end

#positionObject

Returns the value of attribute position.



170
171
172
# File 'lib/rui/descriptor.rb', line 170

def position
  @position
end

Instance Method Details

#valid?Boolean

Returns:

  • (Boolean)


207
208
209
# File 'lib/rui/descriptor.rb', line 207

def valid?
  @count != 0
end