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

📄 addressserver.java

📁 java开源的企业总线.xmlBlaster
💻 JAVA
字号:
/*------------------------------------------------------------------------------Name:      AddressServer.javaProject:   xmlBlaster.orgCopyright: xmlBlaster.org, see xmlBlaster-LICENSE fileComment:   Holding address string and protocol string------------------------------------------------------------------------------*/package org.xmlBlaster.engine.qos;import org.xmlBlaster.util.Global;import org.xmlBlaster.util.qos.address.AddressBase;import java.util.Properties;/** * Helper class holding address string, protocol string of server side protocol plugins.  * <p /> * <pre> * &lt;address type='XMLRPC'> *    http://server:8080/ * &lt;/address> * </pre> */public class AddressServer extends AddressBase implements Cloneable{   private Object remoteAddress;   /**    * @param type    The protocol type, e.g. "IOR", "EMAIL", "XMLRPC"    * @param nodeId  A unique string (typically the cluster node id we connect to).    * @param pluginInfoParameters Attributes from xmlBlasterPlugins.xml    */   public AddressServer(Global glob, String type, String nodeId, Properties pluginInfoParameters) {      super(glob, "address");      this.nodeId = nodeId;      this.instanceName = null;      setType(type);      if (pluginInfoParameters != null)         setPluginInfoParameters(pluginInfoParameters);      else         initialize();   }   /**    * Some protocol plugins may add this information.     * For example the SOCKET plugin can deliver the remote clients    * IP and port here.    * @return For example getRemoteAddress().toString() = "socket://192.168.1.2:64794"    *         Can be null depending on the protocol plugin.<br />    *         For example the SOCKET protocol returns an "org.xmlBlaster.util.protocol.socket.SocketUrl" instance    */   public Object getRemoteAddress() {      return this.remoteAddress;   }   public void setRemoteAddress(Object remoteAddress) {      this.remoteAddress = remoteAddress;   }   /** DUMMY */   public int getDefaultRetries() { return -1; }   /** DUMMY */   public long getDefaultDelay() { return -1; };   /** DUMMY */   public long getDefaultPingInterval() { return -1; }   /** @return The literal address as given by getAddressServer() */   public String toString() {      return getRawAddress();   }      public AddressBase getClone() {      try {         AddressServer s = (AddressServer)super.clone();          return s;      } catch (CloneNotSupportedException e) {          //This shouldn't happen because we implement Cloneable.          throw new AssertionError();      }   }}

⌨️ 快捷键说明

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