Хранитель (шаблон проектирования): различия между версиями
[непроверенная версия] | [непроверенная версия] |
Содержимое удалено Содержимое добавлено
добавление модификатора final в memento |
→C#: Memento instance is meant to be returned from GetMemento method and not a Foo instance. |
||
Строка 400:
object IOriginator.GetMemento()
{
return new
}
Строка 408:
if (Object.ReferenceEquals(memento, null))
throw new ArgumentNullException("memento");
if (!(memento is
throw new ArgumentException("memento");
StringProperty = ((Memento)memento).StringProperty;
IntProperty = ((
}
|