Example #1
0
 /** Stop stack. Clear all the timer stuff. */
 public void stopStack() {
   this.notifyPendingRecordScanner();
   this.timer.cancel();
   this.pendingTransactions.clear();
   super.stopStack();
   // PC 2.0 Notify the PendingRecordScanner to clean up
   this.notifyPendingRecordScanner();
 }
Example #2
0
  /** Re Initialize the stack instance. */
  protected void reInit() {
    super.reInit();
    clientTransactions = Collections.synchronizedList(new ArrayList<SIPClientTransaction>());
    serverTransactions = Collections.synchronizedList(new ArrayList<SIPServerTransaction>());
    pendingTransactions = new HashSet<SIPServerTransaction>();
    pendingRecords = Collections.synchronizedList(new ArrayList<PendingRecord>());
    clientTransactionTable = new Hashtable<String, SIPTransaction>();
    serverTransactionTable = new Hashtable<String, SIPTransaction>();
    // Dialog dable.
    this.dialogTable = new Hashtable<String, SIPDialog>();

    this.timer = new Timer();
    pendingRecordScanner = new Thread(new PendingRecordScanner(this));
    pendingRecordScanner.setDaemon(true);
    pendingRecordScanner.setName("PendingRecordScanner");
    pendingRecordScanner.start();
  }