ibspan.ecap.merchant.shopdecisions.negotiationpreparation
Class TemplatePreparer

java.lang.Object
  extended by ibspan.ecap.merchant.shopdecisions.negotiationpreparation.TemplatePreparer

public class TemplatePreparer
extends java.lang.Object

A class preparing the negotiation templates.

Author:
Micha³ Drozdowicz

Nested Class Summary
 class TemplatePreparer.AmountInputData
           
 class TemplatePreparer.PriceInputData
           
 
Constructor Summary
TemplatePreparer()
           
 
Method Summary
 double evaluateStartingPrice(java.lang.String productId, java.util.Date date, NegotiationDescription previousTemplate)
           
 NegotiationDescription prepareTemplate(java.lang.String productId, java.util.Date date, NegotiationDescription previousTemplate)
          Prepares a negotiation template for a given product.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TemplatePreparer

public TemplatePreparer()
Method Detail

prepareTemplate

public NegotiationDescription prepareTemplate(java.lang.String productId,
                                              java.util.Date date,
                                              NegotiationDescription previousTemplate)
Prepares a negotiation template for a given product.

Parameters:
productId - the id of the product for which a negotiation template should be prepared.
date - the date starting at which the template is to be used.
previousTemplate - the previously used template.
Returns:
the updated negotiation template.

evaluateStartingPrice

public double evaluateStartingPrice(java.lang.String productId,
                                    java.util.Date date,
                                    NegotiationDescription previousTemplate)
                             throws DataAccessException
Throws:
DataAccessException