Isis 3 Programmer Reference
|
#include <Template.h>
Public Slots | |
void | updateFileName (Project *project) |
Change the file name for this template to be where it now is with the given project. | |
Public Member Functions | |
Template (QString fileName, QString templateType, QString importName, QObject *parent=0) | |
Create a Template from template file's name. | |
Template (FileName templateFolder, QXmlStreamReader *xmlReader, QObject *parent=0) | |
Construct this template from XML. | |
~Template () | |
Destroys Template object. | |
QString | importName () const |
Get the name of the TemplateList this file was imported under. | |
QString | fileName () const |
Get the file name that this Template represents. | |
QString | templateType () const |
Get the type of template. | |
void | deleteFromDisk () |
Delete the template from disk. | |
void | save (QXmlStreamWriter &stream, const Project *project, FileName newProjectRoot) const |
Method to write this Template object's member data to an XML stream. | |
Private Attributes | |
QString | m_fileName |
QString | m_templateType |
QString | m_importName |
Definition at line 30 of file Template.h.
|
explicit |
Create a Template from template file's name.
fileName | The name of the template file on disk |
templateType | The type of template being imported (Options are maps or registrations) |
importName | The name of the TemplateList this Template is imported in |
parent | The Qt-relationship parent |
Definition at line 18 of file Template.cpp.
References fileName(), importName(), and templateType().
Isis::Template::Template | ( | FileName | templateFolder, |
QXmlStreamReader * | xmlReader, | ||
QObject * | parent = 0 ) |
Construct this template from XML.
templateFolder | Location of template xml |
xmlReader | An XML reader that's up to an <template> tag. |
parent | The Qt-relationship parent |
Definition at line 32 of file Template.cpp.
Isis::Template::~Template | ( | ) |
Destroys Template object.
Definition at line 41 of file Template.cpp.
void Isis::Template::deleteFromDisk | ( | ) |
Delete the template from disk.
IException::Io | "Could not remove file." |
Definition at line 87 of file Template.cpp.
References Isis::IException::Io.
QString Isis::Template::fileName | ( | ) | const |
Get the file name that this Template represents.
Definition at line 49 of file Template.cpp.
Referenced by Isis::TemplateEditViewWorkOrder::setupExecution(), and Template().
QString Isis::Template::importName | ( | ) | const |
Get the name of the TemplateList this file was imported under.
Definition at line 67 of file Template.cpp.
Referenced by Template().
QString Isis::Template::templateType | ( | ) | const |
Get the type of template.
Definition at line 58 of file Template.cpp.
Referenced by Template().
|
slot |
Change the file name for this template to be where it now is with the given project.
project | The project that this file is stored in. |
Definition at line 77 of file Template.cpp.
References Isis::FileName::name(), and Isis::Project::templateRoot().
|
private |
Definition at line 48 of file Template.h.
|
private |
Definition at line 50 of file Template.h.
|
private |
Definition at line 49 of file Template.h.