Asterisk-Java

org.asteriskjava.live
Interface AsteriskQueue


public interface AsteriskQueue

An Asterisk ACD queue.

Version:
$Id: AsteriskQueue.java 1242 2009-03-09 15:49:12Z srt $
Author:
srt

Field Summary
static java.lang.String STRATAGY_LEAST_RECENT
           
static java.lang.String STRATEGY_FEWEST_CALLS
           
static java.lang.String STRATEGY_RANDOM
           
static java.lang.String STRATEGY_RINGALL
           
static java.lang.String STRATEGY_ROUNDROBIN
           
static java.lang.String STRATEGY_RRMEMORY
           
 
Method Summary
 void addAsteriskQueueListener(AsteriskQueueListener listener)
          Registers a new queue listener.
 java.util.List<AsteriskQueueEntry> getEntries()
          Returns the list of entries currently waiting in this queue.
 java.lang.Integer getMax()
          Returns the maximum number of people allowed to wait in this queue or 0 for unlimited.
 java.util.Collection<AsteriskQueueMember> getMembers()
          Returns the list of Asterisk members of this queue.
 java.lang.String getName()
          Returns the name of this queue as defined in Asterisk's queues.conf.
 java.lang.Integer getServiceLevel()
          Returns the service level (in seconds) as defined by the servicelevel setting in queues.conf.
 java.lang.String getStrategy()
          Returns the strategy used for this queue.
 java.lang.Integer getWeight()
          Returns the weight of this queue.
 void removeAsteriskQueueListener(AsteriskQueueListener listener)
          Removes a previously registered queue listener.
 

Field Detail

STRATEGY_RINGALL

static final java.lang.String STRATEGY_RINGALL
See Also:
Constant Field Values

STRATEGY_ROUNDROBIN

static final java.lang.String STRATEGY_ROUNDROBIN
See Also:
Constant Field Values

STRATAGY_LEAST_RECENT

static final java.lang.String STRATAGY_LEAST_RECENT
See Also:
Constant Field Values

STRATEGY_FEWEST_CALLS

static final java.lang.String STRATEGY_FEWEST_CALLS
See Also:
Constant Field Values

STRATEGY_RANDOM

static final java.lang.String STRATEGY_RANDOM
See Also:
Constant Field Values

STRATEGY_RRMEMORY

static final java.lang.String STRATEGY_RRMEMORY
See Also:
Constant Field Values
Method Detail

getName

java.lang.String getName()
Returns the name of this queue as defined in Asterisk's queues.conf.

Returns:
the name of this queue.

getMax

java.lang.Integer getMax()
Returns the maximum number of people allowed to wait in this queue or 0 for unlimited.

Corresponds to the maxlen option in Asterisk's queues.conf.

Returns:
the maximum number of people allowed to wait in this queue.

getStrategy

java.lang.String getStrategy()
Returns the strategy used for this queue.

Possible values are:

Available since Asterisk 1.6

Returns:
the strategy used for this queue.
Since:
1.0.0

getServiceLevel

java.lang.Integer getServiceLevel()
Returns the service level (in seconds) as defined by the servicelevel setting in queues.conf.

Returns:
the service level (in seconds).

getWeight

java.lang.Integer getWeight()
Returns the weight of this queue.

A queue can be assigned a 'weight' to ensure calls waiting in a higher priority queue will deliver its calls first. Only delays the lower weight queue's call if the member is also in the higher weight queue.

Available since Asterisk 1.2

Returns:
the weight of this queue or null if not supported by your version of Asterisk.

getEntries

java.util.List<AsteriskQueueEntry> getEntries()
Returns the list of entries currently waiting in this queue.

Returns:
the (ordered) list of entries currently waiting in this queue.

getMembers

java.util.Collection<AsteriskQueueMember> getMembers()
Returns the list of Asterisk members of this queue.

Returns:
the list of Asterisk members of this queue.
Since:
0.3.1

addAsteriskQueueListener

void addAsteriskQueueListener(AsteriskQueueListener listener)
Registers a new queue listener.

Parameters:
listener - the listener to add.
Since:
0.3

removeAsteriskQueueListener

void removeAsteriskQueueListener(AsteriskQueueListener listener)
Removes a previously registered queue listener.

Parameters:
listener - the listener to remove.
Since:
0.3

Asterisk-Java

Copyright © 2004-2009 Stefan Reuter. All Rights Reserved.