27 #include <boost/foreach.hpp>
30 #include "../../common/BoostUtils.h"
31 #include "../../common/PlatformUtils.h"
32 #include "../../common/SystemApplicationSettings.h"
33 #include "../../common/UserApplicationSettings.h"
34 #include "../../dataaccess/datasource/DataSourceInfo.h"
35 #include "../../dataaccess/datasource/DataSourceInfoManager.h"
36 #include "../../dataaccess/serialization/xml/Serializer.h"
37 #include "../../maptools/AbstractLayer.h"
38 #include "../../plugin/PluginManager.h"
39 #include "../../plugin/PluginInfo.h"
40 #include "../../maptools/serialization/xml/Layer.h"
41 #include "../../xml/AbstractWriter.h"
42 #include "../../xml/AbstractWriterFactory.h"
43 #include "../../xml/Reader.h"
44 #include "../../xml/ReaderFactory.h"
45 #include "../../Version.h"
58 #include <boost/property_tree/ptree.hpp>
59 #include <boost/property_tree/json_parser.hpp>
60 #include <boost/algorithm/string/replace.hpp>
61 #include <boost/filesystem.hpp>
62 #include <boost/format.hpp>
69 #include <QTextStream>
70 #include <QApplication>
72 #include <QMainWindow>
73 #include <QMessageBox>
79 boost::filesystem::path furi(uri);
81 if (!boost::filesystem::exists(furi) || !boost::filesystem::is_regular_file(furi))
82 throw Exception((boost::format(
TE_TR(
"Could not read project file: %1%.")) % uri).str());
85 xmlReader->setValidationScheme(
false);
89 if(!xmlReader->next())
90 throw Exception((boost::format(
TE_TR(
"Could not read project information in the file: %1%.")) % uri).str());
93 throw Exception((boost::format(
TE_TR(
"Error reading the document %1%, the start element wasn't found.")) % uri).str());
95 if(xmlReader->getElementLocalName() !=
"Project")
96 throw Exception((boost::format(
TE_TR(
"The first tag in the document %1% is not 'Project'.")) % uri).str());
102 XMLFormatter::format(proj,
false);
112 std::auto_ptr<Project> project(
new Project);
189 project->setProjectAsChanged(
false);
191 return project.release();
203 Save(p, *writer.get());
229 boost::replace_all(schema_loc,
" ",
"%20");
231 writer.
writeAttribute(
"xmlns:xsd",
"http://www.w3.org/2001/XMLSchema-instance");
232 writer.
writeAttribute(
"xmlns:te_da",
"http://www.terralib.org/schemas/dataaccess");
233 writer.
writeAttribute(
"xmlns:te_map",
"http://www.terralib.org/schemas/maptools");
234 writer.
writeAttribute(
"xmlns:te_qt_af",
"http://www.terralib.org/schemas/common/af");
238 writer.
writeAttribute(
"xmlns:xlink",
"http://www.w3.org/1999/xlink");
240 writer.
writeAttribute(
"xmlns",
"http://www.terralib.org/schemas/qt/af");
241 writer.
writeAttribute(
"xsd:schemaLocation",
"http://www.terralib.org/schemas/qt/af " + schema_loc);
250 writer.
writeAttribute(
"xmlns:te_common",
"http://www.terralib.org/schemas/common");
256 for(it=itBegin; it!=itEnd; ++it)
258 bool ogrDsrc = it->second->getAccessDriver() ==
"OGR";
264 writer.
writeAttribute(
"access_driver", it->second->getAccessDriver());
275 std::map<std::string, std::string> info = it->second->getConnInfo();
276 std::map<std::string, std::string>::iterator conIt;
278 for(conIt=info.begin(); conIt!=info.end(); ++conIt)
307 for(std::list<te::map::AbstractLayerPtr>::const_iterator it = project.
getTopLayers().begin();
310 lserial.
write(it->get(), writer);
322 QSettings user_settings(QSettings::IniFormat,
323 QSettings::UserScope,
324 QApplication::instance()->organizationName(),
325 QApplication::instance()->applicationName());
328 if(!prjFiles.empty() && !prjTitles.empty() && (prjFiles.size() == prjTitles.size()))
330 user_settings.setValue(
"projects/most_recent/path", prjFiles.at(0));
331 user_settings.setValue(
"projects/most_recent/title", prjTitles.at(0));
333 if(prjFiles.size() > 1)
335 user_settings.beginGroup(
"projects");
337 user_settings.beginWriteArray(
"recents");
339 for(
int i = 1; i != prjFiles.size(); ++i)
341 user_settings.setArrayIndex(i - 1);
342 user_settings.setValue(
"projects/path", prjFiles.at(i));
343 user_settings.setValue(
"projects/title", prjTitles.at(i));
346 user_settings.endArray();
348 user_settings.endGroup();
353 user_settings.remove(
"plugins/enabled");
355 user_settings.beginGroup(
"plugins");
356 user_settings.remove(
"enabled");
357 user_settings.remove(
"unloaded");
358 user_settings.remove(
"broken");
360 user_settings.beginWriteArray(
"enabled");
366 for(std::size_t i = 0; i != plugins.size(); ++i)
371 user_settings.setArrayIndex(aidx++);
373 user_settings.setValue(
"name", plugins[i].c_str());
376 user_settings.endArray();
379 user_settings.beginWriteArray(
"unloaded");
383 for (std::size_t i = 0; i != plugins.size(); ++i)
388 user_settings.setArrayIndex(unloadedidx++);
389 user_settings.setValue(
"name", plugins[i].c_str());
392 user_settings.endArray();
395 user_settings.beginWriteArray(
"broken");
399 for (std::size_t i = 0; i != plugins.size(); ++i)
404 user_settings.setArrayIndex(brokenidx++);
405 user_settings.setValue(
"name", plugins[i].c_str());
408 user_settings.endArray();
410 user_settings.endGroup();
415 QSettings usettings(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
417 QVariant fileName = usettings.value(
"data_sources/data_file");
419 if(fileName.isNull())
421 const QString& udir = ApplicationController::getInstance().getUserDataDir();
425 usettings.setValue(
"data_sources/data_file", fileName);
438 sett.beginGroup(bar->objectName());
440 sett.setValue(
"name", bar->objectName());
442 sett.beginWriteArray(
"Actions");
444 QList<QAction*> acts = bar->actions();
446 for(
int i=0; i<acts.size(); i++)
448 sett.setArrayIndex(i);
449 sett.setValue(
"action", acts.at(i)->objectName());
460 std::vector<QToolBar*>::const_iterator it;
461 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
463 sett.beginGroup(
"toolbars");
465 for (it = bars.begin(); it != bars.end(); ++it)
469 sett.remove(bar->objectName());
479 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
481 sett.beginGroup(
"toolbars");
490 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
492 sett.beginGroup(
"toolbars");
493 sett.remove(bar->objectName());
499 std::vector<QToolBar*> bars;
501 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
503 sett.beginGroup(
"toolbars");
504 QStringList lst = sett.childGroups();
506 QStringList::iterator it;
508 for(it=lst.begin(); it != lst.end(); ++it)
514 QString grName = sett.value(
"name").toString();
516 int size = sett.beginReadArray(
"Actions");
518 QToolBar* toolbar =
new QToolBar(barsParent);
519 toolbar->setObjectName(grName);
520 toolbar->setWindowTitle(grName);
522 for(
int i=0; i<size; i++)
524 sett.setArrayIndex(i);
525 QString act = sett.value(
"action").toString();
529 toolbar->addSeparator();
533 QAction* a = ApplicationController::getInstance().findAction(act);
536 toolbar->addAction(a);
543 bars.push_back(toolbar);
553 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
555 sett.beginGroup(
"mainWindow");
556 sett.setValue(
"geometry", mainWindow->saveGeometry());
557 sett.setValue(
"windowState", mainWindow->saveState());
563 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
565 sett.beginGroup(
"mainWindow");
566 mainWindow->restoreGeometry(sett.value(
"geometry").toByteArray());
567 mainWindow->restoreState(sett.value(
"windowState").toByteArray());
573 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
575 sett.beginGroup(
"projects");
576 defaultAuthor = sett.value(
"author_name").toString();
577 maxSaved = sett.value(
"recents_history_size").toInt();
583 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
585 sett.beginGroup(
"projects");
586 sett.setValue(
"author_name", defaultAuthor);
587 sett.setValue(
"recents_history_size", maxSaved);
593 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
595 sett.setValue(
"projects/last datasource used", dsType);
600 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
602 sett.setValue(
"projects/openLastDataSource", openLast);
607 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
609 return sett.value(
"projects/last datasource used").toString();
614 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
616 QVariant variant = sett.value(
"projects/openLastDataSource");
619 if(variant.isNull() || !variant.isValid())
622 return variant.toBool();
627 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
629 sett.beginGroup(
"toolbars");
631 sett.beginGroup(
"File Tool Bar");
632 sett.setValue(
"name",
"File Tool Bar");
633 sett.beginWriteArray(
"Actions");
634 sett.setArrayIndex(0);
635 sett.setValue(
"action",
"File.New Project");
636 sett.setArrayIndex(1);
637 sett.setValue(
"action",
"File.Open Project");
638 sett.setArrayIndex(2);
639 sett.setValue(
"action",
"File.Save Project");
640 sett.setArrayIndex(3);
641 sett.setValue(
"action",
"");
642 sett.setArrayIndex(4);
643 sett.setValue(
"action",
"Project.New Folder");
644 sett.setArrayIndex(5);
645 sett.setValue(
"action",
"Project.Add Layer.All Sources");
649 sett.beginGroup(
"View Tool Bar");
650 sett.setValue(
"name",
"View Tool Bar");
651 sett.beginWriteArray(
"Actions");
652 sett.setArrayIndex(0);
653 sett.setValue(
"action",
"View.Layer Explorer");
654 sett.setArrayIndex(1);
655 sett.setValue(
"action",
"View.Map Display");
656 sett.setArrayIndex(2);
657 sett.setValue(
"action",
"View.Data Table");
658 sett.setArrayIndex(3);
659 sett.setValue(
"action",
"View.Style Explorer");
663 sett.beginGroup(
"Map Tool Bar");
664 sett.setValue(
"name",
"Map Tool Bar");
665 sett.beginWriteArray(
"Actions");
666 sett.setArrayIndex(0);
667 sett.setValue(
"action",
"Map.Draw");
668 sett.setArrayIndex(1);
669 sett.setValue(
"action",
"Map.Previous Extent");
670 sett.setArrayIndex(2);
671 sett.setValue(
"action",
"Map.Next Extent");
672 sett.setArrayIndex(3);
673 sett.setValue(
"action",
"Map.Zoom Extent");
674 sett.setArrayIndex(4);
675 sett.setValue(
"action",
"");
676 sett.setArrayIndex(5);
677 sett.setValue(
"action",
"Map.Zoom In");
678 sett.setArrayIndex(6);
679 sett.setValue(
"action",
"Map.Zoom Out");
680 sett.setArrayIndex(7);
681 sett.setValue(
"action",
"Map.Pan");
682 sett.setArrayIndex(8);
683 sett.setValue(
"action",
"");
684 sett.setArrayIndex(9);
685 sett.setValue(
"action",
"Map.Info");
686 sett.setArrayIndex(10);
687 sett.setValue(
"action",
"Map.Selection");
693 sett.beginGroup(
"projects");
695 sett.setValue(
"author_name",
"");
696 sett.setValue(
"recents_history_size",
"8");
703 QString result(windowTitle);
707 if(result.at(result.count()-1) !=
'*')
712 if(result.at(result.count()-1) ==
'*')
713 result.remove((result.count()-1), 1);
721 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
722 QString hexColor = sett.value(
"display/defaultDisplayColor").toString();
724 defaultColor.setNamedColor(hexColor);
725 if(!defaultColor.isValid())
733 QString sty(
"alternate-background-color: ");
734 sty +=
"rgb(" + QString::number(secondaryColor.red()) +
", " + QString::number(secondaryColor.green());
735 sty +=
", " + QString::number(secondaryColor.blue()) +
")";
736 sty +=
";background-color: rgb(" + QString::number(primaryColor.red()) +
", " + QString::number(primaryColor.green());
737 sty +=
", " + QString::number(primaryColor.blue()) +
");";
744 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
747 pColor.setNamedColor(sett.value(
"table/primaryColor").toString());
749 sColor.setNamedColor(sett.value(
"table/secondaryColor").toString());
751 if(!pColor.isValid())
753 if(!sColor.isValid())
761 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
762 bool isChecked = sett.value(
"table/tableAlternateColors").toBool();
769 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
771 sett.beginGroup(
"toolbars");
772 QStringList lst = sett.childGroups();
773 QStringList::iterator it;
775 for(it=lst.begin(); it!=lst.end(); ++it)
777 int size = sett.beginReadArray(*it+
"/Actions");
779 for(
int i=0; i<size; i++)
781 sett.setArrayIndex(i);
783 QString v = sett.value(
"action").toString();
785 if (v == act->objectName())
787 ApplicationController::getInstance().getToolBar(*it)->addAction(act);
800 std::vector<std::string> res;
804 filters <<
"*.teplg";
808 QFileInfoList files = d.entryInfoList(filters, QDir::Files);
810 foreach(QFileInfo file, files)
812 res.push_back(file.absoluteFilePath().toStdString());
820 std::vector<std::string> res;
825 if (pluginsPath ==
"")
829 boost::property_tree::ptree pt;
830 boost::property_tree::json_parser::read_json(pluginsPath, pt);
832 BOOST_FOREACH(boost::property_tree::ptree::value_type &v, pt.get_child(
"plugins"))
834 res.push_back(v.second.get<std::string>(
"plugin"));
842 std::vector<std::string> res;
843 std::vector<std::string>::const_iterator it;
845 for(it=plgFiles.begin(); it!=plgFiles.end(); ++it)
847 boost::property_tree::ptree p;
848 boost::property_tree::read_xml(*it, p, boost::property_tree::xml_parser::trim_whitespace);
850 res.push_back(p.get<std::string>(
"PluginInfo.Name"));
858 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
860 return sett.value(
"configuration/generation").toString();
865 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
867 sett.setValue(
"configuration/generation", dateTime);
872 QSettings sett(QSettings::IniFormat, QSettings::UserScope, qApp->organizationName(), qApp->applicationName());
874 QFileInfo info(sett.fileName());
876 return info.absolutePath();
881 QFileInfo info(fileName);
886 info.dir().remove(info.fileName());
888 std::string olderFile = appSett.
getValue(
"Application.UserSettingsFile.<xmlattr>.xlink:href");
890 appSett.
setValue(
"Application.UserSettingsFile.<xmlattr>.xlink:href", fileName.toStdString());
894 info.setFile(olderFile.c_str());
895 info.dir().remove(info.fileName());
898 info.setFile(fileName);
902 #if BOOST_VERSION > 105600
903 boost::property_tree::xml_writer_settings<std::string> settings(
'\t', 1);
905 boost::property_tree::xml_writer_settings<char> settings(
'\t', 1);
907 boost::property_tree::write_xml(fileName.toStdString(), usrSett.
getAllSettings(), std::locale(), settings);
910 usrSett.
load(fileName.toStdString());
915 boost::property_tree::ptree p;
920 p.add(
"Project.<xmlattr>.xmlns:xsd",
"http://www.w3.org/2001/XMLSchema-instance");
921 p.add(
"Project.<xmlattr>.xmlns:te_map",
"http://www.terralib.org/schemas/maptools");
922 p.add(
"Project.<xmlattr>.xmlns:te_qt_af",
"http://www.terralib.org/schemas/qt/af");
923 p.add(
"Project.<xmlattr>.xmlns",
"http://www.terralib.org/schemas/qt/af");
924 p.add(
"Project.<xmlattr>.xsd:schemaLocation",
"http://www.terralib.org/schemas/qt/af " + schema_location);
925 p.add(
"Project.<xmlattr>.version", TERRALIB_VERSION_STRING);
928 p.add(
"Project.Title",
"Default project");
929 p.add(
"Project.Author",
"");
930 p.add(
"Project.ComponentList",
"");
931 p.add(
"Project.te_map:LayerList",
"");
934 #if BOOST_VERSION > 105600
935 boost::property_tree::xml_writer_settings<std::string> settings(
'\t', 1);
937 boost::property_tree::xml_writer_settings<char> settings(
'\t', 1);
939 boost::property_tree::write_xml(fileName.toStdString(), p, std::locale(), settings);
944 QString fileName = qApp->applicationDirPath() +
"/../.generated";
947 if (!f.open(QFile::ReadOnly | QFile::Text))
951 QString s = in.readAll();
961 title +=
TE_TR(
"Project:");
963 title += project.
getTitle().c_str();
968 std::string filename = p.filename().string();
970 title += filename.c_str();
979 QString extensionFilter = appName;
980 extensionFilter += QString(
" (*.");
981 extensionFilter += appProjectExtension +
")";
983 return extensionFilter;
TEQTAFEXPORT void RemoveToolBarFromSettings(QToolBar *bar)
Removes a tool bar from the settings.
TECOMMONEXPORT std::string ConvertLatin1UTFString(const std::string &data, const bool &toUtf=true)
Converts a string from latin1 to utf8 and vice-versa.
TEQTAFEXPORT void UpdateToolBarsInTheSettings()
Update plugins file.
std::map< std::string, DataSourceInfoPtr >::iterator iterator
TEQTAFEXPORT QColor GetDefaultDisplayColorFromSettings()
TEQTAFEXPORT std::vector< std::string > GetPluginsFiles()
const std::string & getTitle() const
It gets the title of the project.
This class models a XML reader object.
TEQTAFEXPORT void CreateDefaultSettings()
Creates a default QSettings.
virtual void writeStartElement(const std::string &qName)=0
TECOMMONEXPORT std::string FindInTerraLibPath(const std::string &p)
Returns the path relative to a directory or file in the context of TerraLib.
TEQTAFEXPORT void SaveOpenLastProjectOnSettings(bool openLast)
TEQTAFEXPORT QString GetWindowTitle(const Project &project)
Return a QString with the new window title based on the project informations.
virtual void writeValue(const std::string &value)=0
A singleton for managing application settings applied to a single user.
TEQTAFEXPORT void SetDateTime(const QString &dateTime)
TEQTAFEXPORT std::vector< QToolBar * > ReadToolBarsFromSettings(QWidget *barsParent=0)
Returns a vector of tool bars registered in the QSettings.
This class models the concept of a project for the TerraLib Application Framework.
static te::xml::AbstractWriter * make()
It creates a new XML writer using the dafault implementation.
TEQTAFEXPORT QString UnsavedStar(const QString windowTitle, bool isUnsaved)
Unsaved star.
void setValue(const std::string &key, const std::string &value)
It stores the value according to the key.
static te::xml::Reader * make()
It creates a new XML reader using the dafault implementation.
TEQTAFEXPORT void SaveLastDatasourceOnSettings(const QString &dsType)
This class models a XML writer object.
#define TE_TR(message)
It marks a string in order to get translated.
TEQTAFEXPORT void SaveState(QMainWindow *mainWindow)
TEQTAFEXPORT void UpdateUserSettings(const QStringList &prjFiles, const QStringList &prjTitles, const std::string &userConfigFile)
Updates user settings file section about information of the projects.
TEQTAFEXPORT bool GetAlternateRowColorsFromSettings()
virtual std::string getElementLocalName() const =0
It returns the local part of the element name in the case of an element node.
TEQTAFEXPORT void SaveDataSourcesFile()
Saves data sources file.
TEQTAFEXPORT void AddToolBarToSettings(QToolBar *bar)
Update settings with a new tool bar.
const std::list< te::map::AbstractLayerPtr > & getTopLayers() const
It gets all the top layers of the project (folder and single layers).
virtual void writeElement(const std::string &qName, const std::string &value)=0
te::map::AbstractLayer * read(te::xml::Reader &reader) const
TEQTAFEXPORT void UpdateUserSettingsFile(const QString &fileName, const bool &removeOlder=true)
Changes the user settings file location.
TEQTAFEXPORT void AddActionToCustomToolbars(QAction *act)
Check QSettings for existance of act and adds it if necessary.
TEQTAFEXPORT void SaveProjectInformationsOnSettings(const QString &defaultAuthor, const int &maxSaved)
static DataSourceInfoManager & getInstance()
It returns a reference to the singleton instance.
TEQTAFEXPORT std::vector< std::string > GetDefaultPluginsNames()
virtual void writeToFile()=0
TEQTAFEXPORT QString GetDefaultConfigFileOutputDir()
Returns the default path for output of configuration file.
TEQTAFEXPORT QString GetStyleSheetFromColors(QColor primaryColor, QColor secondaryColor)
void setProjectAsChanged(const bool &changed)
It sets the project status as changed or not.
A singleton for managing application settings applied to the whole system (all users).
TEDATAACCESSEXPORT void Save(const std::string &fileName)
TEQTAFEXPORT void GetProjectInformationsFromSettings(QString &defaultAuthor, int &maxSaved)
An exception class for the TerraLib Application Framework.
TEQTAFEXPORT void RestoreState(QMainWindow *mainWindow)
TEQTAFEXPORT QString GetGenerationDate()
Returns the date and time of generated binary.
TEQTAFEXPORT QString GetDateTime()
TEQTAFEXPORT QString GetExtensionFilter()
Return extension filter string.
TEQTAFEXPORT void WriteDefaultProjectFile(const QString &fileName)
Writes the configuration file. It updates the application settings.
void setFileName(const std::string &fName)
It sets the filename where the project will be saved.
TEQTAFEXPORT QString GetStyleSheetFromSettings()
virtual void writeAttribute(const std::string &attName, const std::string &value)=0
const std::string & getAuthor() const
It gets the author of the project.
TEQTAFEXPORT Project * ReadProject(const std::string &uri)
Reads and return a te::qt::af::Project from the file.
This class models the concept of a project for the TerraLib Application Framework.
void write(const te::map::AbstractLayer *alayer, te::xml::AbstractWriter &writer) const
virtual NodeType getNodeType() const =0
It return the type of node read.
void load(const std::string &fileName)
It tries to find a default config file based on system macros and default condigurations.
void AddToolbarAndActions(QToolBar *bar, QSettings &sett)
virtual std::string getElementValue() const =0
It returns the element data value in the case of VALUE node.
virtual void writeEndElement(const std::string &qName)=0
virtual void writeStartDocument(const std::string &encoding, const std::string &standalone)=0
Utility routines for the TerraLib Application Framework module.
TEQTAFEXPORT bool GetOpenLastProjectFromSettings()
const boost::property_tree::ptree & getAllSettings() const
It return a reading reference to the internal settings.
std::string getValue(const std::string &key)
It returns the value for a given key or empty.
const std::string & getFileName() const
It gets the filename where the project is saved.
#define TERRALIB_APPLICATION_DATASOURCE_FILE_NAME
The default name for the application file containing the list of data sources.
TEQTAFEXPORT void Save(const Project &project, const std::string &uri)
Saves the informations of the project in the uri file.
boost::intrusive_ptr< AbstractLayer > AbstractLayerPtr
virtual bool next()=0
It gets the next event to be read.
TEQTAFEXPORT std::vector< std::string > GetPluginsNames(const std::vector< std::string > &plgFiles)
The base API for controllers of TerraLib applications.
TEQTAFEXPORT QString GetLastDatasourceFromSettings()
boost::shared_ptr< DataSourceInfo > DataSourceInfoPtr
TEDATAACCESSEXPORT void ReadDataSourceInfo(const std::string &datasourcesFileName)