Design Pattern Examples
Overview of object-oriented design patterns
Memento Struct Reference

Represents a single memento (snapshot) of the text state before an operation is applied. The operation becomes the name of the memento for display purposes. More...

#include <Memento_Memento.h>

Collaboration diagram for Memento:
Collaboration graph

Public Attributes

char * text
 The snapshot to be remembered by the Memento.
 
const char * name
 The operation name that triggered the need for this Memento.
 

Detailed Description

Represents a single memento (snapshot) of the text state before an operation is applied. The operation becomes the name of the memento for display purposes.

Definition at line 16 of file Memento_Memento.h.

Member Data Documentation

◆ name

const char* name

The operation name that triggered the need for this Memento.

Definition at line 19 of file Memento_Memento.h.

Referenced by Memento_Create(), Memento_Destroy(), and Memento_Undo().

◆ text

char* text

The snapshot to be remembered by the Memento.

Definition at line 18 of file Memento_Memento.h.

Referenced by Memento_Create(), Memento_Destroy(), and Memento_Undo().


The documentation for this struct was generated from the following file: