NXOpen .NET Reference
12.0.0
|
Represents an NXOpen.AttributePropertiesBaseBuilder to be used for creating attributes. More...
Public Types | |
enum | ObjectOptions { Object, Feature, Occurrence, ComponentInstance, ReferenceSet, ObjectInComponentPart, ComponentAsPartAttribute, Empty } |
Specifies which object will be used when applying attributes. More... | |
enum | DataTypeOptions { Null, Boolean, Integer, Number, String, Date } |
Specifies the data type of the attribute, this cannot be changed once the attribute has been created More... | |
enum | BooleanValueOptions { False, True } |
The value choices for an attribute of type Boolean More... | |
Public Member Functions | |
unsafe void | Delete (NXOpen.NXObject @object) |
Delete the attribute from the given object. More... | |
unsafe void | DeleteArray (NXOpen.NXObject @object) |
Delete the attribute array from the given object. More... | |
unsafe bool | CreateAttribute () |
Create the attribute from the data set in the builder. More... | |
unsafe bool | ApplyUnits () |
Apply the units currently set on the builder to any objects that have a value set for the current attribute. More... | |
unsafe void | SetAttributeObjects (NXOpen.NXObject[] objects) |
Sets the array of objects that have this attribute More... | |
Public Member Functions inherited from NXOpen.Builder | |
unsafe NXOpen.NXObject | Commit () |
Commits any edits that have been applied to the builder. More... | |
unsafe void | Destroy () |
Deletes the builder, and cleans up any objects created by the builder. More... | |
unsafe NXOpen.NXObject[] | GetCommittedObjects () |
For builders that create more than one object, this method returns the objects that are created by commit. More... | |
unsafe NXOpen.NXObject | GetObject () |
Returns the object currently being edited by this builder. More... | |
unsafe void | ShowResults () |
Updates the model to reflect the result of an edit to the model for all builders that support showing results. More... | |
unsafe bool | Validate () |
Validate whether the inputs to the component are sufficient for commit to be called. More... | |
Properties | |
unsafe int | ArrayIndex [get, set] |
Returns or sets the array index. More... | |
unsafe NXOpen.AttributePropertiesBaseBuilder.BooleanValueOptions | BooleanValue [get, set] |
Returns or sets the boolean value. More... | |
unsafe string | Category [get, set] |
Returns or sets the category. More... | |
unsafe NXOpen.AttributePropertiesBaseBuilder.DataTypeOptions | DataType [get, set] |
Returns or sets the data type, which determines the type of attribute to be created. More... | |
unsafe NXOpen.DateBuilder | DateValue [get] |
Returns the date value. More... | |
unsafe NXOpen.Expression | Expression [get, set] |
Returns or sets the expression referenced from this attribute. More... | |
unsafe int | IntegerValue [get, set] |
Returns or sets the integer value. More... | |
unsafe bool | IsArray [get, set] |
Returns or sets the 'is array' flag is set for attributes that have more than one value. More... | |
unsafe bool | IsReferenceType [get, set] |
Returns or sets the 'is reference type' flag is set for attributes that are linked to system expressions. More... | |
unsafe bool | LockOnSave [get, set] |
Returns or sets the 'LockOnSave' flag is set for attributes that will be locked once the part is saved (and reloaded) More... | |
unsafe double | NumberValue [get, set] |
Returns or sets the number value. More... | |
unsafe NXOpen.AttributePropertiesBaseBuilder.ObjectOptions | ObjectPicker [get, set] |
Returns or sets the object picker. More... | |
unsafe NXOpen.SelectNXObjectList | SelectedObjects [get] |
Returns the selected object(s) list. More... | |
unsafe string | StringValue [get, set] |
Returns or sets the string value. More... | |
unsafe string | Title [get, set] |
Returns or sets the attribute title. More... | |
unsafe string | Units [get, set] |
Returns or sets the units associated with an attribute of type Number. More... | |
unsafe string | ValueAlias [get, set] |
Returns or sets the value alias. More... | |
Represents an NXOpen.AttributePropertiesBaseBuilder to be used for creating attributes.
A basic attribute consists of a title, a type, and a value. There are six types of attributes: Null, Boolean, Integer, Number, String, and Date. The type detemines which value field will be read during creation. An attribute may reference an expression instead of setting a value. In this case, the referenced expression's value will also serve as the attribute's value and will update when the expression changes.
If an attribute template exists with the same title as the attribute, then the attribute will assume all characteristics of the cooresponding template including the type. Attribute templates reside at the part level and provide extra information for referencing attributes. They are created using NXOpen.AttributeTemplatesBuilder .
The attribute will be distributed to all objects supplied in the selected object list.
This is an abstract class, and cannot be instantiated.
Created in NX8.0.0
Specifies the data type of the attribute, this cannot be changed once the attribute has been created
Specifies which object will be used when applying attributes.
The options available are determined by the objects passed in. These options will not be used if the object passed in is a part.
unsafe bool NXOpen.AttributePropertiesBaseBuilder.ApplyUnits | ( | ) |
Apply the units currently set on the builder to any objects that have a value set for the current attribute.
This method does not apply the current value set on the builder. NXOpen.AttributePropertiesBaseBuilder.CreateAttribute should be used for doing that.
Created in NX11.0.0
License requirements: None.
unsafe bool NXOpen.AttributePropertiesBaseBuilder.CreateAttribute | ( | ) |
Create the attribute from the data set in the builder.
Unlike calling commit, this method will not perform an update.
Created in NX8.0.0
License requirements: None.
unsafe void NXOpen.AttributePropertiesBaseBuilder.Delete | ( | NXOpen.NXObject @ | object | ) |
Delete the attribute from the given object.
Created in NX8.0.0
License requirements: None.
object | The object containing the attribute |
unsafe void NXOpen.AttributePropertiesBaseBuilder.DeleteArray | ( | NXOpen.NXObject @ | object | ) |
Delete the attribute array from the given object.
Created in NX8.0.0
License requirements: None.
object | The object containing the attribute |
unsafe void NXOpen.AttributePropertiesBaseBuilder.SetAttributeObjects | ( | NXOpen.NXObject[] | objects | ) |
Sets the array of objects that have this attribute
Created in NX8.5.0
License requirements: None.
objects | the array of objects |
|
getset |
Returns or sets the array index.
Required if modifying an attribute that has more than one value. The IsArray flag must also be set.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the boolean value.
Required if creating an attribute of type Boolean.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the category.
The category is an optional, user-defined string that allows attributes to be grouped together.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the data type, which determines the type of attribute to be created.
Once the attribute is created, the data type cannot be modified.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
get |
Returns the date value.
The Date object will contain the value for an attribute of type Date.
Created in NX8.0.0
License requirements: None.
|
getset |
Returns or sets the expression referenced from this attribute.
Only used for attributes of type Number, Integer, Boolean, and String. If an expression is referenced, no value fields need to be set, as the attribute uses the value from the expression.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the integer value.
Required if creating an attribute of type Integer.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the 'is array' flag is set for attributes that have more than one value.
When this is set, the index needs to be provided to indicate which element will be modified.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the 'is reference type' flag is set for attributes that are linked to system expressions.
The type must also be set to String for the Reference attribut to be created/edited. If a Reference attribute is no longer linked to a system expression, it will become a String attribute.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the 'LockOnSave' flag is set for attributes that will be locked once the part is saved (and reloaded)
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the number value.
Required if creating an attribute of type Number.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the object picker.
This determines what objects the attribute will be applied to. If modified, the select object list will change based on this value.
Created in NX8.0.0
Deprecated in NX10.0.0. Use NXOpen.AttributePropertiesBaseBuilder.SetAttributeObjects instead.
License requirements to get this property: None.
License requirements to set this property: None.
|
get |
Returns the selected object(s) list.
The created attribute will be applied to all objects in this list.
Created in NX8.0.0
License requirements: None.
|
getset |
Returns or sets the string value.
Required if creating an attribute of type String.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the attribute title.
The title is required for creating an attribute and must be unique on the given object. Once the attribute is created, the title cannot be modified.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the units associated with an attribute of type Number.
Once the attribute is created, the unit measure (length, area, etc) cannot be changed. However the units (mm, ft, etc) within the measure can be changed.
Created in NX8.0.0
License requirements to get this property: None.
License requirements to set this property: None.
|
getset |
Returns or sets the value alias.
Optional for any attribute.
Created in NX10.0.0
License requirements to get this property: None.
License requirements to set this property: None.