org.ogf.graap.wsag.samples.pendingagreement
Class CreatePendingAgreementWithNotificationAction

java.lang.Object
  extended by org.ogf.graap.wsag.server.actions.AbstractCreateAgreementAction
      extended by org.ogf.graap.wsag.samples.pendingagreement.CreatePendingAgreementWithNotificationAction
All Implemented Interfaces:
IActionHandler, ICreateAgreementAction

public class CreatePendingAgreementWithNotificationAction
extends AbstractCreateAgreementAction

CreatePendingAgreementAction This class shows an example for a long lasting agreement creation process.

Author:
Oliver Waeldrich

Constructor Summary
CreatePendingAgreementWithNotificationAction()
           
 
Method Summary
 Agreement createAgreement(AgreementOffer offer, Map<String,Object> invocationCtx)
          Example for a long lasting agreement creation process.
 void initialize()
          Initializes the action.
 
Methods inherited from class org.ogf.graap.wsag.server.actions.AbstractCreateAgreementAction
createAgreement, getHandlerContext, setHandlerContext
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

CreatePendingAgreementWithNotificationAction

public CreatePendingAgreementWithNotificationAction()
Method Detail

createAgreement

public Agreement createAgreement(AgreementOffer offer,
                                 Map<String,Object> invocationCtx)
                          throws AgreementFactoryException
Example for a long lasting agreement creation process. Creates a new agreement based on an offer.

Specified by:
createAgreement in interface ICreateAgreementAction
Overrides:
createAgreement in class AbstractCreateAgreementAction
Parameters:
offer - the offer to create an agreement for
invocationCtx - factory invocation context
Returns:
the created agreement
Throws:
AgreementFactoryException - indicates that the agreement offer was rejected or a factory fault occurred.

initialize

public void initialize()
                throws ActionInitializationException
Initializes the action. Default implementation of action initialization. Subclasses may overwrite this method in order to provide a custom initialization of a handler. Initializes an action handler. This method is called when a agreement factory action initializes its action handlers. It is called once during the the engine initialization.

Specified by:
initialize in interface IActionHandler
Overrides:
initialize in class AbstractCreateAgreementAction
Throws:
ActionInitializationException - Indicates an error during handler initialization.


Copyright © 2008-2012. All Rights Reserved.