SlideShare a Scribd company logo
1 of 1
Download to read offline
c++
The following questions are about the Memento design pattern. 6.1 Both Serializer and Memento
design patterns save states of objects and can be used to provide a roll-back facility. When would
you use Memento instead of Serializer? 6.2 What objects does Caretaker hold? 6.3 Why is
originator a friend of Memento? (2) 6.4 Assume that a state of originator is saved at some stage
using the Memento design pattern. State the sequence of actions required to roll back to the
saved state of originator. (4)

More Related Content

More from NIRMALJAI08

C++ Deviation from Average (Recursion) Instructions Step 1- Write a.pdf
C++ Deviation from Average (Recursion)   Instructions Step 1- Write a.pdfC++ Deviation from Average (Recursion)   Instructions Step 1- Write a.pdf
C++ Deviation from Average (Recursion) Instructions Step 1- Write a.pdf
NIRMALJAI08
 

More from NIRMALJAI08 (20)

Caitlyn Communications reported the following figures from its adjuste.pdf
Caitlyn Communications reported the following figures from its adjuste.pdfCaitlyn Communications reported the following figures from its adjuste.pdf
Caitlyn Communications reported the following figures from its adjuste.pdf
 
C-CB+2A.pdf
C-CB+2A.pdfC-CB+2A.pdf
C-CB+2A.pdf
 
c- What is the probability that Z is between 1-51 and 1-81- The probab.pdf
c- What is the probability that Z is between 1-51 and 1-81- The probab.pdfc- What is the probability that Z is between 1-51 and 1-81- The probab.pdf
c- What is the probability that Z is between 1-51 and 1-81- The probab.pdf
 
C- Vitamin D is required for the absorption and deposition of calcium.pdf
C- Vitamin D is required for the absorption and deposition of calcium.pdfC- Vitamin D is required for the absorption and deposition of calcium.pdf
C- Vitamin D is required for the absorption and deposition of calcium.pdf
 
c- The login program will disallow logins of any students who enter th.pdf
c- The login program will disallow logins of any students who enter th.pdfc- The login program will disallow logins of any students who enter th.pdf
c- The login program will disallow logins of any students who enter th.pdf
 
C- Quantity Theory of Money In the country of Wiknam- assume that V is.pdf
C- Quantity Theory of Money In the country of Wiknam- assume that V is.pdfC- Quantity Theory of Money In the country of Wiknam- assume that V is.pdf
C- Quantity Theory of Money In the country of Wiknam- assume that V is.pdf
 
C- Picea mariana (black spruce) atsk This specimen was collected trom.pdf
C- Picea mariana (black spruce) atsk This specimen was collected trom.pdfC- Picea mariana (black spruce) atsk This specimen was collected trom.pdf
C- Picea mariana (black spruce) atsk This specimen was collected trom.pdf
 
c) Lefp and q be the pixels at coordinates (10-15) and (15-25) respect.pdf
c) Lefp and q be the pixels at coordinates (10-15) and (15-25) respect.pdfc) Lefp and q be the pixels at coordinates (10-15) and (15-25) respect.pdf
c) Lefp and q be the pixels at coordinates (10-15) and (15-25) respect.pdf
 
c- Identify a paraphyletic group in this phylogenetic tree and explain.pdf
c- Identify a paraphyletic group in this phylogenetic tree and explain.pdfc- Identify a paraphyletic group in this phylogenetic tree and explain.pdf
c- Identify a paraphyletic group in this phylogenetic tree and explain.pdf
 
C- elegans are one of the most common model organisms in biology- C-.pdf
C- elegans are one of the most common model organisms in biology-  C-.pdfC- elegans are one of the most common model organisms in biology-  C-.pdf
C- elegans are one of the most common model organisms in biology- C-.pdf
 
C and D are events with probabilities P(C)-0-15-P(D)-0-3- and P(C UD)-.pdf
C and D are events with probabilities P(C)-0-15-P(D)-0-3- and P(C UD)-.pdfC and D are events with probabilities P(C)-0-15-P(D)-0-3- and P(C UD)-.pdf
C and D are events with probabilities P(C)-0-15-P(D)-0-3- and P(C UD)-.pdf
 
C++ Merge(numbers- 0-2-5) is called- Complete the table for leftPos an.pdf
C++ Merge(numbers- 0-2-5) is called- Complete the table for leftPos an.pdfC++ Merge(numbers- 0-2-5) is called- Complete the table for leftPos an.pdf
C++ Merge(numbers- 0-2-5) is called- Complete the table for leftPos an.pdf
 
C++ Deviation from Average (Recursion) Instructions Step 1- Write a.pdf
C++ Deviation from Average (Recursion)   Instructions Step 1- Write a.pdfC++ Deviation from Average (Recursion)   Instructions Step 1- Write a.pdf
C++ Deviation from Average (Recursion) Instructions Step 1- Write a.pdf
 
C++ Data Structures and Algorithms Part 1- -- Write a program to dem.pdf
C++ Data Structures and Algorithms   Part 1- -- Write a program to dem.pdfC++ Data Structures and Algorithms   Part 1- -- Write a program to dem.pdf
C++ Data Structures and Algorithms Part 1- -- Write a program to dem.pdf
 
C) Which number identifies the region responsible for understanding sp.pdf
C) Which number identifies the region responsible for understanding sp.pdfC) Which number identifies the region responsible for understanding sp.pdf
C) Which number identifies the region responsible for understanding sp.pdf
 
c) Every week a family visits their favourite restaurant- The restaura.pdf
c) Every week a family visits their favourite restaurant- The restaura.pdfc) Every week a family visits their favourite restaurant- The restaura.pdf
c) Every week a family visits their favourite restaurant- The restaura.pdf
 
C programming Create a program to find the largest element of an arr.pdf
C programming   Create a program to find the largest element of an arr.pdfC programming   Create a program to find the largest element of an arr.pdf
C programming Create a program to find the largest element of an arr.pdf
 
C programing 1- What is the type of the formal parameters in the foll.pdf
C programing  1- What is the type of the formal parameters in the foll.pdfC programing  1- What is the type of the formal parameters in the foll.pdf
C programing 1- What is the type of the formal parameters in the foll.pdf
 
C program Write a loop that will prompt the user to enter characters.pdf
C program  Write a loop that will prompt the user to enter characters.pdfC program  Write a loop that will prompt the user to enter characters.pdf
C program Write a loop that will prompt the user to enter characters.pdf
 
BYou are studying a gene in C- elegans that on Chromosome III and is h.pdf
BYou are studying a gene in C- elegans that on Chromosome III and is h.pdfBYou are studying a gene in C- elegans that on Chromosome III and is h.pdf
BYou are studying a gene in C- elegans that on Chromosome III and is h.pdf
 

Recently uploaded

Recently uploaded (20)

Word Stress rules esl .pptx
Word Stress rules esl               .pptxWord Stress rules esl               .pptx
Word Stress rules esl .pptx
 
Open Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPointOpen Educational Resources Primer PowerPoint
Open Educational Resources Primer PowerPoint
 
“O BEIJO” EM ARTE .
“O BEIJO” EM ARTE                       .“O BEIJO” EM ARTE                       .
“O BEIJO” EM ARTE .
 
Salient features of Environment protection Act 1986.pptx
Salient features of Environment protection Act 1986.pptxSalient features of Environment protection Act 1986.pptx
Salient features of Environment protection Act 1986.pptx
 
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & EngineeringBasic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
Basic Civil Engg Notes_Chapter-6_Environment Pollution & Engineering
 
....................Muslim-Law notes.pdf
....................Muslim-Law notes.pdf....................Muslim-Law notes.pdf
....................Muslim-Law notes.pdf
 
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdfINU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
INU_CAPSTONEDESIGN_비밀번호486_업로드용 발표자료.pdf
 
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptxStudents, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
Students, digital devices and success - Andreas Schleicher - 27 May 2024..pptx
 
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
Operations Management - Book1.p  - Dr. Abdulfatah A. SalemOperations Management - Book1.p  - Dr. Abdulfatah A. Salem
Operations Management - Book1.p - Dr. Abdulfatah A. Salem
 
Features of Video Calls in the Discuss Module in Odoo 17
Features of Video Calls in the Discuss Module in Odoo 17Features of Video Calls in the Discuss Module in Odoo 17
Features of Video Calls in the Discuss Module in Odoo 17
 
Incoming and Outgoing Shipments in 2 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 2 STEPS Using Odoo 17Incoming and Outgoing Shipments in 2 STEPS Using Odoo 17
Incoming and Outgoing Shipments in 2 STEPS Using Odoo 17
 
2024_Student Session 2_ Set Plan Preparation.pptx
2024_Student Session 2_ Set Plan Preparation.pptx2024_Student Session 2_ Set Plan Preparation.pptx
2024_Student Session 2_ Set Plan Preparation.pptx
 
How to Manage Notification Preferences in the Odoo 17
How to Manage Notification Preferences in the Odoo 17How to Manage Notification Preferences in the Odoo 17
How to Manage Notification Preferences in the Odoo 17
 
Pragya Champions Chalice 2024 Prelims & Finals Q/A set, General Quiz
Pragya Champions Chalice 2024 Prelims & Finals Q/A set, General QuizPragya Champions Chalice 2024 Prelims & Finals Q/A set, General Quiz
Pragya Champions Chalice 2024 Prelims & Finals Q/A set, General Quiz
 
The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...The impact of social media on mental health and well-being has been a topic o...
The impact of social media on mental health and well-being has been a topic o...
 
The Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. HenryThe Last Leaf, a short story by O. Henry
The Last Leaf, a short story by O. Henry
 
Application of Matrices in real life. Presentation on application of matrices
Application of Matrices in real life. Presentation on application of matricesApplication of Matrices in real life. Presentation on application of matrices
Application of Matrices in real life. Presentation on application of matrices
 
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
UNIT – IV_PCI Complaints: Complaints and evaluation of complaints, Handling o...
 
How to Break the cycle of negative Thoughts
How to Break the cycle of negative ThoughtsHow to Break the cycle of negative Thoughts
How to Break the cycle of negative Thoughts
 
The Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve ThomasonThe Art Pastor's Guide to Sabbath | Steve Thomason
The Art Pastor's Guide to Sabbath | Steve Thomason
 

c++ The following questions are about the Memento design pattern- 6-1.pdf

  • 1. c++ The following questions are about the Memento design pattern. 6.1 Both Serializer and Memento design patterns save states of objects and can be used to provide a roll-back facility. When would you use Memento instead of Serializer? 6.2 What objects does Caretaker hold? 6.3 Why is originator a friend of Memento? (2) 6.4 Assume that a state of originator is saved at some stage using the Memento design pattern. State the sequence of actions required to roll back to the saved state of originator. (4)