GH_ArchivedUndoAction

GH_UndoActionReferences
public abstract class GH_ArchivedUndoAction : GH_UndoAction
Base class implementation for undo actions that require (de)serialization of data.

Fields

m_data

#
protected byte[] m_data
Internal data storage for serialized archives.

Properties

ExpiresDisplay

public virtual bool ExpiresDisplay { get; }
Override this property if you want the Rhino viewport display to refresh upon undo completion.
inherited fromGH_UndoAction
ExpiresDisplay

ExpiresSolution

public virtual bool ExpiresSolution { get; }
Override this property if you want the Grasshopper solution to refresh upon undo completion.
inherited fromGH_UndoAction
ExpiresSolution

State

public GH_UndoState State { get; }
inherited fromGH_UndoAction
State

Methods

Deserialize

#
protected void Deserialize(GH_ISerializable obj)
Deserializes the obj from the local archive.
obj (GH_ISerializable)
ArgumentNullExceptionThrown when obj is a null reference.
NullReferenceExceptionThrown when the internal archive data is null.
IOExceptionThrown when the deserialization fails.

Internal_Redo

protected abstract void Internal_Redo(GH_Document doc)
inherited fromGH_UndoAction
doc (GH_Document)

Internal_Undo

protected abstract void Internal_Undo(GH_Document doc)
inherited fromGH_UndoAction
doc (GH_Document)

Read

#
public override bool Read(GH_IReader reader)
reader (GH_IReader)

Redo

public void Redo(GH_Document doc)
inherited fromGH_UndoAction
doc (GH_Document)
Redo

Serialize

#
protected void Serialize(GH_ISerializable obj)
Serializes the obj into the local archive.
obj (GH_ISerializable)Object to serialize

SerializeToByteArray

#
protected byte[] SerializeToByteArray(GH_ISerializable obj)
Serializes the obj into the local archive.
obj (GH_ISerializable)Object to serialize

Undo

public void Undo(GH_Document doc)
inherited fromGH_UndoAction
doc (GH_Document)
Undo

Write

#
public override bool Write(GH_IWriter writer)
writer (GH_IWriter)