Examples of ResultsType


Examples of com.google.checkout.schema._2.MerchantCalculationResults.ResultsType

      individualResult.setShippable(isShippable);
      individualResult.setShippingRate(createMoney(shippingRate));
      individualResult.setTotalTax(createMoney(totalTaxAmount));
      individualResult.setMerchantCodeResults(merchantCodeResults);
     
      ResultsType results
          = _objectFact.createMerchantCalculationResultsResultsType();
      results.getResult().add(individualResult);
      MerchantCalculationResults mResults
          = _objectFact.createMerchantCalculationResultsElement();
      mResults.setResults(results);
      return convertToDOM(mResults);
    } catch (JAXBException jaxbEx) {
View Full Code Here

Examples of gov.nist.scap.schema.ocil.x20.ResultsType

    this.status = AssessmentResult.Status.SUCCESSFUL;
    this.statusMessage = null;

    OcilDocument document = resultContext.getResultContent().getXmlObject();
    OCILType ocil = document.getOcil();
    ResultsType results = ocil.getResults();
    QuestionnaireResultsType questionnaireResults = (results != null) ? results
        .getQuestionnaireResults()
        : null;

    int mapSize = (questionnaireResults != null) ? questionnaireResults
        .sizeOfQuestionnaireResultArray() : 0;
View Full Code Here

Examples of org.jboss.jbossts.xts.servicetests.generated.ResultsType

    @WebResult(name = "results", targetNamespace = "http://jbossts.jboss.org/xts/servicetests/generated", partName = "results")
    public ResultsType serve(
        @WebParam(name = "commands", targetNamespace = "http://jbossts.jboss.org/xts/servicetests/generated", partName = "commands")
        CommandsType commands)
    {
        ResultsType results = new ResultsType();
        List<String> resultsList = results.getResultList();
        List<String> commandList = commands.getCommandList();

        MessageContext messageContext = context.getMessageContext();
        HttpServletRequest servletRequest = ((HttpServletRequest)messageContext.get(MessageContext.SERVLET_REQUEST));
        String path = servletRequest.getServletPath();
View Full Code Here

Examples of org.jboss.jbossts.xts.servicetests.generated.ResultsType

    @WebResult(name = "results", targetNamespace = "http://jbossts.jboss.org/xts/servicetests/generated", partName = "results")
    public ResultsType serve(
        @WebParam(name = "commands", targetNamespace = "http://jbossts.jboss.org/xts/servicetests/generated", partName = "commands")
        CommandsType commands)
    {
        ResultsType results = new ResultsType();
        List<String> resultsList = results.getResultList();
        List<String> commandList = commands.getCommandList();

        MessageContext messageContext = context.getMessageContext();
        HttpServletRequest servletRequest = ((HttpServletRequest)messageContext.get(MessageContext.SERVLET_REQUEST));
        String path = servletRequest.getServletPath();
View Full Code Here

Examples of org.jboss.jbossts.xts.servicetests.generated.ResultsType

                CommandsType newCommands = new CommandsType();
                List<String> newCommandList = newCommands.getCommandList();
                for (int i = 0; i < size; i++) {
                    newCommandList.add(commandList.get(i));
                }
                ResultsType subResults = serveSubordinate(url, newCommands);
                List<String> subResultsList = subResults.getResultList();
                size = subResultsList.size();
                for (idx = 0; idx < size; idx++) {
                    resultsList.add(subResultsList.get(idx));
                }
            } else if (command.equals("subtransaction")) {
// create subordinate AT transaction
// this is surplus to requirements since we should really be running against a service which uses
// the subordinate interposition JaxWS handler to install a subordinate transaction before
// entering the service method. we ought to test that handler rather than hand crank the
// interposition in the service
                TxContext currentTx;
                TxContext newTx;
                try {
                    currentTx = TransactionManager.getTransactionManager().currentTransaction();
                } catch (SystemException e) {
                    throw new WebServiceException("subtransaction currentTransaction() failed with exception " + e);
                }

                try {
                    UserTransaction userTransaction = UserTransactionFactory.userSubordinateTransaction();
                    userTransaction.begin();
                    newTx = TransactionManager.getTransactionManager().currentTransaction();
                } catch (Exception e) {
                    throw new WebServiceException("subtransaction begin() failed with exception " + e);
                }
                String id = transactionId("at");
                subordinateTransactionMap.put(id, newTx);
                resultsList.add(id);
            } else if (command.equals("subactivity")) {
// create subordinate BA transaction
// this is surplus ot requirements since we should really be running against a service which uses
// the subordinate interposition JaxWS handler to install a subordinate activity before
// entering the service method. we ought to test that handler rather than hand crank the
// interposition in the service
                TxContext currentTx;
                TxContext newTx;
                try {
                    currentTx = BusinessActivityManagerFactory.businessActivityManager().currentTransaction();
                } catch (SystemException e) {
                    throw new WebServiceException("subtransaction currentTransaction() failed with exception " + e);
                }

                try {
                    UserBusinessActivity userBusinessActivity = UserBusinessActivityFactory.userBusinessActivity();
                    // this is nto implemented yet!!!
                    // userBusinessActivity.beginSubordinate();
                    // and this will fail with a WrongStateException
                    userBusinessActivity.begin();
                    newTx = BusinessActivityManager.getBusinessActivityManager().currentTransaction();
                } catch (Exception e) {
                    throw new WebServiceException("subtransaction begin() failed with exception " + e);
                }
                String id = transactionId("ba");
                subordinateActivityMap.put(id, newTx);
                resultsList.add(id);
            } else if (command.equals("subtransactionserve")) {
// dispatch commands in a subordinate transaction or activity
                // we should find the id of a subordinate transaction, a web service URL
                // and a list of commands to dispatch to that transaction
                // the txid and url must be resolved if supplied as bindings
                String txId = bindCommand(commandList.remove(idx), bindings, true);
                size--;
                String url = bindCommand(commandList.remove(idx), bindings,  true);
                size--;

                TxContext newTx = subordinateTransactionMap.get(txId);
                if (newTx != null) {
                    try {
                        TransactionManager.getTransactionManager().resume(newTx);
                    } catch (Exception e) {
                        throw new WebServiceException("subtransactioncommands resume() failed with exception " + e);
                    }
                } else {
                    throw new WebServiceException("subtransactioncommands unknown subordinate transaction id " + txId);
                }
                // ok, now we install the relevant transaction and then just pass the commands on to
                // the web service

                // we allow unresolved variable references in the rest of the command list as
                // they may be satisfied by embedded bind commands

                bindCommands(commandList,  bindings,  false);

                CommandsType newCommands = new CommandsType();
                List<String> newCommandList = newCommands.getCommandList();
                for (int i = 0; i < size; i++) {
                    newCommandList.add(commandList.get(i));
                }
                ResultsType subResults = serveSubordinate(url, newCommands);
                List<String> subResultsList = subResults.getResultList();
                size = subResultsList.size();
                for (idx = 0; idx < size; idx++) {
                    resultsList.add(subResultsList.get(idx));
                }
            } else if (command.equals("subactivityserve")) {
// dispatch commands in a subordinate transaction or activity
                // we should find the id of a subordinate transaction, a web service URL
                // and a list of commands to dispatch to that transaction
                // the txid and url must be resolved if supplied as bindings
                String txId = bindCommand(commandList.remove(idx), bindings, true);
                size--;
                String url = bindCommand(commandList.remove(idx), bindings,  true);
                size--;

                TxContext newTx = subordinateActivityMap.get(txId);
                if (newTx != null) {
                    try {
                        TransactionManager.getTransactionManager().resume(newTx);
                    } catch (Exception e) {
                        throw new WebServiceException("subactivitycommands resume() failed with exception " + e);
                    }
                } else {
                    throw new WebServiceException("subactivitycommands unknown subordinate transaction id " + txId);
                }
                // ok, now we install the relevant transaction and then just pass the commands on to
                // the web service

                // we allow unresolved variable references in the rest of the command list as
                // they may be satisfied by embedded bind commands

                bindCommands(commandList, bindings,  false);

                CommandsType newCommands = new CommandsType();
                List<String> newCommandList = newCommands.getCommandList();
                for (int i = 0; i < size; i++) {
                    newCommandList.add(commandList.get(i));
                }
                ResultsType subResults = serveSubordinate(url, newCommands);
                List<String> subResultsList = subResults.getResultList();
                size = subResultsList.size();
                for (idx = 0; idx < size; idx++) {
                    resultsList.add(subResultsList.get(idx));
                }
            }
View Full Code Here

Examples of org.mitre.oval.xmlSchema.ovalResults5.ResultsType

    this.assessmentFile = assessmentFile;
    this.resultContext = resultContext;

    OvalResultsDocument document = resultContext.getResultContent().getXmlObject();
    OvalResultsDocument.OvalResults results = document.getOvalResults();
    ResultsType resultsType = results.getResults();
    List<SystemType> systems = resultsType.getSystemList();
    if (systems.size() != 1) {
      // TODO: P4: automatically resolve error?
      this.status = AssessmentResult.Status.ERROR;
      this.statusMessage = "OVAL result set contained results from multiple systems";
      definitionResultMap = Collections.emptyMap();
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.