IA4HierarchyFolder::BindToList

Purpose

Returns an instance of IA4HierarchyFolder that corresponds to a particular folder in the iSeries™ Navigator hierarchy. This is a required member function.

Syntax

HRESULT STDMETHODCALLTYPE BindToList(
    HWND hwnd,
    LPCITEMIDLIST pidl,
    REFIID riid,
    LPVOID* ppvOut
    );

Parameters

hwnd
Handle of the view window that will display the list which may be either a tree or list control. A component should use this handle to determine if a list of objects for this view is already cached on the client.
pidl
Pointer to an ITEMIDLIST (item identifier list) structure that uniquely identifies the folder to be enumerated.
riid
Identifier of the interface to return. This parameter points to the IID_IA4HierarchyFolder interface identifier.
ppvOut
Address that receives the interface pointer. If an error occurs, a NULL pointer should be returned at this address.

Return Codes

Returns NOERROR if successful or E_FAIL if a general error occurred.

Comments

If an instance of IA4HierarchyFolder already exists for the specified folder, then this member function should return the cached instance instead of instantiating and initializing a separate instance. However, if the window handle associated with the cached object is not the same as the value specified on the hwnd parameter, then a new instance should be created.

The function should initialize implementation class member variables from the parameters supplied.