IdmaEditListOfObject

This interface provides the methods for modifying lists that contain references to objects.

This interface offers all the methods of the IdmaEditList interface, as well as those listed below.

IdmaEditListOfObject::InsertObject

This method must be supported in every implementation of this interface.

Syntax
DmaRC IdmaEditListOfObject::InsertObject (
DmaIndex32 iIndex,
Dmapv pIObjectValue)

Parameters

Name

Mode

Description

iIndex

input

The ordinal position in the list where the value will be placed.

pIObjectValue

input

The object that will be inserted into the list.

Description

This function inserts an object into a list based on an ordinal position provided by the caller. All list elements that have indexes greater then iIndex at the time of the call will have their index in the list incremented by one. Permitted values for iIndex are 0 through n, where n is the number of elements in the list at the time of the call. A value of n appends a new value to the end of the list.

The object is inserted into the list by reference. Changes to the object outside the context of the list will result in side-effects on the list.

Return Values

Name

Description

DMARC_BAD_INDEX

The index specified does not reference a valid property or list element.

DMARC_BAD_OBJECT

An inappropriate object was passed as parameter to this function. For example, the object does not support a required interface or is of an inappropriate class.

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_OK

(S_OK) Success.

DMARC_READ_ONLY

Method failed because an object or property is read-only.

Deferred Return Values

Name

Description

DMARC_CONSTRAINT_VIOLATED

The operation violates a constraint of the implementation.

DMARC_LIST_BOUNDS_ERROR

The number of elements in a list is outside the permitted range.

DMARC_NOT_UNIQUE

A uniqueness requirement has been violated.

IdmaEditListOfObject::ReplaceObject

This method must be supported in every implementation of this interface.

Syntax
DmaRC IdmaEditListOfObject::ReplaceObject (
DmaIndex32 iIndex,
Dmapv pIObjectValue)

Parameters

Name

Mode

Description

iIndex

input

The ordinal position in the list where the value will be placed.

pIObjectValue

input

The new object that will replace the object in the list.

Description

Replaces an object value in a list with the supplied object value given an ordinal position value as input. Valid values for iIndex are 0 through n-1, where n is the number of elements in the list at the time of the call.

The object found in the list will be released using the method IUnknown::Release. The new object is inserted into the list by reference. Changes to the object outside the context of the list will result in side-effects on the list.

Return Values

Name

Description

DMARC_BAD_INDEX

The index specified does not reference a valid property or list element.

DMARC_BAD_OBJECT

An inappropriate object was passed as parameter to this function. For example, the object does not support a required interface or is of an inappropriate class.

DMARC_BAD_PARAMETER

(E_INVALIDARG) Invalid input parameter.

DMARC_OK

(S_OK) Success.

DMARC_READ_ONLY

Method failed because an object or property is read-only.

Deferred Return Values

Name

Description

DMARC_CONSTRAINT_VIOLATED

The operation violates a constraint of the implementation.

DMARC_NOT_UNIQUE

A uniqueness requirement has been violated.