File failed to load: https://isis.astrogeology.usgs.gov/6.0.0/Object/assets/jax/output/NativeMML/config.js
Isis 3 Programmer Reference
PolygonSeederFactory.cpp
1 
6 /* SPDX-License-Identifier: CC0-1.0 */
7 
8 #include "PolygonSeederFactory.h"
9 #include "Plugin.h"
10 #include "IException.h"
11 #include "FileName.h"
12 
13 namespace Isis {
37  // Get the algorithm name to create
38  PvlGroup &algo = pvl.findGroup("PolygonSeederAlgorithm", Pvl::Traverse);
39  QString algorithm = algo["Name"];
40 
41  // Open the factory plugin file
42  Plugin p;
43  FileName f("PolygonSeeder.plugin");
44  if(f.fileExists()) {
45  p.read("PolygonSeeder.plugin");
46  }
47  else {
48  p.read("$ISISROOT/lib/PolygonSeeder.plugin");
49  }
50 
51  // Get the algorithm specific plugin and return it
52  PolygonSeeder* (*plugin)(Pvl & pvl);
53  plugin = (PolygonSeeder * ( *)(Pvl & pvl)) p.GetPlugin(algorithm);
54  return (*plugin)(pvl);
55  }
56 } // end namespace isis
Isis::PvlObject::findGroup
PvlGroupIterator findGroup(const QString &name, PvlGroupIterator beg, PvlGroupIterator end)
Find a group with the specified name, within these indexes.
Definition: PvlObject.h:129
Isis::PolygonSeederFactory::Create
static PolygonSeeder * Create(Pvl &pvl)
Create a PolygonSeeder object using a PVL specification.
Definition: PolygonSeederFactory.cpp:36
Isis::FileName
File name manipulation and expansion.
Definition: FileName.h:100
Isis::FileName::fileExists
bool fileExists() const
Returns true if the file exists; false otherwise.
Definition: FileName.cpp:449
Isis::Pvl
Container for cube-like labels.
Definition: Pvl.h:119
Isis::PvlObject::Traverse
@ Traverse
Search child objects.
Definition: PvlObject.h:158
Isis::PvlGroup
Contains multiple PvlContainers.
Definition: PvlGroup.h:41
Isis::Pvl::read
void read(const QString &file)
Loads PVL information from a stream.
Definition: Pvl.cpp:90
Isis::Plugin::GetPlugin
QFunctionPointer GetPlugin(const QString &group)
This method returns a void pointer to a C function (i.e., the plugin) It does this by looking in itse...
Definition: Plugin.cpp:39
Isis::PolygonSeeder
This class is used as the base class for all PolygonSeeder objects.
Definition: PolygonSeeder.h:47
Isis
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
Isis::Plugin
Loads plugins from a shared library.
Definition: Plugin.h:55

U.S. Department of the Interior | U.S. Geological Survey
ISIS | Privacy & Disclaimers | Astrogeology Research Program
To contact us, please post comments and questions on the USGS Astrogeology Discussion Board
To report a bug, or suggest a feature go to: ISIS Github
File Modified: 07/13/2023 15:17:02