copy to the object in ptr if it exists, else overwrite ptr contents with object pointer

Tried to delete contents of ptr if non-null, but it frequently points to a static data member - in which case
delete fails noisily.
So, check if null. if not null, use set_null() (if it exists) and operator=; otherwise, overwrite the
pointer

Also make SDAI_Enum dtor public