Array::IsOwner

Description

Access to the ownership value of the array

Syntax

BOOL IsOwner( )

Parameters

Return

Returns a boolean indicating whether the array is the owner or not

Examples

EX1

#include <Array.h>
struct PERSON
{
        int nID;
};
void Array_IsOwner_ex1()
{
        Array<PERSON&> arp(true); //is owner
        if ( !arp.IsOwner() )
                printf("Fail to set Array arp as Owner.");
        
        Array<PERSON&> arp2(false); //not owner
        if ( arp2.IsOwner() )
                printf("Array arp2 should not be the owner of the items in it.");
}

Remark

See Also

Array::Array, Array::SetAsOwner

header to Include

Array.h