This class is designed for the purpose of server storing requests from all clients.
To maintain the consistency of the whole system, the server should manipulate requests one at a time.
But when there are many clients connecting to the server, one or more requests may arrive when the
server is processing a request. Therefore, we designed a shared queue. The server has two shared
queues. All map requests from any client are put into one queue; all action requests are put into
the other.
The server has two SharedQueues: one is for all the map requests, and the other is for all the action
requests. When a request arrives, it will be put into the corresponding queue and be processed later in
the first in first out manner.
The shared queue is built by using a Vector. When constructing a SharedQueue, the size and increment should be specified.
SharedQueue has two methods: put and get. put is to put the specified object into the queue while
get is to get this first object in the queue.