Package com.arjuna.mwtests.wst.common

Examples of com.arjuna.mwtests.wst.common.DemoBusinessParticipant


  try
  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      com.arjuna.wst.BAParticipantManager bpm = null;
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.EXIT, "1234");
     
      uba.begin();
     
      bpm = bam.enlistForBusinessAgreementWithParticipantCompletion(p, "1234");

      bpm.exit();
     
      uba.close();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here


 
  try
  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.CANCEL, "1234");
      FailureBusinessParticipant fp = new FailureBusinessParticipant(FailureBusinessParticipant.FAIL_IN_CANCEL, "5678");
     
      uba.begin();
     
      bam.enlistForBusinessAgreementWithParticipantCompletion(p, "1234");
      bam.enlistForBusinessAgreementWithParticipantCompletion(fp, "5678");
     
      uba.close();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

 
  try
  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.CLOSE, "1234");
     
      uba.begin();
     
      bam.enlistForBusinessAgreementWithParticipantCompletion(p, null);
     
      uba.close();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

  try
  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      String participantId = "1234";
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.CANCEL, participantId);
     
      uba.begin();
     
      bam.enlistForBusinessAgreementWithParticipantCompletion(p, participantId);

      uba.cancel();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      com.arjuna.wst.BAParticipantManager bpm1 = null;
      com.arjuna.wst.BAParticipantManager bpm2 = null;
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.COMPENSATE, "1234");
      FailureBusinessParticipant fp = new FailureBusinessParticipant(FailureBusinessParticipant.FAIL_IN_COMPENSATE, "5678");
     
      uba.begin();
     
      bpm1 = bam.enlistForBusinessAgreementWithParticipantCompletion(p, "1234");
      bpm2 = bam.enlistForBusinessAgreementWithParticipantCompletion(fp, "5678");

      bpm1.completed();
      bpm2.completed();
     
      uba.cancel();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      com.arjuna.wst.BAParticipantManager bpm = null;
      String participantId = "1234";
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.COMPENSATE, participantId);
     
      uba.begin();
     
      bpm = bam.enlistForBusinessAgreementWithParticipantCompletion(p, participantId);

      bpm.completed();
     
      uba.cancel();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

 
  try
  {
      UserBusinessActivity uba = UserBusinessActivity.getUserBusinessActivity();
      BusinessActivityManager bam = BusinessActivityManager.getBusinessActivityManager();
      DemoBusinessParticipant p = new DemoBusinessParticipant(DemoBusinessParticipant.CLOSE, "1234");
      FailureBusinessParticipant fp = new FailureBusinessParticipant(FailureBusinessParticipant.FAIL_IN_CLOSE, "5678");
     
      uba.begin();
     
      bam.enlistForBusinessAgreementWithParticipantCompletion(p, null);
      bam.enlistForBusinessAgreementWithParticipantCompletion(fp, null);
     
      uba.close();

      passed = p.passed();
  }
  catch (Exception ex)
  {
      ex.printStackTrace();
  }
View Full Code Here

TOP

Related Classes of com.arjuna.mwtests.wst.common.DemoBusinessParticipant

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.