Memento
E173617
Memento is a behavioral design pattern that captures and externalizes an object's internal state so it can be restored later without violating encapsulation.
All labels observed (1)
| Label | Occurrences |
|---|---|
| Memento canonical | 2 |
How this entity was disambiguated
This entity first appeared as the object of triple T1531330 — resolving that mention is where its identity was fixed. The disambiguator weighed these candidate entities and picked the highlighted one (or “None”, minting a new entity). This is how homonymy is resolved: the same surface form can point to different entities.
Target entity: Memento Context triple: [Design Patterns: Elements of Reusable Object-Oriented Software, describesPattern, Memento]
-
A.
Memento
Memento is a 2000 neo-noir psychological thriller film written and directed by Christopher Nolan, renowned for its non-linear narrative structure that explores memory, identity, and perception.
-
B.
Inception
Inception is a 2010 science fiction heist film directed by Christopher Nolan that explores dream manipulation and shared subconscious worlds.
-
C.
Memento Park
Memento Park is an open-air museum in Budapest that displays statues and monuments from Hungary’s communist era.
-
D.
Shutter Island
Shutter Island is a psychological thriller film directed by Martin Scorsese that follows a U.S. Marshal investigating a mysterious disappearance at a remote mental institution.
-
E.
Mulholland Drive
Mulholland Drive is a famous scenic road in Los Angeles known for its sweeping views of the city, the San Fernando Valley, and the Hollywood Hills.
- F. None of above. chosen
- G. Unsure - the case is ambiguous/there is not enough information to decide.
Target entity: Memento Target entity description: Memento is a behavioral design pattern that captures and externalizes an object's internal state so it can be restored later without violating encapsulation.
-
A.
Memento
Memento is a 2000 neo-noir psychological thriller film written and directed by Christopher Nolan, renowned for its non-linear narrative structure that explores memory, identity, and perception.
-
B.
Inception
Inception is a 2010 science fiction heist film directed by Christopher Nolan that explores dream manipulation and shared subconscious worlds.
-
C.
Memento Park
Memento Park is an open-air museum in Budapest that displays statues and monuments from Hungary’s communist era.
-
D.
Shutter Island
Shutter Island is a psychological thriller film directed by Martin Scorsese that follows a U.S. Marshal investigating a mysterious disappearance at a remote mental institution.
-
E.
Mulholland Drive
Mulholland Drive is a famous scenic road in Los Angeles known for its sweeping views of the city, the San Fernando Valley, and the Hollywood Hills.
- F. None of above. chosen
Statements (47)
| Predicate | Object |
|---|---|
| instanceOf |
behavioral design pattern
ⓘ
software design pattern ⓘ |
| allows |
restoring snapshots of an object’s state
ⓘ
saving snapshots of an object’s state ⓘ |
| alternativeName | Token (historical name in some literature) ⓘ |
| appliesTo |
objects with complex internal state
ⓘ
systems requiring reversible operations ⓘ |
| benefit |
decouples state storage from state management logic
ⓘ
maintains encapsulation boundaries ⓘ supports multiple levels of undo ⓘ |
| category | Gang of Four design pattern ⓘ |
| describedIn | Design Patterns: Elements of Reusable Object-Oriented Software ⓘ |
| drawback |
can consume significant memory if many mementos are stored
ⓘ
may incur performance overhead when frequently capturing state ⓘ |
| encapsulationLevel | hides implementation details of originator’s state representation ⓘ |
| ensures |
only the originator can access its own internal state in the memento
ⓘ
originator’s internal state is not exposed to the caretaker ⓘ |
| hasConstraint | must not violate encapsulation ⓘ |
| hasIntent |
allow restoring an object to a previous state
ⓘ
capture and externalize an object’s internal state ⓘ |
| hasParticipantRole |
Caretaker
ⓘ
Memento self-linksurface differs ⓘ Originator ⓘ |
| preserves | encapsulation of the originator object ⓘ |
| relatedTo |
Command
ⓘ
surface form:
Command (design pattern)
Prototype ⓘ
surface form:
Prototype (design pattern)
|
| responsibility |
creates mementos capturing its internal state
ⓘ
keeps track of mementos ⓘ passes mementos back to the originator for restoration ⓘ provides state back to the originator when requested ⓘ requests mementos from the originator ⓘ restores its state from a memento ⓘ stores the internal state of the originator ⓘ |
| roleInPattern |
Memento (design pattern)
ⓘ
Memento (design pattern) ⓘ Memento (design pattern) ⓘ |
| supports | non-invasive state restoration ⓘ |
| typicalImplementationDetail |
caretaker treats mementos as opaque objects
ⓘ
memento is immutable after creation ⓘ |
| typicalUseCase |
games saving and loading checkpoints
ⓘ
graphical editors with history of operations ⓘ text editors with undo and redo ⓘ transactional systems needing rollback ⓘ |
| usedFor |
implementing rollback functionality
ⓘ
implementing undo mechanisms ⓘ state checkpointing ⓘ time-travel or history features in applications ⓘ |
How these facts were elicited
The pipeline generated the facts above by prompting gpt-5.1 with this entity's name + description and the instruction below.
You are a knowledge base construction expert. Given a subject entity and a description of it, return factual statements that you know for the subject as a JSON list of dictionaries(triples), where keys must be "subject", "predicate" and "object". The number of facts may be very high, between 25 to 50 or more, for very popular subjects. For less popular subjects, the number of facts can be very low, like 5 or 10. # Requirements - If you don't know the subject at all, return an empty list. - If the subject is not a named entity, return an empty list. - Include at least one triple where predicate is "instanceOf". - Do not get too wordy. - Separate several objects into multiple triples with one object.
Subject: Memento Description of subject: Memento is a behavioral design pattern that captures and externalizes an object's internal state so it can be restored later without violating encapsulation.
Referenced by (2)
Full triples — surface form annotated when it differs from this entity's canonical label.