oaBusTermDef.h

Go to the documentation of this file.
00001 // *****************************************************************************
00002 // *****************************************************************************
00003 // oaBusTermDef.h
00004 //
00005 // This file contains the definition for the oaBusTermDef class and its public
00006 // supporting classes. The oaBusTermDef class implements the definition of a
00007 // busTerm, including its name and bit-range.
00008 //
00009 // A busTermDef is automatically created if necessary whenever applications
00010 // create busTerms. These implicit busTerm definitions will have no bitOrder.
00011 // Applications may explicitly create a busTerm definition in order to specify
00012 // that it has a specific bitOrder.
00013 //
00014 // Implicitly created busTerm definitions are automatically destroyed when the
00015 // last busTerm with the same name is destroyed. Explicitly created busTerm
00016 // definitions must be explicitly destroyed. An exception will be thrown if an
00017 // attempt is made to destroy an implicitly created busTerm definition. An
00018 // exception will also be thrown if an attempt is made to destroy an explicitly
00019 // created busNet definition that still has busTerms associated with it.
00020 //
00021 // *****************************************************************************
00022 // Except as specified in the OpenAccess terms of use of Cadence or Silicon
00023 // Integration Initiative, this material may not be copied, modified,
00024 // re-published, uploaded, executed, or distributed in any way, in any medium,
00025 // in whole or in part, without prior written permission from Cadence.
00026 //
00027 //                Copyright 2002-2005 Cadence Design Systems, Inc.
00028 //                           All Rights Reserved.
00029 //
00030 //  $Author: icftcm $
00031 //  $Revision: #1 $
00032 //  $Date: 2010/08/09 $
00033 //  $State: Exp $
00034 // *****************************************************************************
00035 // *****************************************************************************
00036 
00037 
00038 
00039 #if !defined(oaBusTermDef_P)
00040 #define oaBusTermDef_P
00041 
00042 
00043 
00044 // *****************************************************************************
00045 // Nested includes
00046 // *****************************************************************************
00047 #include "oaBusNetDef.h"
00048 
00049 
00050 
00051 // *****************************************************************************
00052 // Declare and define types in the OpenAccess namespace.
00053 // *****************************************************************************
00054 BEGIN_OA_NAMESPACE
00055 
00056 
00057 
00058 // *****************************************************************************
00059 // oaBusTermDef
00060 // *****************************************************************************
00061 class OA_DESIGN_DLL_API oaBusTermDef : public oaBlockObject {
00062 public:
00063     static oaBusTermDef                         *create(const oaBlock       *block,
00064                                                         const oaScalarName  &name,
00065                                                         oaBitOrder          order);
00066 
00067     static oaBusTermDef                         *find(const oaBlock         *block,
00068                                                       const oaScalarName    &name);
00069 
00070     void                                        destroy();
00071 
00072     oaUInt4                                     getMinIndex() const;
00073     oaUInt4                                     getMaxIndex() const;
00074     oaUInt4                                     getNumBits() const;
00075     void                                        getName(oaScalarName &name) const;
00076     void                                        getName(const oaNameSpace   &ns,
00077                                                         oaString            &name) const;
00078     oaBitOrder                                  getBitOrder() const;
00079 
00080     oaBoolean                                   isImplicit() const;
00081 
00082     void                                        setBitOrder(oaBitOrder order);
00083 
00084     oaCollection<oaBusTerm, oaBusTermDef>       getBusTerms() const;
00085     oaCollection<oaBusTermBit, oaBusTermDef>    getBusTermBits() const;
00086 
00087     enum {dtIndex = oacBusTermDefDataType};
00088 };
00089 
00090 
00091 
00092 // *****************************************************************************
00093 // Design Traits.
00094 // *****************************************************************************
00095 template<>
00096 class oaTraits<oaBusTermDef> {
00097 public:
00098     typedef oaBlockObject           parentType;
00099     typedef oaBusTermDefModTypeEnum modTypeType;
00100     enum {domain = oacBlockDomain};
00101     enum {dbType = oacDesignDBType};
00102     enum {isMultiDomain = true};
00103     enum {dtIndex = oacBusTermDefDataType};
00104     enum {isConcrete = true};
00105     enum {objectTypeEnumVal = oacBusTermDefType};
00106     enum {dataTypeEnumVal = oacBusTermDefDataType};
00107 };
00108 
00109 
00110 
00111 END_OA_NAMESPACE
00112 
00113 #endif

Return to top of page