IRefTargMonitorClass.h

Go to the documentation of this file.
00001 //**************************************************************************/
00002 // Copyright (c) 1998-2005 Autodesk, Inc.
00003 // All rights reserved.
00004 // 
00005 // These coded instructions, statements, and computer programs contain
00006 // unpublished proprietary information written by Autodesk, Inc., and are
00007 // protected by Federal copyright law. They may not be disclosed to third
00008 // parties or copied or duplicated in any form, in whole or in part, without
00009 // the prior written consent of Autodesk, Inc.
00010 //**************************************************************************/
00011 // DESCRIPTION: Defines an interface that uses the RefTargMonitorRefMaker class to monitor a RefTarg for 
00012 // deletion. If the RefTargMonitor instance is saved as part of a partial save, or loaded as a partial load, 
00013 // the RefTarg pointed to by the RefTargMonitor is not forced to be saved or loaded.
00014 // AUTHOR: Larry.Minton - created Jan.11.2006
00015 //***************************************************************************/
00016 
00017 #pragma once
00018 
00019 #include "iFnPub.h"
00020 #include "IRefTargMonitor.h"
00021 
00023 #define REFTARGMONITOR_CLASS_ID         Class_ID(0x1af82963, 0x29663cd2)
00024 
00026 #define IID_REFTARGMONITOR_CLASS        Interface_ID(0x1af82963, 0x29663cd2)
00027 
00030 #define REFMSG_REFTARGMONITOR_TARGET_DELETED                REFMSG_USER + 0x18f81904
00031 
00033 
00039 class IRefTargMonitorClass : public FPMixinInterface  {
00040 public:
00042 
00044     virtual RefTargetHandle GetRefTarg() = 0;
00046 
00048     virtual void SetRefTarg(RefTargetHandle theRefTarg) = 0;
00049 
00051 
00053     virtual bool GetPersist() = 0;
00055 
00057     virtual void SetPersist(bool persist) = 0;
00058 
00059     // --- Function publishing
00060     FPInterfaceDesc* GetDesc();    // <-- must implement 
00061     virtual Interface_ID GetID() { return IID_REFTARGMONITOR_CLASS; }
00062 
00063     enum {  
00064         kfpGetRefTarg, kfpSetRefTarg,
00065         kfpGetPersist, kfpSetPersist,
00066     };
00067 
00068     BEGIN_FUNCTION_MAP
00069         PROP_FNS(kfpGetRefTarg, GetRefTarg, kfpSetRefTarg, SetRefTarg, TYPE_REFTARG);
00070         PROP_FNS(kfpGetPersist, GetPersist, kfpSetPersist, SetPersist, TYPE_bool);
00071     END_FUNCTION_MAP
00072 
00073 };
00074