com.ibm.retail.saf.provider
Interface POSResult

All Superinterfaces:
POSInfo, java.io.Serializable
All Known Subinterfaces:
PaymentResult, PriceResult, TransactionResult
All Known Implementing Classes:
DefaultPaymentResult, DefaultPriceResult, DefaultTransactionResult, POSResultImpl

public interface POSResult
extends POSInfo

Contains information returned from the point-of-sale system.

POSResult objects are used as return objects by POSProvider to contain the results of a point-of-sale operation.

Extensions to POSResult may provide specific methods and instance data for the information required for a specific result. Additional data may be provided to client through the more general setAttribute interface.


Method Summary
 java.util.Iterator getExceptions()
          Return an iterator of non-fatal exceptions that are contained in the result.
 boolean hasExceptions()
          Return true if non-fatal exceptions occurred during processing of the request.
 
Methods inherited from interface com.ibm.retail.saf.provider.POSInfo
getExtendedAttribute, getExtendedAttributeNames, removeExtendedAttribute, setExtendedAttribute
 

Method Detail

hasExceptions

public boolean hasExceptions()
Return true if non-fatal exceptions occurred during processing of the request.

A request may produce a "partial result" without throwing a fatal exception. An example is the processing of a price inquiry where an item lookup fails.

Returns:
true if the result contains non-fatal exceptions

getExceptions

public java.util.Iterator getExceptions()
Return an iterator of non-fatal exceptions that are contained in the result.

If no exceptions are contained in the result, null is returned.

A request may produce a "partial result" without throwing a fatal exception. An example is the processing of a price inquiry where an item lookup fails.

This method provides an iterator of exceptions to an object identifier related to the operation that failed. A typical usage provides an ItemIdentifier and a Throwable explaining the exception condition (e.g., Item not on file).

Returns:
Iterator of Map.Entry objects containing an Object key and a Throwable value. NULL is returned if no exceptions are found.