public class OperationContext extends AbstractContext implements Externalizable, SafeSerializable
COPY_PROPERTIES, lastTouchedTime, parent, properties
Constructor and Description |
---|
OperationContext()
Simple constructor (needed for deserialization, shouldn't be used otherwise!)
|
OperationContext(AxisOperation axisOperation,
ServiceContext serviceContext)
Constructs a new OperationContext.
|
Modifier and Type | Method and Description |
---|---|
void |
activate(ConfigurationContext cc)
This method checks to see if additional work needs to be
done in order to complete the object reconstitution.
|
void |
addMessageContext(MessageContext msgContext)
When a new message is added to the
MEPContext the logic
should be included remove the MEPContext from the table in the
EngineContext . |
void |
cleanup()
Removes the pointers to this
OperationContext in the
ConfigurationContext 's OperationContextMap so that this
OperationContext will eventually get garbage collected
along with the MessageContext 's it contains. |
AxisOperation |
getAxisOperation() |
ConfigurationContext |
getConfigurationContext()
Returns the EngineContext in which the parent ServiceContext lives.
|
String |
getLogCorrelationIDString()
Get the ID associated with this object instance.
|
MessageContext |
getMessageContext(String messageLabel)
Get the message context identified by a given label.
|
HashMap<String,MessageContext> |
getMessageContexts() |
String |
getOperationName()
Get the name associated with the operation.
|
ConfigurationContext |
getRootContext() |
ServiceContext |
getServiceContext()
Returns the ServiceContext in which this OperationContext lives.
|
String |
getServiceGroupName()
Get the name associated with the service group.
|
String |
getServiceName()
Get the name associated with the service.
|
boolean |
isComplete()
Checks to see if the MEP is complete.
|
boolean |
isEquivalent(OperationContext ctx)
Compares key parts of the state from the current instance of
this class with the specified instance to see if they are
equivalent.
|
void |
isolateMessageContext(MessageContext mc)
Isolate the specified message context object
to prepare for serialization.
|
void |
readExternal(ObjectInput inObject)
Restore the contents of the object that was previously saved.
|
void |
removeMessageContext(String label)
Remove the indicated message context.
|
void |
restoreMessageContext(MessageContext msg)
Restore the specified MessageContext object in the
table used to hold the message contexts associated
with this operation.
|
void |
setComplete(boolean complete) |
void |
setKey(String key) |
void |
writeExternal(ObjectOutput o)
Save the contents of this object.
|
clearPropertyDifferences, flush, getLastTouchedTime, getLocalProperty, getParent, getProperties, getProperty, getPropertyDifferences, getPropertyNames, getPropertyNonReplicable, isAncestor, mergeProperties, removeProperty, removePropertyNonReplicable, setLastTouchedTime, setNonReplicableProperty, setParent, setProperties, setProperty, touch
public OperationContext()
public OperationContext(AxisOperation axisOperation, ServiceContext serviceContext)
axisOperation
- the AxisOperation whose running instances' state this
OperationContext represents.serviceContext
- the parent ServiceContext representing any state related to
the set of all operations of the service.public void addMessageContext(MessageContext msgContext) throws AxisFault
MEPContext
the logic
should be included remove the MEPContext from the table in the
EngineContext
. Example: IN_IN_OUT At the second IN
message the MEPContext should be removed from the AxisOperation.msgContext
- AxisFault
public void cleanup()
OperationContext
in the
ConfigurationContext
's OperationContextMap so that this
OperationContext
will eventually get garbage collected
along with the MessageContext
's it contains. Note that if
the caller wants to make sure its safe to clean up this OperationContext
he should call isComplete() first. However, in cases like IN_OPTIONAL_OUT
and OUT_OPTIONAL_IN, it is possibe this will get called without the MEP
being complete due to the optional nature of the MEP.public AxisOperation getAxisOperation()
public ConfigurationContext getConfigurationContext()
public MessageContext getMessageContext(String messageLabel) throws AxisFault
messageLabel
- The label of the message context to retrieve.
This should be one of the MESSAGE_LABEL_xxx
constants
defined in WSDLConstants
.null
if no
message context was foundAxisFault
- neverpublic void removeMessageContext(String label) throws AxisFault
label
- AxisFault
public HashMap<String,MessageContext> getMessageContexts()
public ServiceContext getServiceContext()
public boolean isComplete()
public void setComplete(boolean complete)
public void setKey(String key)
public void writeExternal(ObjectOutput o) throws IOException
writeExternal
in interface Externalizable
out
- The stream to write the object contents toIOException
public void readExternal(ObjectInput inObject) throws IOException, ClassNotFoundException
readExternal
in interface Externalizable
in
- The stream to read the object contents fromIOException
ClassNotFoundException
public void activate(ConfigurationContext cc)
cc
- The configuration context object representing the active configurationpublic void isolateMessageContext(MessageContext mc)
mc
- The message context objectpublic void restoreMessageContext(MessageContext msg)
msg
- The message context objectpublic String getOperationName()
public String getServiceName()
public String getServiceGroupName()
public boolean isEquivalent(OperationContext ctx)
ctx
- The object to compare withpublic String getLogCorrelationIDString()
public ConfigurationContext getRootContext()
getRootContext
in class AbstractContext
Copyright © 2004–2013 The Apache Software Foundation. All rights reserved.