com.konakart.appif
Interface OrderTotalIf

All Known Implementing Classes:
OrderTotal

public interface OrderTotalIf

An order may have an array of OrderTotal objects. Each OrderTotal object is created by an OrderTotal module. Modules may be enabled / disabled using the Admin App so that you can decide whether your order shows tax, shipping charges, subtotal, discount etc.

There is an API call getOrderTotals() which is used to populate the order with an array of order totals.


Method Summary
 java.lang.String getClassName()
          This is the name of the order total module.
 java.lang.String getCustom1()
           
 java.lang.String getCustom2()
           
 java.lang.String getCustom3()
           
 int getId()
           
 int getOrderId()
           
 OrderTotalIf[] getOrderTotals()
          An array of OrderTotals which is populated if the OrderTotal module returns more than one result.
 PromotionIf[] getPromotions()
          An array to contain the promotion objects used to calculate the discount for a discount order total module.
 int getSortOrder()
          The sort order defines the order in which the order total items are added to the order.
 java.lang.String getText()
          This is the actual text for the value of the order total.
 java.lang.String getTitle()
          This is the title for the order total which will appear on a print out of the order.
 java.math.BigDecimal getValue()
          The value is a numeric representation of the text which can be used to add the order totals in order to calculate the final total.
 void setClassName(java.lang.String className)
          This is the name of the order total module.
 void setCustom1(java.lang.String custom1)
           
 void setCustom2(java.lang.String custom2)
           
 void setCustom3(java.lang.String custom3)
           
 void setId(int id)
           
 void setOrderId(int orderId)
           
 void setOrderTotals(OrderTotalIf[] orderTotals)
          An array of OrderTotals which is populated if the OrderTotal module returns more than one result.
 void setPromotions(PromotionIf[] promotions)
          An array to contain the promotion objects used to calculate the discount for a discount order total module.
 void setSortOrder(int sortOrder)
          The sort order defines the order in which the order total items are added to the order.
 void setText(java.lang.String text)
          This is the actual text for the value of the order total.
 void setTitle(java.lang.String title)
          This is the title for the order total which will appear on a print out of the order.
 void setValue(java.math.BigDecimal value)
          The value is a numeric representation of the text which can be used to add the order totals in order to calculate the final total.
 

Method Detail

getClassName

java.lang.String getClassName()
This is the name of the order total module. e.g. ot_shipping, ot_tax, ot_total

Returns:
Returns the className.

setClassName

void setClassName(java.lang.String className)
This is the name of the order total module. e.g. ot_shipping, ot_tax, ot_total

Parameters:
className - The className to set.

getId

int getId()
Returns:
Returns the id.

setId

void setId(int id)
Parameters:
id - The id to set.

getOrderId

int getOrderId()
Returns:
Returns the orderId.

setOrderId

void setOrderId(int orderId)
Parameters:
orderId - The orderId to set.

getSortOrder

int getSortOrder()
The sort order defines the order in which the order total items are added to the order. ot_total should be last since it adds up all of the other order totals to calculate the total of the order.

Returns:
Returns the sortOrder.

setSortOrder

void setSortOrder(int sortOrder)
The sort order defines the order in which the order total items are added to the order. ot_total should be last since it adds up all of the other order totals to calculate the total of the order.

Parameters:
sortOrder - The sortOrder to set.

getText

java.lang.String getText()
This is the actual text for the value of the order total. e.g. $95.00 or $90.00

Returns:
Returns the text.

setText

void setText(java.lang.String text)
This is the actual text for the value of the order total. e.g. $95.00 or $90.00

Parameters:
text - The text to set.

getTitle

java.lang.String getTitle()
This is the title for the order total which will appear on a print out of the order. e.g. Sub-Total: or Total:

Returns:
Returns the title.

setTitle

void setTitle(java.lang.String title)
This is the title for the order total which will appear on a print out of the order. e.g. Sub-Total: or Total:

Parameters:
title - The title to set.

getValue

java.math.BigDecimal getValue()
The value is a numeric representation of the text which can be used to add the order totals in order to calculate the final total.

Returns:
Returns the value.

setValue

void setValue(java.math.BigDecimal value)
The value is a numeric representation of the text which can be used to add the order totals in order to calculate the final total.

Parameters:
value - The value to set.

getPromotions

PromotionIf[] getPromotions()
An array to contain the promotion objects used to calculate the discount for a discount order total module.

Returns:
Returns the promotions.

setPromotions

void setPromotions(PromotionIf[] promotions)
An array to contain the promotion objects used to calculate the discount for a discount order total module.

Parameters:
promotions - The promotions to set.

getOrderTotals

OrderTotalIf[] getOrderTotals()
An array of OrderTotals which is populated if the OrderTotal module returns more than one result.

Returns:
the orderTotals

setOrderTotals

void setOrderTotals(OrderTotalIf[] orderTotals)
An array of OrderTotals which is populated if the OrderTotal module returns more than one result.

Parameters:
orderTotals - the orderTotals to set

getCustom1

java.lang.String getCustom1()
Returns:
the custom1

setCustom1

void setCustom1(java.lang.String custom1)
Parameters:
custom1 - the custom1 to set

getCustom2

java.lang.String getCustom2()
Returns:
the custom2

setCustom2

void setCustom2(java.lang.String custom2)
Parameters:
custom2 - the custom2 to set

getCustom3

java.lang.String getCustom3()
Returns:
the custom3

setCustom3

void setCustom3(java.lang.String custom3)
Parameters:
custom3 - the custom3 to set


Copyright © 2011 DS Data Systems UK Ltd.