# Synopsis

PDX_MSGT mda_CopyEntity2(long option, int model, MDA_COPY_CHECK *func, void *src_ent, void *dst_ent)

# Purpose

Recursively copy an entity.

# Description

This function is identical to mda_CopyEntity except if mda_CreateEntity is called, the entity will be written to model as specified in the call to this function rather than the model which is current when this function is called.

# Input

## option

### MDA_CREATE_TOP

The top level entity will be created and left locked.

## model

Model to create entity in

## func

Function to determine if nested entity should be copied or NULL

## src_ent

Entity to be copied

# Output

## dst_ent

Copy of src_ent

# Return

MDA error code