Interface Scheduler
-
- All Known Implementing Classes:
AbstractQueueScheduler
,FIFOScheduler
,LazyScheduler
,PriorityQueueScheduler
public interface Scheduler
This interface represents only the most basic of a scheduler. It imposes no restrictions or particular details on the the type of queue, and allows for different future types to be returned.- Author:
- Maksim Tkachenko, Ween Jiann Lee
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
add(@NotNull Request r)
Adds a request to the queue.void
add(@NotNull Request r, @NotNull Handler h)
Adds a request to the queue.void
add(@NotNull Request r, @NotNull Handler h, Priority p)
Adds a request to the queue.void
add(@NotNull Request r, @NotNull Handler h, Priority p, Priority pf)
Adds a request to the queue.void
add(@NotNull Request r, Priority p)
Adds a request to the queue.void
add(@NotNull Request r, Priority p, Priority pf)
Adds a request to the queue.
-
-
-
Method Detail
-
add
void add(@NotNull @NotNull Request r, @NotNull @NotNull Handler h, Priority p, Priority pf)
Adds a request to the queue.This request would be parsed by the handler specified, and its priority can be downgraded to a minimum priority specified.
- Parameters:
r
- request to fetch when dequeuedh
- handler to be used to parse the requestp
- initial priority of the requestpf
- the minimum (floor) priority of this request
-
add
void add(@NotNull @NotNull Request r, @NotNull @NotNull Handler h, Priority p)
Adds a request to the queue.This request would be parsed by the handler specified, and its priority can be downgraded to the default minimum priority.
- Parameters:
r
- request to fetch when dequeuedh
- handler to be used to parse the requestp
- initial priority of the request
-
add
void add(@NotNull @NotNull Request r, @NotNull @NotNull Handler h)
Adds a request to the queue.This request would be parsed by the handler specified, and it's initialised with default priority that can be downgraded to the default minimum priority.
- Parameters:
r
- request to fetch when dequeuedh
- handler to be used to parse the request
-
add
void add(@NotNull @NotNull Request r, Priority p, Priority pf)
Adds a request to the queue.This request would be parsed by a handler defined in Router or otherwise, and its priority can be downgraded to a minimum priority specified.
- Parameters:
r
- request to fetch when dequeuedp
- initial priority of the requestpf
- the minimum (floor) priority of this request
-
add
void add(@NotNull @NotNull Request r, Priority p)
Adds a request to the queue.This request would be parsed by a handler defined in Router or otherwise defined, and its priority can be downgraded to the default minimum priority.
- Parameters:
r
- request to fetch when dequeuedp
- initial priority of the request
-
add
void add(@NotNull @NotNull Request r)
Adds a request to the queue.This request would be parsed by a handler defined in Router or otherwise defined, and it's initialised with default priority that can be downgraded to the default minimum priority.
- Parameters:
r
- request to fetch when dequeued
-
-