Package tigase.workgroupqueues.scheduler

## Class Queue

- java.lang.Object
- - tigase.workgroupqueues.scheduler.Queue

-     public class Queue
      extends java.lang.Object

- - ### Nested Class Summary

    Nested Classes
    Modifier and Type | Class | Description
    --- | --- | ---
    `static class` | `Queue.Status` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `Queue​(BareJID jid, java.lang.String mucDomain)` |

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `void` | `addAgent​(Agent agent)` |
    `void` | `addOffer​(Offer offer)` |
    `void` | `addUser​(User user)` |
    `boolean` | `equals​(java.lang.Object o)` |
    `Agent` | `getAgent​(JID jid)` |
    `java.util.Collection<Agent>` | `getAgents()` |
    `int` | `getAvailableAgents()` | Return the total number of agents available in the workgroup.
    `int` | `getAverageWaitingTime()` |
    `int` | `getCurrentChats()` | Returns current total number of chats being handled by agents in the workgroup.
    `BareJID` | `getJid()` |
    `int` | `getMaxChats()` | Returns maximum number of simultaneous conversations that can be handled by agents in the workgroup.
    `java.lang.String` | `getMucDomain()` |
    `java.util.Collection<Offer>` | `getOffers()` |
    `java.util.Date` | `getOldestTime()` | Returns date and time when the oldest member of the queue joined.
    `QueueStats` | `getStats()` |
    `Queue.Status` | `getStatus()` |
    `User` | `getUser​(JID jid)` |
    `java.util.Collection<User>` | `getUsers()` |
    `int` | `hashCode()` |
    `void` | `removeAgent​(Agent agent)` |
    `Offer` | `removeOffer​(Queue queue, JID userJID, Agent agent)` |
    `void` | `removeUser​(User user)` |
    `void` | `setStatus​(Queue.Status status)` |
    `java.lang.String` | `toString()` |

    - ### Methods inherited from class java.lang.Object

      `clone, finalize, getClass, notify, notifyAll, wait, wait, wait`

- - ### Constructor Detail

    - #### Queue

          public Queue​(BareJID jid,
                       java.lang.String mucDomain)

  - ### Method Detail

    - #### addAgent

          public void addAgent​(Agent agent)

    - #### addOffer

          public void addOffer​(Offer offer)

    - #### addUser

          public void addUser​(User user)

    - #### equals

          public boolean equals​(java.lang.Object o)

      Overrides:
        `equals` in class `java.lang.Object`

    - #### getAgent

          public Agent getAgent​(JID jid)

    - #### getAgents

          public java.util.Collection<Agent> getAgents()

    - #### getAvailableAgents

          public int getAvailableAgents()

      Return the total number of agents available in the workgroup.
      Returns:
        number of agents.

    - #### getAverageWaitingTime

          public int getAverageWaitingTime()

    - #### getCurrentChats

          public int getCurrentChats()

      Returns current total number of chats being handled by agents in the workgroup.
      Returns:
        number of chats.

    - #### getJid

          public BareJID getJid()

    - #### getMaxChats

          public int getMaxChats()

      Returns maximum number of simultaneous conversations that can be handled by agents in the workgroup.
      Returns:
        maximum number of simultaneous conversations.

    - #### getMucDomain

          public java.lang.String getMucDomain()

    - #### getOffers

          public java.util.Collection<Offer> getOffers()

    - #### getOldestTime

          public java.util.Date getOldestTime()

      Returns date and time when the oldest member of the queue joined.
      Returns:
        join time of oldest member.

    - #### getStats

          public QueueStats getStats()

    - #### getStatus

          public Queue.Status getStatus()

    - #### setStatus

          public void setStatus​(Queue.Status status)

    - #### getUser

          public User getUser​(JID jid)

    - #### getUsers

          public java.util.Collection<User> getUsers()

    - #### hashCode

          public int hashCode()

      Overrides:
        `hashCode` in class `java.lang.Object`

    - #### removeAgent

          public void removeAgent​(Agent agent)

    - #### removeOffer

          public Offer removeOffer​(Queue queue,
                                   JID userJID,
                                   Agent agent)

    - #### removeUser

          public void removeUser​(User user)

    - #### toString

          public java.lang.String toString()

      Overrides:
        `toString` in class `java.lang.Object`