|
Isis Developer Reference
|
Go to the documentation of this file.
18 #include <QUndoCommand>
30 class QXmlStreamWriter;
42 class XmlStackedHandlerReader;
361 void save(QXmlStreamWriter &stream)
const;
364 virtual void setData(QString data);
465 bool isInStableState()
const;
466 void listenForImageDestruction();
467 void listenForShapeDestruction();
468 void resetProgressBar();
469 void setProgressToFinalText();
472 void attemptQueuedAction();
473 void executionFinished();
474 void clearImageList();
475 void clearShapeList();
476 void updateProgress();
483 enum QueuedWorkOrderAction {
501 virtual bool startElement(
const QString &namespaceURI,
const QString &localName,
502 const QString &qName,
const QXmlAttributes &atts);
505 Q_DISABLE_COPY(XmlHandler);
549 bool m_createsCleanState;
556 bool m_modifiesDiskState;
558 QueuedWorkOrderAction m_queuedAction;
563 int m_progressRangeMinValue;
567 int m_progressRangeMaxValue;
575 QPointer<ImageList> m_imageList;
576 QPointer<ShapeList> m_shapeList;
577 QPointer<ControlList> m_controlList;
626 QPointer<WorkOrder> m_nextWorkOrder;
631 QPointer<WorkOrder> m_previousWorkOrder;
636 QPointer<Project> m_project;
642 QMutex *m_transparentConstMutex;
647 QDateTime m_executionTime;
654 QPointer< QFutureWatcher<void> > m_futureWatcher;
661 QPointer<ProgressBar> m_progressBar;
666 QPointer<QTimer> m_progressBarUpdateTimer;
671 QPointer<QTimer> m_progressBarDeletionTimer;
677 QTime *m_elapsedTimer;
682 double m_secondsElapsed;
@ WorkOrderRedoing
Definition: WorkOrder.h:324
bool isSynchronous() const
Returns true if this work order is run synchronously, otherwise false.
Definition: WorkOrder.cpp:841
bool isUndoable() const
Returns true if this work order is undoable, otherwise false.
Definition: WorkOrder.cpp:819
virtual bool dependsOn(WorkOrder *other) const
Indicate workorder dependency This is a virtual function whose role in child classes is to determine ...
Definition: WorkOrder.cpp:781
virtual bool setupExecution()
This sets up the state for the work order.
Definition: WorkOrder.cpp:1261
bool isRedone() const
Returns the WorkOrder redone status.
Definition: WorkOrder.cpp:893
void addCloneToProject()
Runs a copy of the current WorkOrder and stores it in the project.
Definition: WorkOrder.cpp:1452
Definition: Directory.h:271
bool isGuiCamera() const
Returns true if a GuiCameraQsp is stored in the data of the item.
Definition: ProjectItem.cpp:735
Provide Undo/redo abilities, serialization, and history for an operation.
Definition: WorkOrder.h:311
Definition: ProgressBar.h:15
Shape * shape(QString id)
Return a shape given its id.
Definition: Project.cpp:1539
bool isControl() const
Returns true if a Control is stored in the data of the item.
Definition: ProjectItem.cpp:690
void finished(WorkOrder *)
Image * image() const
Returns the Image stored in the data of the item.
Definition: ProjectItem.cpp:476
int progressMax() const
Gets the maximum value of the progress range of the WorkOrder.
Definition: WorkOrder.cpp:1337
bool isRedoing() const
Returns the redoing status of this WorkOrder.
Definition: WorkOrder.cpp:883
virtual void redo()
Starts (or enqueues) a redo.
Definition: WorkOrder.cpp:1043
QPointer< ControlList > controlList()
Returns the Control List for this WorkOrder (a list of control networks).
Definition: WorkOrder.cpp:706
virtual bool isExecutable(Context)
Re-implement this method if your work order utilizes controls for data in order to operate.
Definition: WorkOrder.cpp:182
ImageList * imageList()
Returns a pointer to the ImageList for this WorkOrder.
Definition: WorkOrder.cpp:631
CorrelationMatrix correlationMatrix() const
Returns the CorrelationMatrix stored the item.
Definition: ProjectItem.cpp:556
bool m_isSavedToHistory
Set the work order to be shown in the HistoryTreeWidget.
Definition: WorkOrder.h:537
Maintains a list of Controls so that control nets can easily be copied from one Project to another,...
Definition: ControlList.h:44
@ Unknown
A type of error that cannot be classified as any of the other error types.
Definition: IException.h:118
virtual void postExecution()
Perform any necessary actions after execution of a workorder.
Definition: WorkOrder.cpp:1414
virtual void pushContentHandler(XmlStackedHandler *newHandler)
Push a contentHandler and maybe continue parsing...
Definition: XmlStackedHandlerReader.cpp:55
void setInternalData(QStringList data)
Sets the internal data for this WorkOrder.
Definition: WorkOrder.cpp:1318
bool isTargetBody() const
Returns true if a TargetBodyQsp is stored in the data of the item.
Definition: ProjectItem.cpp:746
Shape * shape() const
Returns the Shape stored in the data of the item.
Definition: ProjectItem.cpp:496
int progressMin() const
Gets the minimum value of the progress range of the WorkOrder.
Definition: WorkOrder.cpp:1327
static QString toString(WorkOrderStatus)
Gets the current status of the WorkOrder.
Definition: WorkOrder.cpp:1009
void save(QXmlStreamWriter &stream) const
: Saves a WorkOrder to a data stream.
Definition: WorkOrder.cpp:544
Directory * directory() const
return the workorder project directory Returns the Directory object of the Project this WorkOrder is ...
Definition: WorkOrder.cpp:1290
WorkOrder * next() const
Gets the next WorkOrder.
Definition: WorkOrder.cpp:934
void append(Image *const &value)
Appends an image to the image list.
Definition: ImageList.cpp:153
@ WorkOrderUnknownStatus
Definition: WorkOrder.h:322
bool isCorrelationMatrix() const
Returns true if a CorrelationMatrix is stored in the data of the item.
Definition: ProjectItem.cpp:713
virtual bool startElement(const QString &namespaceURI, const QString &localName, const QString &qName, const QXmlAttributes &atts)
Definition: XmlStackedHandler.cpp:44
bool createsCleanState() const
Returns the CleanState status (whether the Project has been saved to disk or not).
Definition: WorkOrder.cpp:854
QSharedPointer< TargetBody > TargetBodyQsp
Defines A smart pointer to a TargetBody obj.
Definition: TargetBody.h:216
bool isControlList() const
Returns true if a ControlList is stored in the data of the item.
Definition: ProjectItem.cpp:702
bool modifiesDiskState() const
Returns the modified disk state.
Definition: WorkOrder.cpp:924
Control * control() const
Returns the Control stored in the data of the item.
Definition: ProjectItem.cpp:536
void read(XmlStackedHandlerReader *xmlReader)
Read this work order's data from disk.
Definition: WorkOrder.cpp:520
void deletingProgress(WorkOrder *)
bool m_isSynchronous
This is defaulted to true.
Definition: WorkOrder.h:530
bool isShape() const
Returns true if an Shape is stored in the data of the item.
Definition: ProjectItem.cpp:668
void creatingProgress(WorkOrder *)
Manage a stack of content handlers for reading XML files.
Definition: XmlStackedHandlerReader.h:30
This is a container for the correlation matrix that comes from a bundle adjust.
Definition: CorrelationMatrix.h:61
The main project for ipce.
Definition: Project.h:289
Directory * directory() const
Returns the directory associated with this Project.
Definition: Project.cpp:1229
bool isFinished() const
Returns the finished state of this WorkOrder.
Definition: WorkOrder.cpp:874
Internalizes a list of images and allows for operations on the entire list.
Definition: ImageList.h:55
ShapeList * shapeList()
@briefReturns a pointer to the ShapeList for this WorkOrder.
Definition: WorkOrder.cpp:663
void addToProject(WorkOrder *)
This executes the WorkOrder and stores it in the project.
Definition: Project.cpp:2598
void disableWorkOrder()
Disables the work order.
Definition: WorkOrder.cpp:1230
bool isImageList() const
Returns true if an ImageList is stored in the data of the item.
Definition: ProjectItem.cpp:657
WorkOrder(Project *project)
Create a work order that will work with the given project.
Definition: WorkOrder.cpp:41
QString id() const
Get a unique, identifying string associated with this shape.
Definition: Shape.cpp:459
bool m_isUndoable
Set the workorder to be undoable/redoable This is defaulted to true - his will allow the workorder to...
Definition: WorkOrder.h:523
bool isSavedToHistory() const
Returns true if this work order is to be shown in History, otherwise false.
Definition: WorkOrder.cpp:830
#define _FILEINFO_
Macro for the filename and line number.
Definition: IException.h:24
bool isShapeList() const
Returns true if an ShapeList is stored in the data of the item.
Definition: ProjectItem.cpp:679
virtual void setData(Context)
Sets the context data for this WorkOrder.
Definition: WorkOrder.cpp:248
GuiCameraQsp guiCamera() const
Returns the GuiCameraQsp stored in the data of the item.
Definition: ProjectItem.cpp:576
bool isImage() const
Returns true if an Image is stored in the data of the item.
Definition: ProjectItem.cpp:646
QString statusText() const
WorkOrder::statusText.
Definition: WorkOrder.cpp:954
bool isUndone() const
Returns the WorkOrder undo status.
Definition: WorkOrder.cpp:913
TargetBodyQsp targetBody()
WorkOrder::targetBody.
Definition: WorkOrder.cpp:746
ShapeList * shapeList() const
Returns the ShapeList stored in the data of the item.
Definition: ProjectItem.cpp:506
bool isFileItem() const
Returns true if a FileItemQsp is stored in the data of the item.
Definition: ProjectItem.cpp:757
virtual void postUndoExecution()
Perform any steps necessary after an undo of a workorder.
Definition: WorkOrder.cpp:1445
Definition: Template.h:30
virtual void undo()
Starts (or enqueues) an undo.
Definition: WorkOrder.cpp:1146
This represents a shape in a project-based GUI interface.
Definition: Shape.h:68
Template * getTemplate()
WorkOrder::getTemplate.
Definition: WorkOrder.cpp:736
Project * project() const
Returns the Project this WorkOrder is attached to.
Definition: WorkOrder.cpp:1300
FileItemQsp fileItem() const
Returns the FileItemQsp stored in the data of the item.
Definition: ProjectItem.cpp:597
void statusChanged(WorkOrder *)
@ WorkOrderUndoing
Definition: WorkOrder.h:326
virtual void undoExecution()
Execute the steps necessary to undo this workorder.
Definition: WorkOrder.cpp:1434
int progressValue() const
Gets the current progress value of the WorkOrder.
Definition: WorkOrder.cpp:1347
WorkOrder * previous() const
Gets the previous WorkOrder.
Definition: WorkOrder.cpp:944
Q_DECLARE_METATYPE(Isis::WorkOrder *)
This allows WorkOrder *'s to be stored in a QVariant.
Internalizes a list of shapes and allows for operations on the entire list.
Definition: ShapeList.h:33
This represents a cube in a project-based GUI interface.
Definition: Image.h:107
Isis exception class.
Definition: IException.h:91
static WorkOrderStatus fromStatusString(QString)
Attempts to query the current status of the WorkOrder.
Definition: WorkOrder.cpp:988
virtual ~WorkOrder()
The Destructor.
Definition: WorkOrder.cpp:157
FileItemQsp fileItem()
WorkOrder::fileItem.
Definition: WorkOrder.cpp:766
void setNext(WorkOrder *nextWorkOrder)
Sets the next WorkOrder in the sequence.
Definition: WorkOrder.cpp:613
ControlList * controlList() const
Returns the ControlList stored in the data of the item.
Definition: ProjectItem.cpp:546
bool isProject() const
Returns true if a Project is stored in the data of the item.
Definition: ProjectItem.cpp:724
void setProgressRange(int, int)
Sets the progress range of the WorkOrder.
Definition: WorkOrder.cpp:1358
Image * image(QString id)
Return an image given its id.
Definition: Project.cpp:1509
@ Programmer
This error is for when a programmer made an API call that was illegal.
Definition: IException.h:146
QString bestText() const
Generate unique action names We don't use action text anymore because Directory likes to rename our a...
Definition: WorkOrder.cpp:795
GuiCameraQsp guiCamera()
WorkOrder::guiCamera.
Definition: WorkOrder.cpp:756
@ NoContext
Definition: WorkOrder.h:340
QSharedPointer< FileItem > FileItemQsp
A FileItem smart pointer.
Definition: FileItem.h:36
@ WorkOrderFinished
This is used for work orders that will not undo or redo (See createsCleanState())
Definition: WorkOrder.h:331
QString id() const
Get a unique, identifying string associated with this image.
Definition: Image.cpp:445
void setProgressValue(int)
Sets the current progress value for the WorkOrder.
Definition: WorkOrder.cpp:1368
ProgressBar * progressBar()
Returns the ProgressBar.
Definition: WorkOrder.cpp:975
ImageList * imageList() const
Returns the ImageList stored in the data of the item.
Definition: ProjectItem.cpp:486
XML Handler that parses XMLs in a stack-oriented way.
Definition: XmlStackedHandler.h:118
WorkOrderStatus
This enumeration is used by other functions to set and retrieve the current state of the WorkOrder.
Definition: WorkOrder.h:321
This is free and unencumbered software released into the public domain.
Definition: AbstractTableModel.h:24
QStringList internalData() const
Gets the internal data for this WorkOrder.
Definition: WorkOrder.cpp:1377
void append(Shape *const &value)
Appends an shape to the shape list.
Definition: ShapeList.cpp:133
virtual void execute()
Execute the workorder.
Definition: WorkOrder.cpp:1403
void setModifiesDiskState(bool changesProjectOnDisk)
Definition: WorkOrder.cpp:1674
CorrelationMatrix correlationMatrix()
Returns the CorrleationMatrix for this WorkOrder.
Definition: WorkOrder.cpp:696
void setPrevious(WorkOrder *previousWorkOrder)
Sets the previous WorkOrder in the sequence.
Definition: WorkOrder.cpp:622
void setCreatesCleanState(bool createsCleanState)
Declare that this work order is saving the project.
Definition: WorkOrder.cpp:1663
virtual WorkOrder * clone() const =0
Context
This enumeration is for recording the context of the current Workorder (whether it is part of a proje...
Definition: WorkOrder.h:339
QSharedPointer< GuiCamera > GuiCameraQsp
GuiCameraQsp Represents a smart pointer to a GuiCamera object.
Definition: GuiCamera.h:186
Template * getTemplate() const
Returns the Template stored in the data of the item.
Definition: ProjectItem.cpp:516
@ WorkOrderNotStarted
Definition: WorkOrder.h:323
bool isUndoing() const
Returns the WorkOrderUndoing state.
Definition: WorkOrder.cpp:903
@ WorkOrderUndone
Definition: WorkOrder.h:327
void enableWorkOrder()
Enables the work order.
Definition: WorkOrder.cpp:1218
@ WorkOrderLastStatus
Definition: WorkOrder.h:332
QDateTime executionTime() const
Gets the execution time of this WorkOrder.
Definition: WorkOrder.cpp:864
@ ProjectContext
Definition: WorkOrder.h:341
This is free and unencumbered software released into the public domain.
Definition: Apollo.h:16
@ WorkOrderRedone
Definition: WorkOrder.h:325
TargetBodyQsp targetBody() const
Returns the TargetBodyQsp stored in the data of the item.
Definition: ProjectItem.cpp:587
WorkOrderStatus m_status
Definition: WorkOrder.h:539
Represents an item of a ProjectItemModel in Qt's model-view framework.
Definition: ProjectItem.h:134
bool isTemplate() const
Definition: ProjectItem.cpp:602