Next: Index of Routines
Up: Overview/Use of routines
Previous: Channel numbers
It is recommended that for each type of entity read in from the CAD file format a separate routine should be created to make the necessary re-arrangement of data a calls to the user routines.
Generally routines have the same parameters :
SUBROUTINE UIxxxx(IWHAT,INDEX,NAME,ISTYPE,
1 LREAL,RDATA,LINTG,IDATA,LPTR,IPTR,
2 IERROR)
C
C --- IN : IWHAT : ACTION REQUESTED ON ENTITY (integer*4)
C : 1 : CREATE
C : 2 : FIND
C : 3 : REPLACE
C : 4 : READ
C : 5 : DELETE
C
C --- IN/OUT : INDEX : POINTER TO INSTANCE (integer*4)
C : NAME : ENTITY NAME (character*8)
C : ISTYPE : ENTITY SUB-TYPE (integer*4)
C : LREAL : NUMBER OF REALS (integer*4)
C : RDATA : ARRAY OF REAL DATA (real*4 array)
C : LINTG : NUMBER OF INTEGERS (integer*4)
C : IDATA : ARRAY OF INTEGER DATA (integer*4 array)
C : LPTR : NUMBER OF POINTERS (integer*4)
C : IPTR : ARRAY OF POINTER DATA (integer*4 array)
C
C --- OUT : IERROR : 0 : OK (integer*4)
C : 1 : ILLEGAL ACTION REQUESTED
C : 2 : INCORRECT POINTER TO ENTITY
C : 3 : ILLEGAL SUB-TYPE
C : 5 : INCORRECT DATA
C
An entity is normally created by specifying its sub-type and the relevant data. The NAME can either be set to the name required or set to blank in which case a name will be generated by the routine.
INDEX will be returned as the pointer to the new entity.
Pointers to undefined attributes like material or physical properties should be set to zero.
A part must exist in the database before it can be referenced in the definition of another part, but other than this condition of not allowing forward referencing, the user is in control of which order he defines his parts.