Class: Pwrake::PriorityHrfQueueArray
- Inherits:
-
PriorityQueueArray
- Object
- Array
- PriorityQueueArray
- Pwrake::PriorityHrfQueueArray
- Includes:
- HrfQueue
- Defined in:
- lib/pwrake/queue/queue_array.rb
Overview
Priority + HRF
Instance Method Summary collapse
-
#initialize(n) ⇒ PriorityHrfQueueArray
constructor
A new instance of PriorityHrfQueueArray.
- #pop_super ⇒ Object
- #push(t) ⇒ Object
- #shift ⇒ Object
Methods included from HrfQueue
#check, #hrf_delete, #hrf_get, #hrf_init, #hrf_push, #pop_last_rank
Methods inherited from PriorityQueueArray
Constructor Details
#initialize(n) ⇒ PriorityHrfQueueArray
Returns a new instance of PriorityHrfQueueArray.
256 257 258 259 |
# File 'lib/pwrake/queue/queue_array.rb', line 256 def initialize(n) super(n) hrf_init(n) end |
Instance Method Details
#pop_super ⇒ Object
271 272 273 |
# File 'lib/pwrake/queue/queue_array.rb', line 271 def pop_super pop end |
#push(t) ⇒ Object
261 262 263 264 |
# File 'lib/pwrake/queue/queue_array.rb', line 261 def push(t) super(t) hrf_push(t) end |
#shift ⇒ Object
266 267 268 269 |
# File 'lib/pwrake/queue/queue_array.rb', line 266 def shift return nil if empty? hrf_get end |