Envision
A visual programming IDE for object-oriented languages
List of all members | Public Member Functions | Private Attributes
Model::ListRemove Class Reference
Inheritance diagram for Model::ListRemove:
Model::NodeOwningCommand Model::UndoCommand

Public Member Functions

 ListRemove (Node *target, QVector< Node * > &nodes, int position)
 
virtual void redo ()
 
virtual void undo ()
 
- Public Member Functions inherited from Model::NodeOwningCommand
 NodeOwningCommand (Node *target, const QString &text, Node *ownedIfDone, Node *ownedIfUndone)
 
virtual ~NodeOwningCommand ()
 
virtual NodeinsertedNode () const override
 Returns the node that this command inserted into the tree, or nullptr if no node was inserted. More...
 
virtual Nodeowned () const override
 Returns the node owned by this command or nullptr if no node is owned. More...
 
virtual NoderemovedNode () const override
 Returns the node that this command removed from the tree, or nullptr if no node was removed. More...
 
- Public Member Functions inherited from Model::UndoCommand
 UndoCommand (Node *target, const QString &text)
 
virtual ~UndoCommand ()
 
bool isUndone () const
 Returns whether the command has been undone since it was applied. More...
 
Nodetarget () const
 

Private Attributes

QVector< Node * > & nodes
 
NoderemovedNode
 
int removePosition
 

Constructor & Destructor Documentation

◆ ListRemove()

Model::ListRemove::ListRemove ( Node target,
QVector< Node * > &  nodes,
int  position 
)

Member Function Documentation

◆ redo()

void Model::ListRemove::redo ( )
virtual

Reimplemented from Model::NodeOwningCommand.

◆ undo()

void Model::ListRemove::undo ( )
virtual

Reimplemented from Model::NodeOwningCommand.

Member Data Documentation

◆ nodes

QVector<Node*>& Model::ListRemove::nodes
private

◆ removedNode

Node* Model::ListRemove::removedNode
private

◆ removePosition

int Model::ListRemove::removePosition
private