예제 #1
0
  public SIPServerTransaction findPendingTransaction(SIPRequest requestReceived) {
    SIPServerTransaction currentTransaction;
    Iterator<SIPServerTransaction> transactionIterator;
    synchronized (pendingTransactions) {
      transactionIterator = pendingTransactions.iterator();
      currentTransaction = null;
      while (transactionIterator.hasNext() && currentTransaction == null) {

        SIPServerTransaction nextTransaction = (SIPServerTransaction) transactionIterator.next();

        // If this transaction should handle this request,
        if (nextTransaction.isMessagePartOfTransaction(requestReceived)) {
          // Mark this transaction as the one
          // to handle this message
          currentTransaction = nextTransaction;
        }
      }
    }
    return currentTransaction;
  }
예제 #2
0
 /**
  * Return true if extension is supported.
  *
  * @return true if extension is supported and false otherwise.
  */
 public boolean isDialogCreated(String method) {
   return dialogCreatingMethods.contains(method.toUpperCase());
 }