|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectmicrosoft.exchange.webservices.data.ExchangeServiceBase
public abstract class ExchangeServiceBase
Represents an abstract binding to an Exchange Service.
| Constructor Summary | |
|---|---|
protected |
ExchangeServiceBase()
|
protected |
ExchangeServiceBase(ExchangeServiceBase service)
Initializes a new instance from existing one. |
protected |
ExchangeServiceBase(ExchangeServiceBase service,
ExchangeVersion requestedServerVersion)
|
protected |
ExchangeServiceBase(ExchangeVersion requestedServerVersion)
* Initializes a new instance. |
protected |
ExchangeServiceBase(ExchangeVersion requestedServerVersion,
TimeZone timeZone)
|
protected |
ExchangeServiceBase(TimeZone timeZone)
|
| Method Summary | |
|---|---|
static boolean |
checkURIPath(String location)
|
protected String |
convertDateTimeToUniversalDateTimeString(Date dt)
Converts the date time to universal date time string. |
protected Date |
convertStartDateToUnspecifiedDateTime(String value)
Converts xs:dateTime string with either "Z", "-00:00" bias, or "" suffixes to unspecified StartDate value ignoring the suffix.Needs to fix E14:232996. |
protected Date |
convertUniversalDateTimeStringToDate(String dateString)
Converts the universal date time string to local date time. |
protected void |
doOnSerializeCustomSoapHeaders(XMLStreamWriter writer)
Calls the custom SOAP header serialisation event handlers, if defined. |
boolean |
getAcceptGzipEncoding()
Gets a value indicating whether GZip compression encoding should be accepted. |
String |
getCookie(URL url)
Gets the cookie. |
ExchangeCredentials |
getCredentials()
Gets the credentials used to authenticate with the Exchange Web Services. |
Map<String,String> |
getHttpHeaders()
Gets a collection of HTTP headers that will be sent with each request to EWS. |
List<microsoft.exchange.webservices.data.ICustomXmlSerialization> |
getOnSerializeCustomSoapHeaders()
Gets the on serialize custom soap headers. |
ExchangeVersion |
getRequestedServerVersion()
Gets the requested server version. |
ExchangeServerInfo |
getServerInfo()
* Gets information associated with the server that processed the last request. |
protected org.apache.commons.httpclient.HttpConnectionManager |
getSimpleHttpConnectionManager()
Static members |
int |
getTimeout()
Gets the timeout used when sending HTTP requests and when receiving HTTP responses, in milliseconds. |
EnumSet<TraceFlags> |
getTraceFlags()
Gets the trace flags. |
ITraceListener |
getTraceListener()
Gets the trace listener. |
boolean |
getUseDefaultCredentials()
Gets a value indicating whether the credentials of the user currently logged into Windows should be used to authenticate with the Exchange Web Services. |
String |
getUserAgent()
Gets the user agent. |
WebProxy |
getWebProxy()
Gets the web proxy that should be used when sending requests to EWS. |
protected void |
internalProcessHttpErrorResponse(microsoft.exchange.webservices.data.HttpWebRequest httpWebResponse,
Exception webException,
TraceFlags responseHeadersTraceFlag,
TraceFlags responseTraceFlag)
|
boolean |
isPreAuthenticate()
Gets a value that indicates whether HTTP pre-authentication should be performed. |
boolean |
isTraceEnabled()
Gets a value indicating whether tracing is enabled. |
protected boolean |
isTraceEnabledFor(TraceFlags traceFlags)
Determines whether tracing is enabled for specified trace flag(s). |
protected microsoft.exchange.webservices.data.HttpWebRequest |
prepareHttpWebRequestForUrl(URI url,
boolean acceptGzipEncoding,
boolean allowAutoRedirect)
* Creates an HttpWebRequest instance and initialises it with the appropriate parameters, based on the configuration of this service object. |
protected abstract void |
processHttpErrorResponse(microsoft.exchange.webservices.data.HttpWebRequest httpWebResponse,
Exception webException)
|
void |
setAcceptGzipEncoding(boolean acceptGzipEncoding)
Gets a value indicating whether GZip compression encoding should be accepted. |
void |
setCookie(URL url,
String value)
Gets the cookie container. |
void |
setCredentials(ExchangeCredentials credentials)
Sets the credentials used to authenticate with the Exchange Web Services. |
protected void |
setCustomUserAgent(String userAgent)
Sets the user agent to a custom value |
void |
setOnSerializeCustomSoapHeaders(List<microsoft.exchange.webservices.data.ICustomXmlSerialization> onSerializeCustomSoapHeaders)
Sets the on serialize custom soap headers. |
void |
setPreAuthenticate(boolean preAuthenticate)
Sets a value that indicates whether HTTP pre-authentication should be performed. |
void |
setTimeout(int timeout)
Sets the timeout used when sending HTTP requests and when receiving HTTP respones, in milliseconds. |
void |
setTraceEnabled(boolean traceEnabled)
Sets a value indicating whether tracing is enabled. |
void |
setTraceFlags(EnumSet<TraceFlags> traceFlags)
Sets the trace flags. |
void |
setTraceListener(ITraceListener traceListener)
Sets the trace listener. |
void |
setUseDefaultCredentials(boolean value)
* Sets a value indicating whether the credentials of the user currently logged into Windows should be used to authenticate with the Exchange Web Services. |
void |
setUserAgent(String userAgent)
Sets the user agent. |
void |
setWebProxy(WebProxy value)
Sets the web proxy that should be used when sending requests to EWS. |
protected void |
traceHttpRequestHeaders(TraceFlags traceType,
microsoft.exchange.webservices.data.HttpWebRequest request)
Traces the HTTP request headers. |
protected void |
traceHttpResponseHeaders(TraceFlags traceType,
microsoft.exchange.webservices.data.HttpWebRequest request)
* Traces the HTTP response headers. |
protected void |
traceMessage(TraceFlags traceType,
String logEntry)
* Logs the specified string to the TraceListener if tracing is enabled. |
protected void |
traceXml(TraceFlags traceType,
ByteArrayOutputStream stream)
Logs the specified XML to the TraceListener if tracing is enabled. |
protected void |
validate()
* Validates this instance. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
protected ExchangeServiceBase(ExchangeServiceBase service,
ExchangeVersion requestedServerVersion)
service - requestedServerVersion - protected ExchangeServiceBase(ExchangeServiceBase service)
service - The other service.ExchangeServiceBaseprotected ExchangeServiceBase()
protected ExchangeServiceBase(ExchangeVersion requestedServerVersion,
TimeZone timeZone)
protected ExchangeServiceBase(TimeZone timeZone)
protected ExchangeServiceBase(ExchangeVersion requestedServerVersion)
requestedServerVersion - The requested server version.| Method Detail |
|---|
protected org.apache.commons.httpclient.HttpConnectionManager getSimpleHttpConnectionManager()
protected void doOnSerializeCustomSoapHeaders(XMLStreamWriter writer)
writer - The XmlWriter to which to write the custom SOAP headers.
protected microsoft.exchange.webservices.data.HttpWebRequest prepareHttpWebRequestForUrl(URI url,
boolean acceptGzipEncoding,
boolean allowAutoRedirect)
throws ServiceLocalException,
URISyntaxException
url - The URL that the HttpWebRequest should target.acceptGzipEncoding - If true, ask server for GZip compressed content.allowAutoRedirect - If true, redirection responses will be automatically followed.
ServiceLocalException - the service local exception
URISyntaxException - the uRI syntax exception
protected void internalProcessHttpErrorResponse(microsoft.exchange.webservices.data.HttpWebRequest httpWebResponse,
Exception webException,
TraceFlags responseHeadersTraceFlag,
TraceFlags responseTraceFlag)
throws Exception
httpWebResponse - webException - responseHeadersTraceFlag - responseTraceFlag -
Exceptionpublic static boolean checkURIPath(String location)
location -
protected abstract void processHttpErrorResponse(microsoft.exchange.webservices.data.HttpWebRequest httpWebResponse,
Exception webException)
throws Exception
httpWebResponse - webException -
Exceptionprotected boolean isTraceEnabledFor(TraceFlags traceFlags)
traceFlags - The trace flags.
protected void traceMessage(TraceFlags traceType,
String logEntry)
throws XMLStreamException,
IOException
traceType - Kind of trace entry.logEntry - The entry to log.
XMLStreamException - the xML stream exception
IOException - Signals that an I/O exception has occurred.
protected void traceXml(TraceFlags traceType,
ByteArrayOutputStream stream)
traceType - Kind of trace entry.stream - The stream containing XML.
protected void traceHttpRequestHeaders(TraceFlags traceType,
microsoft.exchange.webservices.data.HttpWebRequest request)
throws URISyntaxException,
EWSHttpException,
XMLStreamException,
IOException
traceType - Kind of trace entry.request - The request
EWSHttpException
URISyntaxException
IOException
XMLStreamException
protected void traceHttpResponseHeaders(TraceFlags traceType,
microsoft.exchange.webservices.data.HttpWebRequest request)
throws XMLStreamException,
IOException,
EWSHttpException
traceType - Kind of trace entry.request - The HttpRequest object.
XMLStreamException - the xML stream exception
IOException - Signals that an I/O exception has occurred.
EWSHttpException - the eWS http exceptionprotected Date convertUniversalDateTimeStringToDate(String dateString)
dateString - The value.
protected Date convertStartDateToUnspecifiedDateTime(String value)
throws ParseException
value - The string value to parse.
ParseExceptionprotected String convertDateTimeToUniversalDateTimeString(Date dt)
dt - the date
protected void setCustomUserAgent(String userAgent)
userAgent - User agent string to set on the service
protected void validate()
throws ServiceLocalException
ServiceLocalException - the service local exception
public void setCookie(URL url,
String value)
throws IOException,
URISyntaxException
url - the urlvalue - the value
IOException - , URISyntaxException
URISyntaxException - the uRI syntax exception
public String getCookie(URL url)
throws IOException,
URISyntaxException
url - the url
IOException - Signals that an I/O exception has occurred.
URISyntaxException - the uRI syntax exceptionpublic boolean isTraceEnabled()
public void setTraceEnabled(boolean traceEnabled)
traceEnabled - true to enable tracingpublic EnumSet<TraceFlags> getTraceFlags()
public void setTraceFlags(EnumSet<TraceFlags> traceFlags)
traceFlags - A set of trace flagspublic ITraceListener getTraceListener()
public void setTraceListener(ITraceListener traceListener)
traceListener - the trace listener.public ExchangeCredentials getCredentials()
public void setCredentials(ExchangeCredentials credentials)
credentials - Exchange credentials.public boolean getUseDefaultCredentials()
public void setUseDefaultCredentials(boolean value)
value - the new use default credentialspublic int getTimeout()
public void setTimeout(int timeout)
timeout - timeout in millisecondspublic boolean isPreAuthenticate()
public void setPreAuthenticate(boolean preAuthenticate)
preAuthenticate - true to enable pre-authenticationpublic boolean getAcceptGzipEncoding()
public void setAcceptGzipEncoding(boolean acceptGzipEncoding)
acceptGzipEncoding - true to enable compressionpublic ExchangeVersion getRequestedServerVersion()
public String getUserAgent()
public void setUserAgent(String userAgent)
userAgent - The user agentpublic ExchangeServerInfo getServerInfo()
public WebProxy getWebProxy()
public void setWebProxy(WebProxy value)
value - the Proxy Informationpublic Map<String,String> getHttpHeaders()
public List<microsoft.exchange.webservices.data.ICustomXmlSerialization> getOnSerializeCustomSoapHeaders()
public void setOnSerializeCustomSoapHeaders(List<microsoft.exchange.webservices.data.ICustomXmlSerialization> onSerializeCustomSoapHeaders)
onSerializeCustomSoapHeaders - the new on serialize custom soap headers
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||