SST  6.0.0
StructuralSimulationToolkit
elemLoader.h
1 // Copyright 2009-2016 Sandia Corporation. Under the terms
2 // of Contract DE-AC04-94AL85000 with Sandia Corporation, the U.S.
3 // Government retains certain rights in this software.
4 //
5 // Copyright (c) 2009-2016, Sandia Corporation
6 // All rights reserved.
7 //
8 // This file is part of the SST software package. For license
9 // information, see the LICENSE file in the top level directory of the
10 // distribution.
11 
12 #ifndef _SST_CORE_ELEMLOADER_H
13 #define _SST_CORE_ELEMLOADER_H
14 
15 #include <string>
16 #include <sst/core/element.h>
17 
18 namespace SST {
19 
20 struct LoaderData;
21 
22 /** Class to load Element Libraries */
23 class ElemLoader {
24  LoaderData *loaderData;
25  std::string searchPaths;
26 public:
27  /** Create a new ElementLoader with a given searchpath of directories */
28  ElemLoader(const std::string &searchPaths);
29  ~ElemLoader();
30 
31  /** Attempt to load a library
32  * @param elemlib - The name of the Element Library to load
33  * @param showErrors - Print errors associated with attempting to find and load the library
34  * @return Informational structure of the library, or NULL if it failed to load.
35  */
36  const ElementLibraryInfo* loadLibrary(const std::string &elemlib, bool showErrors);
37 };
38 
39 }
40 
41 #endif /* _SST_CORE_ELEMLOADER_H */
This structure exists so that we don't need to have any libtool-specific code (and therefore need the...
Definition: elemLoader.cc:57
Describes all the parts of the Element Library.
Definition: element.h:152
const ElementLibraryInfo * loadLibrary(const std::string &elemlib, bool showErrors)
Attempt to load a library.
Definition: elemLoader.cc:182
Definition: action.cc:17
ElemLoader(const std::string &searchPaths)
Create a new ElementLoader with a given searchpath of directories.
Definition: elemLoader.cc:63
Class to load Element Libraries.
Definition: elemLoader.h:23