ModifierInterface interface
Contract for Modifiers.
Signature:
interface ModifierInterface<TOptions extends KeyValueObject = KeyValueObject> extends EventEmitter<ModifierEvents>
Extends: EventEmitter<ModifierEvents>
Remarks
Modifiers are a fundamental part of the Core3D SDK that describe the application of a ResourceInterface in a Design i.e. a link between the resource and design.
When a ResourceInterface is applied to a Design (e.g. using ) a ModifierInterface is returned.
Properties
Property |
Modifiers |
Type |
Description |
---|---|---|---|
|
boolean |
Used by isModifier(). |
Methods
Method |
Description |
---|---|
Clone the modifier. | |
Destroy the modifier. | |
Get the default value for an option key. | |
Get all option defaults. | |
Get the unique ID of this modifier. | |
Whether the modifier is currently rendering. | |
Get any custom metadata for this resource. | |
Get the current value of an option key. | |
Get all current option values. | |
Get the value of an option key, falling back to the default. | |
Render this modifier. | |
Reset an option by key back to | |
Reset all options to | |
Set a unique ID for this modifier. | |
Set custom metadata for this modifier. | |
Set an option by key. | |
Set options with a key/value object. | |
Set the associated resource. | |
Serialize this resource to JSON. |