DocumentObject
ReferencesNothing matches.
Abstract implementation of the IDocumentObject interface for all objects.
Constructors
Properties
Activity
#Gets or sets the active state of this object. Note that this property is meaningless for certain types of object.
Implements: Activity
ChildrenObjects
#Gets all immediate child objects that belong to the current object. It is possible that an object does not have any children, and it is possible that a child object has children of its own.
Implements: ChildrenObjects
Connectivity
#Gets the topological connectivity of this object. The topology is not updated automatically, so be sure to get a fresh instance every time you need it.
Implements: Connectivity
CustomValues
#Gets a collection of keyed values which can be used to store custom data which will survive (de)serialisation.
Implements: CustomValues
Display
#Gets or sets the display state of this object. Note that this property is meaningless for certain types of object.
Implements: Display
DisplayCapable
#Gets whether this object makes allowance for 3D viewport displays.
Implements: DisplayCapable
DisplayName
#Gets the display name of this object. Often the DisplayName is identical to the UserName, but there could be more complicated algorithms involved.
Implements: DisplayName
DisplayStyle
#Gets or sets the display style to use for the geometric data inside this object. Note that this property is meaningless for certain types of object.
Implements: DisplayStyle
Document
#Gets or sets the document this object belongs to. It is possible an object does not belong to any document, however it can never belong to more than one document simultaneously.
Implements: Document
EntireFamily
#Enumerates over all objects in the hierarchy this object is part of. This enumeration starts at the root object and then continues over all children and grandchildren in a breadth-first fashion.
Implements: EntireFamily
FoundingObject
#Gets the root or founding object in the object hierarchy. If the current object does not have a parent, it is a founding object.
Implements: FoundingObject
IconInternal
#Override this method to provide an icon for this object. If the icon is an embedded resource in this assembly with the same name as the class, it will automatically be loaded. The Icon property calls this property and caches the result.
InstanceId
#Gets or sets the instance Id for this object. The instance Id should be different for every instance of every type. Do *not* assign this Id unless you know exactly what you are doing.
Implements: InstanceId
ParentObject
#Gets or sets the parent object that owns this object. Top-level objects do not have parents. Do not assign or remove parents unless you know exactly what you are doing.
Implements: ParentObject
ProgressPercentage
#Gets the progress as a percentage. If this object is currently not calculating a new solution, this number is not meaningful.
Implements: ProgressPercentage
Relevance
#Gets or sets the auxiliary state of this object. Auxiliary objects are drawn in an inconspicuous way as they are considered in-between logic. Note that this property is meaningless for certain types of object.
Implements: Relevance
Selection
#Gets or sets the selected state of this object. Note that the selected setting of secondary objects is inherited from the parent.
Implements: Selection
StandardColourOverrides
#Methods
AddUndoRecord
#Add a single action undo record for this object.
Returns: Id of undo record.
Implements: AddUndoRecord
AppendStateInput
#Append the 'Enabled' and 'Display' states to this input panel.
Parameters:
| panel (InputPanel) | Panel to append to. |
| enabledState (bool) | If true, the Enabled state button will be modifiable. |
| displayState (bool) | If true, the Display state button will be modifiable. |
AppendToInputPanel
#Override this method to populate the popover panel. The base implementation does not add any panel inputs, however the DocumentObject class does provide a slew of protected utility methods for adding standard inputs.
Parameters:
| panel (InputPanel) |
Implements: AppendToInputPanel
AppendUserNameInput
#Append the user name text box within a category labelled 'Attributes'.
Parameters:
| panel (InputPanel) |
CreateAttributes
#Create default attributes for this object. If attributes already exist, this method will not replace them.
DisplayFaces
#Draw the shaded faces for this object.
Parameters:
| pipeline (DisplayPipeline) | |
| guises (Guises) | |
| extents (ref BoundingBox) |
Implements: DisplayFaces
DisplayWires
#Draw the wires for this object.
Parameters:
| pipeline (DisplayPipeline) | |
| guises (Guises) | |
| extents (ref BoundingBox) |
Implements: DisplayWires
Expire
#public abstract void Expire()
Expire this object and all objects that depend on it. This will request-cancel any running solutions inside whatever document contains this object.
Implements: Expire
ExpireDisplay
#protected void ExpireDisplay()
Expire the attributes and raise the DisplayChanged event.
GetCreationInfo
#Gets information about who created this component and when.
Returns: True if the creation data was available.
Implements: GetCreationInfo
GetModificationInfo
#Gets information about who last modified this component and when.
Parameters:
| name (out string) | Name of modifier. |
| time (out DateTime) | Time of modification in UTC coordinates. |
Returns: True if the modification data was available.
Implements: GetModificationInfo
InvalidateExistingLayout
#protected void InvalidateExistingLayout()
Invalidate the attribute layout, but only if the attributes already exist.
ModifyIcon
#Override the icon for this object. Use this judiciously.
Parameters:
| newIcon (IIcon) | New icon to assign, or null to revert to the default icon. |
| overrideExtrinsicIcon (bool = true) | If true, the permanent extrinsic icon will be overwritten. If false, the temporary intrinsic icon will be overwritten. |
Implements: ModifyIcon
ModifyNameAndInfo
#Programmatically modify the nickname, name and/or info strings on the Nomen.
Implements: ModifyNameAndInfo
OnDisplayChanged
#public void OnDisplayChanged()
Raise the DisplayChanged event.
Implements: OnDisplayChanged
OnLayoutChanged
#public void OnLayoutChanged()
Raise the LayoutChanged event.
Implements: OnLayoutChanged
OverrideAttributes
#Assign new attributes to this object. Not all attributes may be accepted, it depends on the implementation.
Parameters:
| attributes (IAttributes) | New attributes to assign. Assigning null will revert to default attributes. |
Returns: True if attributes were accepted.
Implements: OverrideAttributes
RequestAutoSave
#Request an autosave.
Parameters:
| reason (AutoSaveReason) | Autosave reason. |
| autosaveId (Guid) | Autosave Id. Consecutive requests with identical Ids are ignored. |
Implements: RequestAutoSave
RequestAutoSave
#Request an autosave using the instance ID of this object as a filter. This means hat subsequent autosave requests coming from the same object will be ignored.
Parameters:
| reason (AutoSaveReason) | Autosave reason. |
Implements: RequestAutoSave
SetCreationInfo
#public void SetCreationInfo()
Set the CreatedBy and CreatedAt fields if they haven't been set already.
Implements: SetCreationInfo
SetModificationInfo
#public void SetModificationInfo()
Set the ModifiedBy and ModifiedAt fields.
Implements: SetModificationInfo
SetProgressPercentage
#Set the ProgressPercentage field directly. The percentage is automatically limited to the [0, 100] interval.
Parameters:
| percentage (int) |
SetProgressPercentage
#Set the ProgressPercentage field based on a step count. This method always limits the percentage to the [1, 99] range, as 0% and 100% are oftentimes indicative of unstarted or completed processes, which probably gives the wrong impression.
UpdateDisplay
#Recreate the display caches based on the given solution data and display rules.
Parameters:
| data (SolutionData) | Data from which to extract display caches. |
| rules (DisplayRules) | Optional display rules. |
| token (CancellationToken) | Cancellation token. |
Implements: UpdateDisplay
Events
ActivityChanged
#Raised whenever the Enabled state of this object changes.
Implements: ActivityChanged
DocumentChanged
#Raised whenever this object becomes part of a different document.
Implements: DocumentChanged
InstanceIdChanged
#Raised whenever the InstanceId of this object changes.
Implements: InstanceIdChanged
LayoutChanged
#Raised whenever the layout of this object changes. Layout invalidation triggers a canvas redraw.
Implements: LayoutChanged
NameChanged
#Raised whenever the UserName of this object changes. This typically infers that the DisplayName also changes.
Implements: NameChanged
RelevanceChanged
#Raised whenever the Auxiliary state of this object changes.
Implements: RelevanceChanged
SelectedChanged
#Raised whenever the Selected state of this object changes.
Implements: SelectedChanged