1 18 package org.apache.activemq.transport.http; 19 20 import org.apache.activemq.transport.TransportThreadSupport; 21 import org.apache.activemq.transport.util.TextWireFormat; 22 23 import java.net.URI ; 24 25 30 public abstract class HttpTransportSupport extends TransportThreadSupport { 31 private TextWireFormat textWireFormat; 32 private URI remoteUrl; 33 private String proxyHost; 34 private int proxyPort = 8080; 35 36 public HttpTransportSupport(TextWireFormat textWireFormat, URI remoteUrl) { 37 this.textWireFormat = textWireFormat; 38 this.remoteUrl = remoteUrl; 39 } 40 41 public String toString() { 42 return "HTTP Reader " + getRemoteUrl(); 43 } 44 45 public String getRemoteAddress() { 48 return remoteUrl.toString(); 49 } 50 51 public URI getRemoteUrl() { 52 return remoteUrl; 53 } 54 55 public TextWireFormat getTextWireFormat() { 56 return textWireFormat; 57 } 58 59 public void setTextWireFormat(TextWireFormat textWireFormat) { 60 this.textWireFormat = textWireFormat; 61 } 62 63 public String getProxyHost() { 64 return proxyHost; 65 } 66 67 public void setProxyHost(String proxyHost) { 68 this.proxyHost = proxyHost; 69 } 70 71 public int getProxyPort() { 72 return proxyPort; 73 } 74 75 public void setProxyPort(int proxyPort) { 76 this.proxyPort = proxyPort; 77 } 78 } 79 | Popular Tags |