public class InvocationServer extends java.lang.Object implements Dependency
Constructor and Description |
---|
InvocationServer(InvocationBuilder builder) |
Modifier and Type | Method and Description |
---|---|
void |
addServerListener(ServerListener listener)
Adds a listener.
|
Invocation |
buildInvocation(Invocation invocation)
Builds the invocation.
|
Invocation |
buildInvocation(java.lang.Object protocolKey,
Invocation invocation)
Builds the invocation, saving its value keyed by the protocol key.
|
void |
clearCache()
Clears the invocation cache.
|
Invocation |
createInvocation()
Creates an invocation.
|
InvocationDecoder |
createInvocationDecoder()
Returns the invocation decoder for configuration.
|
void |
destroy()
Closes the server.
|
Invocation |
getInvocation(java.lang.Object protocolKey)
Returns the cached invocation.
|
InvocationBuilder |
getInvocationBuilder()
Gets the dispatch builder.
|
long |
getInvocationCacheHitCount()
Returns the invocation cache hit count.
|
long |
getInvocationCacheMissCount()
Returns the invocation cache hit count.
|
int |
getInvocationCacheSize() |
InvocationDecoder |
getInvocationDecoder()
Returns the InvocationDecoder.
|
java.util.ArrayList<Invocation> |
getInvocations()
Returns the invocations.
|
int |
getMaxURILength() |
java.lang.String |
getServerId()
Gets the server's id.
|
java.lang.String |
getURLCharacterEncoding()
Sets URL encoding.
|
void |
init()
Initializes the server.
|
void |
invalidateMatchingInvocations(InvocationMatcher matcher)
Clears matching entries.
|
boolean |
isDestroyed()
Returns true if the server is destroyed.
|
boolean |
isModified()
Returns true if the server has been modified and needs restarting.
|
boolean |
logModified(java.util.logging.Logger log)
Log the reason for modification.
|
void |
setInvocationCacheMaxURLLength(int length)
Sets the max url length.
|
void |
setInvocationCacheSize(int size)
Sets the invocation cache size.
|
void |
setMaxURILength(int maxURILength)
Sets max uri length
|
void |
setServerId(java.lang.String serverId)
Gets the server's id.
|
public InvocationServer(InvocationBuilder builder)
public java.lang.String getServerId()
public void setServerId(java.lang.String serverId)
public InvocationBuilder getInvocationBuilder()
public void setInvocationCacheSize(int size)
public int getInvocationCacheSize()
public void setInvocationCacheMaxURLLength(int length)
public int getMaxURILength()
public void setMaxURILength(int maxURILength)
@PostConstruct public void init()
public InvocationDecoder getInvocationDecoder()
public java.lang.String getURLCharacterEncoding()
public InvocationDecoder createInvocationDecoder()
public final Invocation getInvocation(java.lang.Object protocolKey)
public Invocation createInvocation()
public Invocation buildInvocation(java.lang.Object protocolKey, Invocation invocation) throws ConfigException
protocolKey
- protocol-specific key to save the invocation ininvocation
- the invocation to build.ConfigException
public Invocation buildInvocation(Invocation invocation) throws ConfigException
ConfigException
public void clearCache()
public void invalidateMatchingInvocations(InvocationMatcher matcher)
public java.util.ArrayList<Invocation> getInvocations()
public long getInvocationCacheHitCount()
public long getInvocationCacheMissCount()
public boolean isModified()
isModified
in interface Dependency
public boolean logModified(java.util.logging.Logger log)
logModified
in interface Dependency
public void addServerListener(ServerListener listener)
public boolean isDestroyed()
public void destroy()