Class: Nodo

Inherits:
Struct
  • Object
show all
Includes:
Comparable
Defined in:
lib/exam1/linkedlist.rb,
lib/exam1/linkedlist.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#previoObject

Returns the value of attribute previo

Returns:

  • (Object)

    the current value of previo



1
2
3
# File 'lib/exam1/linkedlist.rb', line 1

def previo
  @previo
end

#siguienteObject

Returns the value of attribute siguiente

Returns:

  • (Object)

    the current value of siguiente



1
2
3
# File 'lib/exam1/linkedlist.rb', line 1

def siguiente
  @siguiente
end

#valueObject

Returns the value of attribute value

Returns:

  • (Object)

    the current value of value



1
2
3
# File 'lib/exam1/linkedlist.rb', line 1

def value
  @value
end

Instance Method Details

#<=>(other) ⇒ Object



5
6
7
# File 'lib/exam1/linkedlist.rb', line 5

def <=>(other)
	value <=> other.value
end