oaScriptEngineLink.h

Go to the documentation of this file.
00001 // *****************************************************************************
00002 // *****************************************************************************
00003 // oaScriptEngineLink.h
00004 //
00005 // This file contains the definitions for oaScriptEngineLink class:
00006 //
00007 //  oaScriptEngineLink
00008 //     This class is used as an container class for IScriptEngine. IScriptEngine
00009 //     is the interface for a script engine. An IScriptEngine can be
00010 //     created in memory by the application or through script engine plug-in.
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: Exp $
00025 // *****************************************************************************
00026 // *****************************************************************************
00027 
00028 
00029 
00030 #if !defined(oaScriptEngineLink_P)
00031 #define oaScriptEngineLink_P
00032 
00033 
00034 
00035 // *****************************************************************************
00036 // Nested includes
00037 // *****************************************************************************
00038 #include "oaCommonSPtr.h"
00039 #include "oaPlugInScriptInterfaces.h"
00040 #include "oaDesignDBTypes.h"
00041 
00042 
00043 
00044 // *****************************************************************************
00045 // Declare and define types in the OpenAccess namespace.
00046 // *****************************************************************************
00047 BEGIN_OA_NAMESPACE
00048 
00049 USE_OA_PLUGIN_NAMESPACE
00050 
00051 
00052 // *****************************************************************************
00053 // Explicit template instantiations
00054 // *****************************************************************************
00055 #if defined(OA_DESIGN_DLL_EXTERN)
00056 OA_DESIGN_DLL_EXTERN template
00057  class OA_DESIGN_DLL_API SPtr<IScriptEngine>;
00058 #endif
00059 
00060 
00061 
00062 // *****************************************************************************
00063 // oaScriptEngineLink
00064 // *****************************************************************************
00065 class OA_DESIGN_DLL_API oaScriptEngineLink {
00066 public:
00067     void                        destroy();
00068     IScriptEngine               *getEngine() const;
00069     const oaString              &getName() const;
00070 
00071     static oaScriptEngineLink   *get(const oaString &seName);
00072     static oaScriptEngineLink   *create(IScriptEngine   *scriptEngineIn,
00073                                         const oaString  &nameIn);
00074 
00075 private:
00076                                 oaScriptEngineLink(IScriptEngine    *sEngineIn,
00077                                                    const oaString   &nameIn);
00078 
00079     oaString                    name;
00080     SPtr<IScriptEngine>         sEngine;
00081     oaScriptEngineLink          *next;
00082     static oaScriptEngineLink   *first;
00083 };
00084 
00085 
00086 
00087 END_OA_NAMESPACE
00088 
00089 
00090 
00091 #endif

Return to top of page