00001 // ***************************************************************************** 00002 // ***************************************************************************** 00003 // oaObject.h 00004 // 00005 // This file contains the definition for the oaObject class. This is an abstract 00006 // class that is the base for all OpenAccess database objects. 00007 // 00008 // Note that construction, desctruction, copying, and assigning of objects is 00009 // not allowed. These methods are specified as private to insure that 00010 // application code does not call them. 00011 // 00012 // ***************************************************************************** 00013 // Except as specified in the OpenAccess terms of use of Cadence or Silicon 00014 // Integration Initiative, this material may not be copied, modified, 00015 // re-published, uploaded, executed, or distributed in any way, in any medium, 00016 // in whole or in part, without prior written permission from Cadence. 00017 // 00018 // Copyright 2002-2005 Cadence Design Systems, Inc. 00019 // All Rights Reserved. 00020 // 00021 // $Author: icftcm $ 00022 // $Revision: #1 $ 00023 // $Date: 2010/08/09 $ 00024 // $State$ 00025 // ***************************************************************************** 00026 // ***************************************************************************** 00027 00028 00029 00030 #if !defined(oaObject_P) 00031 #define oaObject_P 00032 00033 00034 00035 // ***************************************************************************** 00036 // Nested includes 00037 // ***************************************************************************** 00038 #include "oaType.h" 00039 #include "oaDomain.h" 00040 00041 00042 00043 // ***************************************************************************** 00044 // Declare and define types in the OpenAccess namespace. 00045 // ***************************************************************************** 00046 BEGIN_OA_NAMESPACE 00047 00048 00049 00050 // ***************************************************************************** 00051 // Forward Public Class Declarations 00052 // ***************************************************************************** 00053 class oaConstraintGroup; 00054 class oaProp; 00055 class oaObject; 00056 class oaAppDef; 00057 class oaGroupMember; 00058 class oaGroup; 00059 template <class U, class V> 00060 class OA_BASE_DLL_PVT oaCollection; 00061 00062 00063 00064 // ***************************************************************************** 00065 // oaObject 00066 // ***************************************************************************** 00067 class OA_BASE_DLL_API oaObject { 00068 public: 00069 oaBoolean isValid() const; 00070 oaType getType() const; 00071 oaDomain getDomain() const; 00072 oaBoolean isTech() const; 00073 oaBoolean isDesign() const; 00074 oaBoolean isDM() const; 00075 oaBoolean isDMData() const; 00076 oaBoolean isWafer() const; 00077 oaBoolean isSession() const; 00078 oaBoolean isProp() const; 00079 oaBoolean isGroup() const; 00080 oaBoolean isGroupMember() const; 00081 oaBoolean isAppObject() const; 00082 oaBoolean isConstraint() const; 00083 oaBoolean isConstraintGroup() const; 00084 oaBoolean isConstraintGroupMem() const; 00085 oaBoolean isConstraintGroupHeader() const; 00086 oaBoolean isConstraintParam() const; 00087 oaBoolean isValue() const; 00088 oaBoolean isViaVariant() const; 00089 oaBoolean isViaVariantHeader() const; 00090 00091 oaBoolean hasProp() const; 00092 oaBoolean inGroup() const; 00093 oaBoolean hasAppDef() const; 00094 oaBoolean hasConstraintGroup() const; 00095 oaBoolean hasAssociate() const; 00096 00097 oaConstraintGroup *getConstraintGroup() const; 00098 00099 oaObject *getDatabase() const; 00100 00101 oaCollection<oaProp, oaObject> getProps() const; 00102 oaCollection<oaAppDef, oaObject> getAppDefs() const; 00103 oaCollection<oaGroupMember, oaObject> getGroupMems() const; 00104 oaCollection<oaGroupMember, oaObject> getGroupLeaders() const; 00105 oaCollection<oaGroup, oaObject> getGroupsOwnedBy() const; 00106 00107 enum {dbType = oacBaseDBType}; 00108 enum {domain = oacNoDomain}; 00109 00110 protected: 00111 oaByte id; 00112 00113 ~oaObject(); 00114 00115 private: 00116 oaObject(); 00117 oaObject(const oaObject &obj); 00118 00119 oaObject &operator=(const oaObject &obj); 00120 00121 friend class oaObjectPage; 00122 }; 00123 00124 00125 00126 // ***************************************************************************** 00127 // oaBaseTraits<> 00128 // 00129 // oaBaseTraits<> is a placeholder for traits that are common to most objects. 00130 // Its usage has been deprecated as each oaTraits<> specialization is fully 00131 // specified and independent from each other. 00132 // ***************************************************************************** 00133 template<class obj> 00134 class oaBaseTraits { 00135 public: 00136 enum {domain = oacNoDomain}; 00137 enum {isMultiDomain = false}; 00138 }; 00139 00140 00141 00142 // ***************************************************************************** 00143 // oaTraits<> 00144 // 00145 // The oaTraits<> template has no default implementation since all instances of 00146 // it are specializations. All specializations of oaTraits<> are independent and 00147 // fully specified. 00148 // ***************************************************************************** 00149 template<class obj> 00150 class oaTraits; 00151 00152 00153 00154 // ***************************************************************************** 00155 // oaObject is the base object for all OpenAccess objects 00156 // ***************************************************************************** 00157 template<> 00158 class oaTraits<oaObject> { 00159 public: 00160 enum {domain = oacNoDomain}; 00161 enum {isMultiDomain = false}; 00162 enum {isConcrete = false}; 00163 enum {dbType = oacBaseDBType}; 00164 enum {abstractTypeEnumVal = oacObjectType}; 00165 }; 00166 00167 00168 00169 END_OA_NAMESPACE 00170 00171 #endif
Copyright © 2002 - 2010 Cadence Design Systems, Inc.
All Rights Reserved.