IResourceList::AddEntryFromParent method (portcls.h)
The AddEntryFromParent
method adds to a resource list an entry found in the resource list's parent list.
Syntax
NTSTATUS AddEntryFromParent(
[in] IResourceList *Parent,
[in] CM_RESOURCE_TYPE Type,
[in] ULONG Index
);
Parameters
[in] Parent
Pointer to parent IResourceList object from which the entry is to be taken.
[in] Type
Identifies the resource type of the entry that is to be added. For a list of valid resource-type values, see the description of the Type member of the CM_PARTIAL_RESOURCE_DESCRIPTOR structure.
[in] Index
Specifies the index in the parent list of the entry to add. If the parent's IResourceList::NumberOfEntriesOfType method returns a value n for the number of entries of type Type, valid indices range from 0 to n-1. If Index is zero, for example, the method adds the first occurrence of an entry of the specified type from the parent list.
Return value
AddEntryFromParent
returns STATUS_SUCCESS if the call was successful. Otherwise, the method returns an appropriate error code. The following table shows some of the possible return status codes.
Return code | Description |
---|---|
|
Indicates there are no free entries in the list. |
|
Indicates the entry was not found in the parent list. |
Remarks
For each resource type, a macro is defined to call this method. See IResourceList.
The Parent parameter follows the reference-counting conventions for COM objects.
Requirements
Requirement | Value |
---|---|
Target Platform | Universal |
Header | portcls.h (include Portcls.h) |
IRQL | PASSIVE_LEVEL |