Developer Resources for AbleCommerce eCommerce platform
CommerceBuilder.Services Namespace / OrderCalculator Class / InternalGetParentItem Method
Item for which to find the parent.
If true, this method gets the top level parent for this item. If false, only the immediate parent is returned.
List to track the current item path, to prevent recursive loops.
In This Topic
    InternalGetParentItem Method
    In This Topic
    Gets the parent item for the given basket item.
    Syntax
    protected static OrderItem InternalGetParentItem( 
       OrderItem item,
       bool recurse,
       List<int> itemPath
    )

    Parameters

    item
    Item for which to find the parent.
    recurse
    If true, this method gets the top level parent for this item. If false, only the immediate parent is returned.
    itemPath
    List to track the current item path, to prevent recursive loops.

    Return Value

    Returns the OrderItem instance for the parent item. If the current item has no parent, the current item is returned.
    Requirements

    Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2

    See Also