GH_StateServer

List<1>References
Maintains all the recorded states for this document.

Constructors

GH_StateServer

#
public GH_StateServer()

Properties

Names

#
Gets a list of all the state names in this server.
public List<string> Names { get; }

Owner

#
Gets the document that owns this server.
public GH_Document Owner { get; }

Methods

NewStateFromDocument

#
Displays UI for new state creation. If the user aborts, then null is returned. If the user successfully defines a new state, it is appended to this server.
public GH_State NewStateFromDocument()

Read

#
public bool Read(
reader
)
Read

RemoveState

#
Remove a certain state. This method adds an undo record to the document.
public bool RemoveState(
index
Index of state to remove.
)
True on success, false on failure.

RestoreState

#
Restore a certain state.
public bool RestoreState(
index,
Index of state to restore.
recompute,
If True, a new solution will be started right away.
ref int
restored_objects,
Number of objects successfully restored.
ref int
missing_objects
Number of objects that could not be found.
)
True on success, false on failure.

RestoreState

#
Restore a certain state.
public bool RestoreState(
index,
Index of state to restore.
ref int
restored_objects,
Number of objects successfully restored.
ref int
missing_objects
Number of objects that could not be found.
)
True on success, false on failure.

RestoreState

#
Restore a certain state.
public bool RestoreState(
name,
Name of state to restore. Name is case-sensitive.
ref int
restored_objects,
Number of objects successfully restored.
ref int
missing_objects
Number of objects that could not be found.
)
True on success, false on failure.

Write

#
public bool Write(
writer
)
Write