Platform SDK Java 8.5 API Reference

com.genesyslab.platform.webmedia.protocol
Class EspEmailProtocol

java.lang.Object
  extended by com.genesyslab.platform.commons.protocol.AbstractChannel
      extended by com.genesyslab.platform.commons.protocol.DuplexChannel
          extended by com.genesyslab.platform.commons.protocol.ClientChannel
              extended by com.genesyslab.platform.openmedia.protocol.ExternalServiceProtocol
                  extended by com.genesyslab.platform.webmedia.protocol.EspEmailProtocol
All Implemented Interfaces:
AsyncChannel, AsyncChannelOperations, AsyncInvokerSupport, Channel, ChannelListenerSupport, ConfigurationSupport, ConnectionInvokerSupport, EndpointSupport, InputChannel, InterceptorSupport, LogMessageFilterSupport, MessageReceiver, MessageReceiverManagement, OutputChannel, Protocol, ProtocolDescriptionSupport, Receiver, ReceiverManagement, RequestChannel, RequestorInfoSupport, EspEmailProtocolHandshakeOptions

@ProtocolDescription.Tag(sdkName="WebMedia",
                         protocolName="EspEmail")
public class EspEmailProtocol
extends ExternalServiceProtocol
implements EspEmailProtocolHandshakeOptions

Use an EspEmailProtocol object to establish communication between client application and ESP based Email Server.


Nested Class Summary
 
Nested classes/interfaces inherited from class com.genesyslab.platform.commons.protocol.ClientChannel
ClientChannel.BasicClientHandshakeStep, ClientChannel.ClientHandshakeStep, ClientChannel.RegistrationHandler, ClientChannel.SimpleRegistrationHandler
 
Nested classes/interfaces inherited from class com.genesyslab.platform.commons.protocol.AbstractChannel
AbstractChannel.AsyncErrorNotifier
 
Field Summary
static ProtocolDescription PROTOCOL_DESCRIPTION
           
 
Fields inherited from class com.genesyslab.platform.openmedia.protocol.ExternalServiceProtocol
USE_UTF_FOR_REQUESTS
 
Fields inherited from class com.genesyslab.platform.commons.protocol.DuplexChannel
messageFilter
 
Fields inherited from interface com.genesyslab.platform.commons.protocol.Receiver
DEF_INPUT_SIZE
 
Fields inherited from interface com.genesyslab.platform.commons.protocol.Channel
DEFAULT_TIMEOUT, INFINITE_TIMEOUT
 
Constructor Summary
EspEmailProtocol()
          Creates a new instance of the ESP based Genesys EmailServer protocol client.
EspEmailProtocol(Endpoint endpoint)
          Creates a new instance of the ESP based Genesys EmailServer protocol client.
EspEmailProtocol(Endpoint endpoint, ReferenceBuilder refBuilder)
          Creates a new instance of the ESP based Genesys EmailServer protocol client.
 
Method Summary
 void doSend(Message message)
          Sends the message unconditionally.
protected static Message fromEsp(DuplexChannel channel, Message esp)
           
protected  Message fromEsp(Message esp)
           
 java.lang.String getClientApplicationType()
          Returns client application type for the Genesys EMail Server connection.
 java.lang.String getClientName()
          Returns client name for the Email Server connection handshake.
 ProtocolDescription getProtocolDescription()
           
protected  void onReceiveMessage(Message message)
          Gives to subclass a chance to perform some operations on incoming message arrival before delivering it to connection user code.
protected static Message processEvent(DuplexChannel channel, Message msg, ILogger log)
           
protected  Message processEvent(Message msg)
           
protected static Message processSentMesage(DuplexChannel channel, Message message, ReferenceBuilder referenceBuilder)
           
 void setClientApplicationType(java.lang.String clientAppType)
          Sets client application type for the Genesys EMail Server connection.
 void setClientName(java.lang.String clientName)
          Sets the Email Server client name for connection handshake procedure.
protected static Message toEsp(DuplexChannel channel, Message msg)
           
protected  Message toEsp(Message msg)
           
 
Methods inherited from class com.genesyslab.platform.openmedia.protocol.ExternalServiceProtocol
fromEspRequestorInfo, getRequestorInfo, getTKVPrinter, setRequestorInfo, setTKVPrinter, toEspRequestorInfo
 
Methods inherited from class com.genesyslab.platform.commons.protocol.ClientChannel
beginClose, beginOpen, beginRequest, close, close, closeAsync, closeAsync, disableConnectionOperations, doBeginRequest, doBeginRequest, doRequest, endRequest, endRequest, fireUnsolicitedEvents, getCopyResponse, getInvoker, getOpenTimeoutException, getReferenceBuilder, onOpen, onSend, onUnexpectedHandshakeMessage, open, openAsync, openAsync, request, request, requestAsync, requestAsync, setAddressResolver, setAddressResolverParams, setAddressResolverParams, setCopyResponse, setEndpoint, setHandshakeFinished, setHandshakePhase, setHandshakeUnsolicitedEventsPassLimit, setRegistrationHandler, setState, submitRegMessage, throwOnUnReferenceableRequest
 
Methods inherited from class com.genesyslab.platform.commons.protocol.DuplexChannel
addListener, applyConfiguration, cancelCloseTimeout, cancelOpenTimeout, clearInput, close, closeAsync, createChannelClosedEvent, createConnection, createConnectionClosedEvent, doBeginClose, doClose, downgradeConnection, getDefaultRestriction, getEnpointPrefixInfo, getInputSize, getInterceptor, getLocalEndPoint, getLocalEndpointInfo, getLogMessageFilter, getProtocolFactory, getProtocolId, getRemoteEndPoint, getTimeoutException, initPackager, isMessageAllowed, notifyWithObject, onClose, onFireClosed, onFireErrorEvent, onFireOpened, open, openAsync, openAsync, processClose, processCloseAll, receive, receive, receivedMessage, releaseReceivers, removeListener, resetReceiver, resumeReading, send, setConnectionInvoker, setExternalTransport, setInputSize, setLogMessageFilter, setMessageHandler, setProtocolData, setReceiver, startUpgradeConnection, stopReading, toString, triggerWithObject, upgradeConnection, waitForObject
 
Methods inherited from class com.genesyslab.platform.commons.protocol.AbstractChannel
addChannelListener, configure, connectionContext, copyTLSSettings, fireClosed, fireErrorEvent, fireErrorEvent, generateChannelId, getChannelId, getConfiguration, getDefaultInvoker, getEndpoint, getListenerHelper, getServerContext, getState, getStateMods, getTimeout, internal, onSetEndpoint, releaseDefaultInvoker, removeChannelListener, setConfiguration, setInvoker, setServerContext, setState, setTimeout, throwNotClosed, throwNotOpened, throwNotOpenedOnClose, throwNotOpenedOnSend, throwNull, throwNullEndpoint
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.Protocol
getProtocolId
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.InputChannel
setMessageHandler
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.MessageReceiver
receive, receive
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.Receiver
clearInput, getInputSize, releaseReceivers, setInputSize
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.OutputChannel
addListener, removeListener, send
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.Channel
close, getTimeout, open, setTimeout
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.AsyncChannel
getState
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.ChannelListenerSupport
addChannelListener, removeChannelListener
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.InterceptorSupport
getInterceptor
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.MessageReceiverManagement
setReceiver
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.ReceiverManagement
resetReceiver
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.ConfigurationSupport
configure, getConfiguration
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.EndpointSupport
getEndpoint
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.AsyncInvokerSupport
setInvoker
 
Methods inherited from interface com.genesyslab.platform.commons.protocol.ConnectionInvokerSupport
setConnectionInvoker
 

Field Detail

PROTOCOL_DESCRIPTION

public static final ProtocolDescription PROTOCOL_DESCRIPTION
Constructor Detail

EspEmailProtocol

public EspEmailProtocol()
Creates a new instance of the ESP based Genesys EmailServer protocol client.


EspEmailProtocol

public EspEmailProtocol(Endpoint endpoint)
Creates a new instance of the ESP based Genesys EmailServer protocol client.

Parameters:
endpoint - the server endpoint you wish to connect to.

EspEmailProtocol

public EspEmailProtocol(Endpoint endpoint,
                        ReferenceBuilder refBuilder)
Creates a new instance of the ESP based Genesys EmailServer protocol client.

Parameters:
endpoint - the server endpoint you wish to connect to.
refBuilder - external reference builder instance.
Method Detail

getProtocolDescription

public ProtocolDescription getProtocolDescription()
Specified by:
getProtocolDescription in interface ProtocolDescriptionSupport
Overrides:
getProtocolDescription in class DuplexChannel

processSentMesage

protected static Message processSentMesage(DuplexChannel channel,
                                           Message message,
                                           ReferenceBuilder referenceBuilder)
                                    throws ProtocolException
Throws:
ProtocolException

doSend

public void doSend(Message message)
            throws ProtocolException
Description copied from class: DuplexChannel
Sends the message unconditionally. Doesn't check channel state. Use with caution. Intended for using in registration process.

Overrides:
doSend in class DuplexChannel
Parameters:
message - message to send
Throws:
ProtocolException - In the case of an unrecoverable protocol error. Client applications should not try to deal with these exceptions, except for logging or displaying to users or technical administrators. Check the exception cause for more details.

processEvent

protected Message processEvent(Message msg)

processEvent

protected static Message processEvent(DuplexChannel channel,
                                      Message msg,
                                      ILogger log)

onReceiveMessage

protected void onReceiveMessage(Message message)
Description copied from class: DuplexChannel
Gives to subclass a chance to perform some operations on incoming message arrival before delivering it to connection user code. We don't use AsyncInvoker here, because the message handling in this class probably doesn't worth it - this method is quick and shouldn't load connection thread too much. But if this method is overridden in some classes and contains some long-running logic, consider using AsyncInvoker

Overrides:
onReceiveMessage in class ClientChannel
Parameters:
message - received message

setClientName

public void setClientName(java.lang.String clientName)
Sets the Email Server client name for connection handshake procedure. Usually it represents application name of this Email Server client.

Specified by:
setClientName in interface EspEmailProtocolHandshakeOptions
Parameters:
clientName - client name

getClientName

public java.lang.String getClientName()
Returns client name for the Email Server connection handshake. Usually it represents application name of this Email Server client.

Specified by:
getClientName in interface EspEmailProtocolHandshakeOptions
Returns:
client name
See Also:
setClientName(String)

getClientApplicationType

public java.lang.String getClientApplicationType()
Returns client application type for the Genesys EMail Server connection. Usually it represents application type in Configuration Server.

Specified by:
getClientApplicationType in interface EspEmailProtocolHandshakeOptions
Returns:
client application type
See Also:
setClientApplicationType(String)

setClientApplicationType

public void setClientApplicationType(java.lang.String clientAppType)
Sets client application type for the Genesys EMail Server connection. Usually it represents application type in Configuration Server.

Specified by:
setClientApplicationType in interface EspEmailProtocolHandshakeOptions
Parameters:
clientAppType - client application type

fromEsp

protected Message fromEsp(Message esp)

fromEsp

protected static Message fromEsp(DuplexChannel channel,
                                 Message esp)

toEsp

protected Message toEsp(Message msg)

toEsp

protected static Message toEsp(DuplexChannel channel,
                               Message msg)

Platform SDK Java 8.5 API Reference

Send comments on this topicTechpubs.webadmin@genesys.com.
Document version: 8.5.302.00
Copyright © 2006–2017 Genesys Telecommunications Laboratories, Inc. All rights reserved.