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

📄 addressbase.java

📁 java开源的企业总线.xmlBlaster
💻 JAVA
📖 第 1 页 / 共 4 页
字号:
   // used by SOCKET as the same socket is used for callback tunneling   private Object/*I_CallbackDriver*/ callbackDriver = null;   public final void setCallbackDriver(Object/*I_CallbackDriver*/ callbackDriver) {      this.callbackDriver = callbackDriver;   }   public final Object getCallbackDriver() {      return this.callbackDriver;   }      /**    * Returns the protocol type.    * @return e.g. "EMAIL" or "IOR" (never null).    */   public final String getType() {      return type.getValue();   }   /**    * Returns the protocol version.    * @return e.g. "1.0" or null    */   public final String getVersion() {      return version.getValue();   }   /**    * What to do if max retries is exhausted.     * <p />    * This mode is currently not configurable, we always destroy the login session.     * This is interpreted only server side if callback fails.    * @return Constants.ONEXHAUST_KILL_SESSION="killSession"    */   public final String getOnExhaust() {      return Constants.ONEXHAUST_KILL_SESSION; // in future possibly Constants.ONEXHAUST_KILL_CALLBACK   }   /**    * Kill login session if max callback retries is exhausted?    */   public final boolean getOnExhaustKillSession() {      return getOnExhaust().equalsIgnoreCase(Constants.ONEXHAUST_KILL_SESSION);   }   /**    * BurstMode: The time span to collect messages before sending.     * @return The time to collect in milliseconds (default is 0 == switched off)    */   public final long getCollectTime() {      return this.collectTime.getValue();   }   /**    * BurstMode: The time to collect messages for sending in a bulk.     * @param The time to collect in milliseconds    */   public void setCollectTime(long collectTime) {      if (collectTime < 0L) this.collectTime.setValue(0L);      else this.collectTime.setValue(collectTime);   }   /**    * How many messages maximum shall the callback thread take in one bulk out of the    * callback queue and deliver to the client in one bulk.     */   public int getBurstModeMaxEntries() {      return this.burstModeMaxEntries.getValue();   }   public void setBurstModeMaxEntries(int burstModeMaxEntries) {      if (burstModeMaxEntries == 0)         log.warning("<burstMode maxEntries='" + burstModeMaxEntries + "'> is not supported and may cause strange behavior");      else if (burstModeMaxEntries < -1)         burstModeMaxEntries = -1;            this.burstModeMaxEntries.setValue(burstModeMaxEntries);   }   /**    * How many bytes maximum shall the callback thread take in one bulk out of the    * callback queue and deliver to the client in one bulk.     */   public long getBurstModeMaxBytes() {      return this.burstModeMaxBytes.getValue();   }   public void setBurstModeMaxBytes(long burstModeMaxBytes) {      if (burstModeMaxBytes == 0)         log.warning("<burstMode maxBytes='" + burstModeMaxBytes + "'> is not supported and may cause strange behavior");      else if (burstModeMaxBytes < -1L)         burstModeMaxBytes = -1L;      this.burstModeMaxBytes.setValue(burstModeMaxBytes);   }   /**    * How long to wait between pings to the callback server.     * @return The pause time between pings in millis    */   public final long getPingInterval() {      return pingInterval.getValue();   }   /**    * How long to wait between pings to the callback server.     * @param pingInterval The pause time between pings in millis    */   public void setPingInterval(long pingInterval) {      if (pingInterval <= 0L) this.pingInterval.setValue(0L);      else if (pingInterval < 10L) {         log.warning("pingInterval=" + pingInterval + " msec is too short, setting it to 10 millis");         this.pingInterval.setValue(10L);      }      else         this.pingInterval.setValue(pingInterval);   }   /**    * How often shall we retry callback attempt on callback failure    * @return -1 forever, 0 no retry, > 0 number of retries    */   public final int getRetries() {      return retries.getValue();   }   /**    * How often shall we retry callback attempt on callback failure    * @param -1 forever, 0 no retry, > 0 number of retries    */   public void setRetries(int retries) {      if (retries < -1) this.retries.setValue(-1);      else this.retries.setValue(retries);   }   /**    * Delay between callback retries in milliseconds, defaults to one minute    * @return The delay in millisconds    */   public final long getDelay() {      return delay.getValue();   }   /**    * Delay between callback retries in milliseconds, defaults to one minute    */   public void setDelay(long delay) {      if (delay <= 0L) this.delay.setValue(getDefaultDelay());      else this.delay.setValue(delay);   }   /**    * Shall the publish() or callback update() message be oneway.     * Is only with CORBA and our native SOCKET protocol supported    * @return true if you want to force oneway sending    */   public final boolean oneway() {      return oneway.getValue();   }   /**    * Shall the publish() or callback update() message be oneway.     * Is only with CORBA and our native SOCKET protocol supported    * @param oneway false is default    */   public void setOneway(boolean oneway) {      this.oneway.setValue(oneway);   }   /**    * Inhibits/activates the delivery of asynchronous dispatches of messages.    * @param dispatcherActive    */   public void setDispatcherActive(boolean dispatcherActive) {      this.dispatcherActive.setValue(dispatcherActive);   }      /**    * @return true if the dispatcher is currently activated, i.e. if it is     * able to deliver asynchronous messages from the queue.    */   public boolean isDispatcherActive() {      return this.dispatcherActive.getValue();   }   /**    * @param Set if we accept point to point messages    */   public void setPtpAllowed(boolean ptpAllowed) {      this.ptpAllowed.setValue(ptpAllowed);   }   /**    * @return true if we may send PtP messages    */   public final boolean isPtpAllowed() {      return this.ptpAllowed.getValue();   }   public void setCompressType(String compressType) {      if (compressType == null) this.compressType.setValue("");      this.compressType.setValue(compressType);   }   /**    * The identifier sent to the callback client, the client can decide if he trusts this invocation    * @return never null    */   public final String getSecretSessionId() {      return sessionId.getValue();   }   /** The identifier sent to the callback client, the client can decide if he trusts this invocation */   public void setSecretSessionId(String sessionId) {      this.sessionId.setValue(sessionId);   }   /**    * Get the compression method.     * @return "" No compression    */   public final String getCompressType() {      return this.compressType.getValue();   }   /**     * Messages bigger this size in bytes are compressed.     * <br />    * Note: This value is only used if compressType is set to a supported value    * @return size in bytes    */   public long getMinSize() {      return this.minSize.getValue();   }   /**     * Messages bigger this size in bytes are compressed.     * <br />    * Note: This value is only evaluated if compressType is set to a supported value    * @return size in bytes    */   public void setMinSize(long minSize) {      this.minSize.setValue(minSize);   }   /**    * Specify your dispatcher plugin configuration.     * <p>    * Set to "undef" to switch off, or to e.g. "Priority,1.0" to access the PriorizedDispatchPlugin    * </p>    * <p>    * This overwrites the xmlBlaster.properties default setting e.g.:    * <pre>    * DispatchPlugin[Priority][1.0]=org.xmlBlaster.util.dispatch.plugins.prio.PriorizedDispatchPlugin    * DispatchPlugin[SlowMotion][1.0]=org.xmlBlaster.util.dispatch.plugins.motion.SlowMotion    * DispatchPlugin/defaultPlugin=Priority,1.0    * </pre>    * </p>    * @see <a href="http://www.xmlBlaster.org/xmlBlaster/doc/requirements/dispatch.control.plugin.html">The dispatch.control.plugin requirement</a>    */   public void setDispatchPlugin(String dispatchPlugin) {      this.dispatchPlugin.setValue(dispatchPlugin);   }   /**    * @return "undef" or e.g. "Priority,1.0"    */   public String getDispatchPlugin() {      return this.dispatchPlugin.getValue();   }      public final boolean isStallOnPingTimeout() {      return this.stallOnPingTimeout.getValue();   }   public final void setStallOnPingTimeout(boolean stallOnPingTimeout) {      this.stallOnPingTimeout.setValue(stallOnPingTimeout);   }      /**    * Called for SAX callback start tag    */   public final void startElement(String uri, String localName, String name, StringBuffer character, Attributes attrs) {      // log.info(ME, "startElement(rootTag=" + rootTag + "): name=" + name + " character='" + character.toString() + "'");      String tmp = character.toString().trim(); // The address      if (tmp.length() > 0) {         setRawAddress(tmp);      }      character.setLength(0);      if (name.equalsIgnoreCase(rootTag)) { // "callback"         if (attrs != null) {            int len = attrs.getLength();

⌨️ 快捷键说明

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