⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 stackconfiguration.java

📁 First of all, the Applet-phone is a SIP User-Agent with audio and text messaging capabilities. But
💻 JAVA
字号:
/* * StackConfiguration.java * * Created on May 22, 2003, 10:08 AM */package gov.nist.examples.pcc;import java.util.*;/** * * @author  deruelle */public class StackConfiguration {        // Stack:    public String stackName;    public String stackIPAddress;    public String outboundProxy;    public String routerPath;    public String extensionMethods;    public String retransmissionFilter;    public String maxConnections;    public String maxServerTransactions;    public String threadPoolSize;       // Listening points:    public Hashtable listeningPoints;      private int counter;          /** Creates a new instance of StackConfiguration */    public StackConfiguration() {          counter=0;          listeningPoints=new Hashtable();    }        protected boolean check(String s) {        return  (s!=null && !s.trim().equals(""));    }        public void addListeningPoint(String port,String transport) {        if (check(port) && check(transport) ) {            counter++;            listeningPoints.put		("listeningPoint"+counter,new Association(port,transport) );        }    }             public Vector getListeningPoints() {        if (listeningPoints!=null) {            Collection c = listeningPoints.values();           return new Vector(c);        }        return null;    }        public boolean isValidConfiguration() {                if  ( check(stackName) &&        check(stackIPAddress) &&        check(routerPath) &&        !listeningPoints.isEmpty()        ) {            return true;        }        else {            System.out.println            ("ERROR, the configuration is not valid: Problem with"+            " the stack tag and stack parameters");            return false;        }            }    }

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -