Package nl.clockwork.mule.ebms.model.ebxml

Examples of nl.clockwork.mule.ebms.model.ebxml.AckRequested


    PartyInfo partyInfo = CPAUtils.getSendingPartyInfo(cpa,context.getFromRole(),context.getServiceType(),context.getService(),context.getAction());
    DeliveryChannel channel = CPAUtils.getDeliveryChannel(partyInfo.getCollaborationRole().get(0).getServiceBinding().getCanSend().get(0).getThisPartyActionBinding());

    if (PerMessageCharacteristicsType.ALWAYS.equals(channel.getMessagingCharacteristics().getAckRequested()))
    {
      AckRequested ackRequested = new AckRequested();
      ackRequested.setVersion(Constants.EBMS_VERSION);
      ackRequested.setMustUnderstand(true);
      ackRequested.setSigned(PerMessageCharacteristicsType.ALWAYS.equals(channel.getMessagingCharacteristics().getAckSignatureRequested()));
      ackRequested.setActor(channel.getMessagingCharacteristics().getActor().value());
      return ackRequested;
    }
    else
      return null;
  }
View Full Code Here


  public static EbMSMessage ebMSMessageContentToEbMSMessage(CollaborationProtocolAgreement cpa, EbMSMessageContent content, String hostname) throws DatatypeConfigurationException
  {
    MessageHeader messageHeader = createMessageHeader(cpa,content.getContext(),hostname);

    AckRequested ackRequested = createAckRequested(cpa,content.getContext());
   
    Manifest manifest = createManifest();
    for (int i = 0; i < content.getAttachments().size(); i++)
      manifest.getReference().add(createReference(i + 1));
   
View Full Code Here

          if (!checkDuplicateElimination(deliveryChannel,messageHeader))
          {
            message.setProperty(Constants.EBMS_ERROR,EbMSMessageUtils.createError("//Header/MessageHeader/DuplicateElimination",Constants.EbMSErrorCode.INCONSISTENT.errorCode(),"Wrong value."));
            return false;
          }
          AckRequested ackRequested = ((EbMSMessage)message.getPayload()).getAckRequested();
          if (!checkAckRequested(deliveryChannel))
          {
            message.setProperty(Constants.EBMS_ERROR,EbMSMessageUtils.createError("//Header/AckRequested",Constants.EbMSErrorCode.NOT_SUPPORTED.errorCode(),"AckRequested mode not supported."));
            return false;
          }
          if (!checkAckRequested(deliveryChannel,ackRequested))
          {
            message.setProperty(Constants.EBMS_ERROR,EbMSMessageUtils.createError("//Header/AckRequested",Constants.EbMSErrorCode.INCONSISTENT.errorCode(),"Wrong value."));
            return false;
          }
          if (ackRequested != null && !Constants.EBMS_VERSION.equals(ackRequested.getVersion()))
          {
            message.setProperty(Constants.EBMS_ERROR,EbMSMessageUtils.createError("//Header/AckRequested[@version]",Constants.EbMSErrorCode.INCONSISTENT.errorCode(),"Wrong value."));
            return false;
          }
          if (ackRequested != null && ackRequested.getActor() != null && ackRequested.getActor().equals(ActorType.URN_OASIS_NAMES_TC_EBXML_MSG_ACTOR_NEXT_MSH.value()))
          {
            message.setProperty(Constants.EBMS_ERROR,EbMSMessageUtils.createError("//Header/AckRequested[@actor]",Constants.EbMSErrorCode.NOT_SUPPORTED.errorCode(),"NextMSH not supported."));
            return false;
          }
          if (!checkAckSignatureRequested(deliveryChannel))
View Full Code Here

TOP

Related Classes of nl.clockwork.mule.ebms.model.ebxml.AckRequested

Copyright © 2018 www.massapicom. 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.