Message 1 of 3
Unique ID For Objects
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
When you create an object (even non-graphical object like blockdefinition) in AutoCAD, AutoCAD assigns a unique (in that drawing) ID to it. (As far as I remember, only selection sets do not have handles). AutoCAD retains this handle even when that object is deleted. It is not assigned to any other object in that drawing.
In programming, this handle is available as EntityName in AutoLISP and ObjectID in VB. (These are however different from the handle). This has many advantages, especially in programming.
For example, I can share the same object in multiple languages using conversion like EntityName > Handle > ObjecttID and vice versa. Also storing objects in variables becomes easier.
Most of the Solid Modellers (Inventor, SolidEdge) must be having this concept internally. However, none of them expose anything similar to handle in API. This causes inconvenience in identifying objects and storing them in variables.
They provide other facilities like ReferenceKey or Attributes. But this means extra work for the programmers.
My questions:
1) Why solid Modelling APIs do not provide this facility. What could be the pros and cons.
2) Do you think they should provide this for making the life of Progrmmers a bit more easier?
Your take on this.
In programming, this handle is available as EntityName in AutoLISP and ObjectID in VB. (These are however different from the handle). This has many advantages, especially in programming.
For example, I can share the same object in multiple languages using conversion like EntityName > Handle > ObjecttID and vice versa. Also storing objects in variables becomes easier.
Most of the Solid Modellers (Inventor, SolidEdge) must be having this concept internally. However, none of them expose anything similar to handle in API. This causes inconvenience in identifying objects and storing them in variables.
They provide other facilities like ReferenceKey or Attributes. But this means extra work for the programmers.
My questions:
1) Why solid Modelling APIs do not provide this facility. What could be the pros and cons.
2) Do you think they should provide this for making the life of Progrmmers a bit more easier?
Your take on this.