atg.commerce.order
Class OrderRelationshipContainerImpl

java.lang.Object
  extended by atg.commerce.order.OrderRelationshipContainerImpl
All Implemented Interfaces:
OrderRelationshipContainer, java.io.Serializable

public class OrderRelationshipContainerImpl
extends java.lang.Object
implements OrderRelationshipContainer

A class which manages the containment of OrderRelationship objects.

See Also:
Serialized Form

Field Summary
static java.lang.String CLASS_VERSION
          Class version string
 
Constructor Summary
OrderRelationshipContainerImpl()
          Constructs a OrderRelationshipContainerImpl object.
 
Method Summary
 void addOrderRelationship(OrderRelationship pOrderRelationship)
          Add the OrderRelationship to the container.
 OrderRelationship getOrderRelationship()
          Returns the OrderRelationship.
 int getOrderRelationshipCount()
          Returns the number of OrderRelationships in the container.
 OrderRelationship removeOrderRelationship()
          Removes a OrderRelationship.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

CLASS_VERSION

public static java.lang.String CLASS_VERSION
Class version string

Constructor Detail

OrderRelationshipContainerImpl

public OrderRelationshipContainerImpl()
Constructs a OrderRelationshipContainerImpl object.

Method Detail

addOrderRelationship

public void addOrderRelationship(OrderRelationship pOrderRelationship)
                          throws DuplicateRelationshipException,
                                 InvalidParameterException
Add the OrderRelationship to the container. If the OrderRelationship was already in the container a DuplicateRelationshipException is thrown.

Specified by:
addOrderRelationship in interface OrderRelationshipContainer
Throws:
DuplicateRelationshipException
InvalidParameterException

removeOrderRelationship

public OrderRelationship removeOrderRelationship()
                                          throws RelationshipNotFoundException,
                                                 InvalidParameterException
Removes a OrderRelationship. If the OrderRelationship is not in the container then a RelationshipNotFoundException is thrown. Otherwise a reference to the removed OrderRelationship is returned.

Specified by:
removeOrderRelationship in interface OrderRelationshipContainer
Throws:
RelationshipNotFoundException
InvalidParameterException

getOrderRelationship

public OrderRelationship getOrderRelationship()
                                       throws RelationshipNotFoundException,
                                              InvalidParameterException
Returns the OrderRelationship. If the OrderRelationship with the corresponding id is not in the container then a RelationshipNotFoundException is thrown.

Specified by:
getOrderRelationship in interface OrderRelationshipContainer
Throws:
RelationshipNotFoundException
InvalidParameterException

getOrderRelationshipCount

public int getOrderRelationshipCount()
Returns the number of OrderRelationships in the container. The returned value will be either 0 or 1.

Specified by:
getOrderRelationshipCount in interface OrderRelationshipContainer