当前位置: 首页>>代码示例>>Java>>正文


Java OperationContext.isComplete方法代码示例

本文整理汇总了Java中org.apache.axis2.context.OperationContext.isComplete方法的典型用法代码示例。如果您正苦于以下问题:Java OperationContext.isComplete方法的具体用法?Java OperationContext.isComplete怎么用?Java OperationContext.isComplete使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在org.apache.axis2.context.OperationContext的用法示例。


在下文中一共展示了OperationContext.isComplete方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: addMessageContext

import org.apache.axis2.context.OperationContext; //导入方法依赖的package包/类
public void addMessageContext(MessageContext msgContext,
                              OperationContext opContext) throws AxisFault {
    if (!opContext.isComplete()) {
        opContext.getMessageContexts().put(MESSAGE_LABEL_OUT_VALUE,
                msgContext);
        opContext.setComplete(true);
    } else {
        throw new AxisFault(Messages.getMessage("mepcompleted"));
    }
}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:11,代码来源:OutOnlyAxisOperation.java

示例2: registerOperationContext

import org.apache.axis2.context.OperationContext; //导入方法依赖的package包/类
public void registerOperationContext(MessageContext msgContext,
                                     OperationContext operationContext)
        throws AxisFault {
    msgContext.setAxisOperation(this);
    msgContext.getConfigurationContext().registerOperationContext(msgContext.getMessageID(),
                                                                  operationContext);
    operationContext.addMessageContext(msgContext);
    msgContext.setOperationContext(operationContext);
    if (operationContext.isComplete()) {
        operationContext.cleanup();
    }
}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:13,代码来源:AxisOperation.java

示例3: registerMessageContext

import org.apache.axis2.context.OperationContext; //导入方法依赖的package包/类
public void registerMessageContext(MessageContext msgContext,
                                   OperationContext operationContext) throws AxisFault {
    msgContext.setAxisOperation(this);
    operationContext.addMessageContext(msgContext);
    msgContext.setOperationContext(operationContext);
    if (operationContext.isComplete()) {
        operationContext.cleanup();
    }
}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:10,代码来源:AxisOperation.java

示例4: addMessageContext

import org.apache.axis2.context.OperationContext; //导入方法依赖的package包/类
public void addMessageContext(MessageContext msgContext, OperationContext opContext)
        throws AxisFault {
    if (!opContext.isComplete()) {
        opContext.getMessageContexts().put(MESSAGE_LABEL_IN_VALUE, msgContext);
        opContext.setComplete(true);
    } else {
        throw new AxisFault(Messages.getMessage("mepcompleted"));
    }
}
 
开发者ID:wso2,项目名称:wso2-axis2,代码行数:10,代码来源:InOnlyAxisOperation.java

示例5: flowComplete

import org.apache.axis2.context.OperationContext; //导入方法依赖的package包/类
@Override
// Handle IN_ONLY operations
public void flowComplete(MessageContext msgContext) {
    if (msgContext.getEnvelope() == null) {
        return;
    }
    AxisService axisService = msgContext.getAxisService();
    if (axisService == null ||
        SystemFilter.isFilteredOutService(axisService.getAxisServiceGroup()) ||
        axisService.isClientSide()) {
        return;
    }

    try {
        // Process Request Counter
        OperationContext opContext = msgContext.getOperationContext();
        if (opContext != null && opContext.isComplete()) {
            AxisOperation axisOp = opContext.getAxisOperation();
            if (axisOp != null && axisOp.isControlOperation()) {
                return;
            }
            if (axisOp != null) {
                String mep = axisOp.getMessageExchangePattern();
                if (mep != null &&
                    (mep.equals(WSDL2Constants.MEP_URI_IN_ONLY) ||
                     mep.equals(WSDL2Constants.MEP_URI_ROBUST_IN_ONLY))) {

                    // Increment operation counter
                    final AxisOperation axisOperation = msgContext.getAxisOperation();
                    if (axisOperation != null) {
                        Parameter operationParameter =
                                axisOperation.getParameter(StatisticsConstants.IN_OPERATION_COUNTER);
                        if (operationParameter != null) {
                            ((AtomicInteger) operationParameter.getValue()).incrementAndGet();
                        } else {
                            log.error(StatisticsConstants.IN_OPERATION_COUNTER +
                                      " has not been set for operation " +
                                      axisService.getName() + "." + axisOperation.getName());
                            return;
                        }

                        // Calculate response times
                        try {
                            ResponseTimeCalculator.calculateResponseTimes(msgContext);
                        } catch (AxisFault axisFault) {
                            log.error("Cannot compute response times", axisFault);
                        }
                    }

                    // Increment global counter
                    Parameter globalRequestCounter =
                            msgContext.getParameter(StatisticsConstants.GLOBAL_REQUEST_COUNTER);
                    ((AtomicInteger) globalRequestCounter.getValue()).incrementAndGet();

                    updateCurrentInvocationGlobalStatistics(msgContext);
                }
            }
        }
    } catch (Throwable e) {  // Catching Throwable since exceptions here should not be propagated up
        log.error("Could not call InOnlyMEPHandler.flowComplete", e);
    }
}
 
开发者ID:wso2,项目名称:carbon-commons,代码行数:63,代码来源:InOnlyMEPHandler.java


注:本文中的org.apache.axis2.context.OperationContext.isComplete方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。