oaCMProtocol.h

Go to the documentation of this file.
00001 // ****************************************************************************
00002 // ****************************************************************************
00003 // oaCMProtocol.h
00004 //
00005 // This file contains the definitions of the oaCMProtocol and oaCMProtocolArray 
00006 // classes 
00007 //
00008 //  oaCMProtocol
00009 //      The oaCMProtocol class defines a specific protocol. A protocol has a 
00010 //      name, plug-in name, an array of fixed attributes and an array of 
00011 //      modifiable attributes.
00012 //
00013 //  oaCMProtocolArray
00014 //      The oaCMProtocolArray is an array of oaCMProtocols. A oaCMProtocolArray
00015 //      generally represents the array of oaCMProtocols supported by a plug-in
00016 //      from which the application can choose one.
00017 //
00018 // ****************************************************************************
00019 // Except as specified in the OpenAccess terms of use of Cadence or Silicon
00020 // Integration Initiative, this material may not be copied, modified,
00021 // re-published, uploaded, executed, or distributed in any way, in any medium,
00022 // in whole or in part, without prior written permission from Cadence.
00023 //
00024 //                Copyright 2007 Cadence Design Systems, Inc.
00025 //                           All Rights Reserved.
00026 //
00027 //  $Author: icftcm $
00028 //  $Revision: #1 $
00029 //  $Date: 2010/08/09 $
00030 //  $State: $
00031 // ****************************************************************************
00032 // ****************************************************************************
00033 
00034 
00035 
00036 #if !defined(oaCMProtocol_P)
00037 #define oaCMProtocol_P
00038 
00039 
00040 
00041 // *****************************************************************************
00042 // Nested includes
00043 // *****************************************************************************
00044 #include "oaString.h"
00045 #include "oaCMAttr.h"
00046 
00047 
00048 
00049 // *****************************************************************************
00050 // Define names in the OA namespace.
00051 // *****************************************************************************
00052 BEGIN_OA_NAMESPACE
00053 
00054 
00055 
00056 // ****************************************************************************
00057 // oaCMProtocol
00058 // ****************************************************************************
00059 class OA_CM_DLL_API oaCMProtocol {
00060 public:
00061                             oaCMProtocol();
00062                             oaCMProtocol(const oaString &nameIn,
00063                                          const oaString &plugInNameIn);
00064                             oaCMProtocol(const oaString         &nameIn,
00065                                          const oaString         &plugInNameIn,
00066                                          const oaCMAttrArray    &fixedAttrsIn,
00067                                          const oaCMAttrArray    &modAttrsIn);
00068                             oaCMProtocol(const oaCMProtocol &protocolIn);
00069 
00070     const oaString          &getName() const;
00071     const oaString          &getPlugInName() const;
00072     const oaCMAttrArray     &getFixedAttrs() const;
00073     const oaCMAttrArray     &getModAttrs() const;
00074 
00075     void                    setFixedAttrs(const oaCMAttrArray &arrayIn);
00076     void                    setModAttrs(const oaCMAttrArray &arrayIn);
00077 
00078     oaBoolean               hasUnsetAttrs() const;
00079     oaBoolean               match(const oaCMProtocol &protoIn) const;
00080 
00081     const oaCMAttr          *findAttr(const oaString &name) const;
00082 
00083     oaCMProtocol            &operator=(const oaCMProtocol &rhs);
00084     oaBoolean               operator==(const oaCMProtocol &rhs) const;
00085     oaBoolean               operator!=(const oaCMProtocol &rhs) const;
00086 
00087 private:
00088     oaString                m_name;
00089     oaString                m_plugInName;
00090     oaCMAttrArray           m_fixedAttrs;
00091     oaCMAttrArray           m_modAttrs;
00092 };
00093 
00094 
00095 
00096 // ****************************************************************************
00097 // oaCMProtocolArray
00098 // ****************************************************************************
00099 class OA_CM_DLL_API oaCMProtocolArray : public oaArray<oaCMProtocol> {
00100 public:
00101                             oaCMProtocolArray(oaUInt4 sizeIn = 0);
00102                             oaCMProtocolArray(const oaCMProtocolArray &arrayIn);
00103 
00104     oaUInt4                 findByName(const oaString   &nameIn,
00105                                        const oaString   &plugInNameIn) const;
00106     oaBoolean               validate(const oaCMProtocol &protoIn) const;
00107 
00108     oaCMProtocolArray       &operator=(const oaCMProtocolArray &rhs);
00109 };
00110 
00111 
00112 
00113 END_OA_NAMESPACE
00114 
00115 #endif
00116 

Return to top of page