dummy-name:add
List of: Scheme Extensions
Subjects: Debugging
Contents: Kernel

Action: Adds a dummy naming attribute which can be used to test the annotation callbacks.

Filename: kern/kern_scm/anno_scm.cxx

Syntax: (dummy-name:add entity string)

Arg Types: entity entity

string string

Returns: entity


entity specifies the entity for attaching the attribute.


string specifies the attribute that has to be attached.

Example: ; dummy-name:add

; Set options

(option:set 'annotations #t)

;; #f

(option:set 'unhook_annotations #f)

;; #t

; Define a profile

(define profile (wire-body:points (list


(position 0 0 0) (position 10 0 0)


(position 10 10 0) (position 0 10 0)


(position 0 0 0))))

;; profile

; Define a path

(define path (edge:linear (position 0 0 0)


(position 0 0 10)))

;; path


; Attach a DUMMY_NAME attribute to the edges of

; the profile

(define dummy (dummy-name:add (entity:edges profile)


"ProfileEdge"))

;; dummy

; Sweep the entity

(define opt (sweep:options "draft_angle" 10


"gap_type" "n" 'solid #t))

;; opt

(define sweep (sweep:law profile path opt))

;; sweep

; View annotations on a profile edge and verify the

; derived tag was created from the information in

; the dummy name

(map entity:debug (entity:annotations


(car (entity:edges profile))) (make-list 100 2))

; sweep_anno_edge_top **** 471552:

; Rollback pointer: 450936

; Attribute list : id_attribute 0 -10304

; path

: tag **** 578864

;




tag **** 578864:

; Rollback pointer: NULL

; Attribute list : NULL

; Owning entity : NULL

; Previous attrib : NULL

; Next attribute : NULL

; actual

: edge **** -18120

; StartVtx
: point **** -12800:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinates
: 0, 0, 0

; EndVtx

: point **** -12736:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinate
: 0, 0, 10

;

; profile
: derived_tag **** 578912

;



derived_tag **** 578912:

; Rollback pointer: NULL

; Attribute list : NULL

; Owning entity : NULL

; Previous attrib : NULL

; Next attribute : NULL

; m_string
: ProfileEdge

; actual

: edge **** -17544

; StartVt

: point **** -13184:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinates : 0, 10, 0

; EndVtx
; point **** -13512:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinates
: 0, 0, 0

;

; top_edge
: edge **** 552608

; actual
:
edge **** 552608

; StartVtx
: point **** 471936:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinates
: -1.7632698070846,

;




-1.7632698070846, 10

; EndVtx
:
point **** 523392:

; Rollback pointer: NULL

; Attribute list : NULL

; Use count
: 1

; Coordinates
: -1.7632698070846,

;




11.763269807085, 10

;; ("sweep_anno_edge_top")
PDF/KERN/12SCA.PDF
HTM/DATA/KERN/KERN/12SCA/0055.HTM