Changeset 1388 for fmts


Ignore:
Timestamp:
Mar 25, 2012, 11:53:47 PM (13 years ago)
Author:
George Lilly
Message:

new $$tagRoot command

File:
1 edited

Legend:

Unmodified
Added
Removed
  • fmts/trunk/p/C0XGET1.m

    r1387 r1388  
    3737 s zobj=$$IENOF($$EXT^C0XUTIL($g(obj)),fary) ; ien of object
    3838 s zgraph=$$IENOF($g(graph),fary) ; ien of graph
    39  W !,"s:",zsub," p:",zpred," o:",zobj
     39 I $G(DEBUG) W !,"s:",zsub," p:",zpred," o:",zobj
    4040 d trip(.tmprtn,zsub,zpred,zobj,zgraph,fary)
    4141 n ztmp
     
    151151 s zobj=$$IENOF($$EXT^C0XUTIL($g(obj)),fary) ; ien of object
    152152 s zgraph=$$IENOF($g(graph),fary) ; ien of graph
    153  W !,"s:",zsub," p:",zpred," o:",zobj
     153 I $G(DEBUG) W !,"s:",zsub," p:",zpred," o:",zobj
    154154 d trip(.tmprtn,zsub,zpred,zobj,zgraph,fary)
    155155 d ien2tary(.zrary,"tmprtn") ; convert to triples
     
    206206 s zobj=$$IENOF($$EXT^C0XUTIL($g(obj)),fary) ; ien of obj
    207207 s zgraph=$$IENOF($g(graph),fary) ; ien of graph
    208  W !,"s:",zsub," p:",zpred," o:",zobj
     208 I $G(DEBUG) W !,"s:",zsub," p:",zpred," o:",zobj
    209209 n c0xflag,zi,zx,zt
    210210 s zt=$na(^C0X(101)) ;
     
    240240 s zx=itbl(c0xflag,zi) ; executable instruction to run
    241241 ;i $g(ngraph)'="" s zi="G"_zi ; this is wrong.. don't do graphs yet
    242  w !,c0xflag," ",zw," ",zt," ",zi," ",zx,!
     242 i $g(DEBUG) w !,c0xflag," ",zw," ",zt," ",zi," ",zx,!
    243243 ;zwr itbl
    244244 x zx
     
    352352 s zx=itbl(c0xflag,zi) ; executable instruction to run
    353353 i $g(ngraph)'="" s zi="G"_zi
    354  w !,zx
     354 i $g(DEBUG) w !,zx
    355355 x zx
    356356 q
     
    460460 q $$WHERETXT^C0XF2N(zo)
    461461 ;
     462tagRoot(ztag) ; extrinsic which returns the root for graphs and subjects
     463 ; associated with ztag
     464 n zs,zo
     465 s zs=$$subject("fmts:fileTag",ztag)
     466 i zs="" d  q "" ;
     467 . w !,"error, tag is either missing or there are more than one ",ztag
     468 s zo=$$object(zs,"fmts:root")
     469 i zo="" d  q "" ;
     470 . w !,"error, root not found ",zs
     471 ;w !,zo
     472 q zo
     473 ;
Note: See TracChangeset for help on using the changeset viewer.