oaWaferObserver.h

Go to the documentation of this file.
00001 // *****************************************************************************
00002 // *****************************************************************************
00003 // oaWaferObserver.h
00004 //
00005 // This file contains the definition of the observer class
00006 //  oaVersionedObserver<oaWafer>
00007 //      This class implements the observers for the wafer object. It
00008 //      supports open, purge, preSave, postSave, preSaveAs, postSaveAs,
00009 //      preReopen, postReopen, and truncate actions.
00010 //
00011 // *****************************************************************************
00012 // Except as specified in the OpenAccess terms of use of Cadence or Silicon
00013 // Integration Initiative, this material may not be copied, modified,
00014 // re-published, uploaded, executed, or distributed in any way, in any medium,
00015 // in whole or in part, without prior written permission from Cadence.
00016 //
00017 //                Copyright 2004-2005 Cadence Design Systems, Inc.
00018 //                           All Rights Reserved.
00019 //
00020 //  $Author: icftcm $
00021 //  $Revision: #1 $
00022 //  $Date: 2010/08/09 $
00023 //  $State: Exp $
00024 // *****************************************************************************
00025 // *****************************************************************************
00026 
00027 
00028 
00029 #if !defined(oaWaferObserver_P)
00030 #define oaWaferObserver_P
00031 
00032 
00033 
00034 // *****************************************************************************
00035 // Nested includes
00036 // *****************************************************************************
00037 #include "oaObserver.h"
00038 #include "oaWaferModTypes.h"
00039 #include "oaWafer.h"
00040 #include "oaDesignInst.h"
00041 #include "oaImage.h"
00042 #include "oaStepperMap.h"
00043 #include "oaWaferFeature.h"
00044 #include "oaFrameInst.h"
00045 
00046 
00047 
00048 // *****************************************************************************
00049 // Declare and define types in the OpenAccess namespace.
00050 // *****************************************************************************
00051 BEGIN_OA_NAMESPACE
00052 
00053 
00054 
00055 
00056 // *****************************************************************************
00057 // Explicit template instantiations
00058 // *****************************************************************************
00059 #if defined(OA_WAFER_DLL_EXTERN)
00060 OA_WAFER_DLL_EXTERN template
00061  class OA_WAFER_DLL_API oaVersionedObserver<oaDesignInst, oaRevisionTraits<oaDesignInst>::scopedObserverRevision>;
00062 
00063 OA_WAFER_DLL_EXTERN template
00064  class OA_WAFER_DLL_API oaVersionedObserver<oaFrame, oaRevisionTraits<oaFrame>::scopedObserverRevision>;
00065 
00066 OA_WAFER_DLL_EXTERN template
00067  class OA_WAFER_DLL_API oaVersionedObserver<oaFrameInst, oaRevisionTraits<oaFrameInst>::scopedObserverRevision>;
00068 
00069 OA_WAFER_DLL_EXTERN template
00070  class OA_WAFER_DLL_API oaVersionedObserver<oaImage, oaRevisionTraits<oaImage>::scopedObserverRevision>;
00071 
00072 OA_WAFER_DLL_EXTERN template
00073  class OA_WAFER_DLL_API oaVersionedObserver<oaReticle, oaRevisionTraits<oaReticle>::scopedObserverRevision>;
00074 
00075 OA_WAFER_DLL_EXTERN template
00076  class OA_WAFER_DLL_API oaVersionedObserver<oaReticleRef, oaRevisionTraits<oaReticleRef>::scopedObserverRevision>;
00077 
00078 OA_WAFER_DLL_EXTERN template
00079  class OA_WAFER_DLL_API oaVersionedObserver<oaStepperMap, oaRevisionTraits<oaStepperMap>::scopedObserverRevision>;
00080 
00081 OA_WAFER_DLL_EXTERN template
00082  class OA_WAFER_DLL_API oaVersionedObserver<oaWaferDesc, oaRevisionTraits<oaWaferDesc>::scopedObserverRevision>;
00083 
00084 OA_WAFER_DLL_EXTERN template
00085  class OA_WAFER_DLL_API oaVersionedObserver<oaWaferFeature, oaRevisionTraits<oaWaferFeature>::scopedObserverRevision>;
00086 
00087 #endif
00088 
00089 
00090 
00091 // *****************************************************************************
00092 // oaVersionedObserver<oaWafer> specialization
00093 // *****************************************************************************
00094 template<>
00095 class OA_WAFER_DLL_API oaVersionedObserver<oaWafer, oacObserverVersion1> : public oaBaseObserver {
00096 public:
00097                                                                 oaVersionedObserver(oaUInt4     priorityIn,
00098                                                                                     oaBoolean   enabledIn = true);
00099     virtual                                                     ~oaVersionedObserver();
00100 
00101     virtual void                                                onFirstOpen(oaWafer *wafer);
00102     virtual void                                                onPurge(oaWafer *wafer);
00103     virtual void                                                onPreReopen(oaWafer *wafer,
00104                                                                             oaChar  newMode);
00105     virtual void                                                onPostReopen(oaWafer    *wafer,
00106                                                                              oaChar     oldMode);
00107     virtual void                                                onTruncate(oaWafer *wafer);
00108     virtual void                                                onPreSave(oaWafer *wafer);
00109     virtual void                                                onPostSave(oaWafer      *wafer,
00110                                                                            oaBoolean    succeeded);
00111     virtual void                                                onPreSaveAs(oaWafer             *wafer,
00112                                                                             const oaScalarName  &libName,
00113                                                                             const oaScalarName  &cellName,
00114                                                                             const oaScalarName  &viewName);
00115     virtual void                                                onPostSaveAs(oaWafer            *wafer,
00116                                                                              const oaScalarName &libName,
00117                                                                              const oaScalarName &cellName,
00118                                                                              const oaScalarName &viewName,
00119                                                                              oaBoolean          succeeded);
00120     virtual void                                                onPreModify(oaWafer             *wafer,
00121                                                                             oaWaferModTypeEnum  modType);
00122     virtual void                                                onPostModify(oaWafer            *wafer,
00123                                                                              oaWaferModTypeEnum modType);
00124 
00125     static void                                                 notifyFirstOpenObservers(oaWafer *w);
00126     static void                                                 notifyPurgeObservers(oaWafer *w);
00127     static void                                                 notifyPreReopenObservers(oaWafer    *r,
00128                                                                                          oaChar     newMode);
00129     static void                                                 notifyPostReopenObservers(oaWafer   *r,
00130                                                                                           oaChar    oldMode);
00131     static void                                                 notifyTruncateObservers(oaWafer *r);
00132     static void                                                 notifyPreSaveObservers(oaWafer *r);
00133     static void                                                 notifyPostSaveObservers(oaWafer     *r,
00134                                                                                         oaBoolean   succeeded);
00135     static void                                                 notifyPreSaveAsObservers(oaWafer            *w,
00136                                                                                          const oaScalarName &libN,
00137                                                                                          const oaScalarName &cellN,
00138                                                                                          const oaScalarName &viewN);
00139     static void                                                 notifyPostSaveAsObservers(oaWafer               *w,
00140                                                                                           const oaScalarName    &libN,
00141                                                                                           const oaScalarName    &cellN,
00142                                                                                           const oaScalarName    &viewN,
00143                                                                                           oaBoolean             didIt);
00144     static void                                                 notifyPreModifyObservers(oaWafer            *r,
00145                                                                                          oaWaferModTypeEnum mt);
00146     static void                                                 notifyPostModifyObservers(oaWafer               *r,
00147                                                                                           oaWaferModTypeEnum    mt);
00148 private:
00149     typedef oaVersionedObserver<oaWafer, oacObserverVersion1>   oaWaferObserver;
00150 
00151     oaWaferObserver                                             *next;
00152 
00153     static oaWaferObserver                                      *first;
00154 
00155     template<class T, oaUInt4 V> friend class oaObserverCollectionPvt;
00156 };
00157 
00158 
00159 
00160 END_OA_NAMESPACE
00161 
00162 #endif
00163 

Return to top of page