Some comments
This commit is contained in:
parent
2765c5b4c9
commit
f0ec7833d7
@ -11,8 +11,8 @@ class App::Queue
|
|||||||
@data = [] of Item
|
@data = [] of Item
|
||||||
end
|
end
|
||||||
|
|
||||||
# Plan finishing of *command* at time *ts*
|
|
||||||
def push(ts : Int32, value : Command)
|
def push(ts : Int32, value : Command)
|
||||||
|
# very unoptimal algo
|
||||||
@data.push(Item.new(ts, value))
|
@data.push(Item.new(ts, value))
|
||||||
@data.sort! do |a, b|
|
@data.sort! do |a, b|
|
||||||
b.ts <=> a.ts
|
b.ts <=> a.ts
|
||||||
|
Loading…
Reference in New Issue
Block a user