File Context Operators(work in progress)

KEY:
D: Dyadic; M: Monadic; N: Niladic

Commentary     Op Code Result
Commentary N =>#FC Set CWD #fc.cwd =>c;
'c:\glee'=> #FC ; #fc .cwd $;
c => #fc;

c:\glee\
Commentary N #FC Create File Context #fc.cwd => c;
'c:\glee'=> #fc;
"<1>---" $; #FC $;
"<2>---" $; #FC =>fc; fc %** $;
"<3>---" $; fc.fc $;
"<4>---" $; fc.fpath $;
"<5>---" $;
'website' #fc => fc; fc %** $;
"<6>---" $; fc.fc $;
"<7>---" $; fc.fpath $;
"<8>---" $;
'website\bases'=>[.fc]fc; fc $;
"<9>---" $; fc.fc $;
"<10>---" $; fc.fpath $;
c => #fc;
<1>---
<2>---
FCtxt[I77R1C1:P]
<3>---
<4>---
c:\glee\
<5>---
FCtxt[I191R1C1:P]website\
<6>---
website\
<7>---
c:\glee\website\
<8>---
website\bases\
<9>---
website\bases\
<10>---
c:\glee\website\bases\
Commentary M #FC Create File Context #fc.cwd =>c;
'c:\glee'=> #fc;
"<1>--------"$;
'c:\glee\website' #FC => fc1;
fc1 $;
"<2>--------"$;
'bad path' #FC => fc2;
fc2.fc $; fc2.fpath $;
c => #fc;
<1>--------
c:\glee\website\
<2>--------
bad path\
c:\glee\bad path\
Commentary N #FC Change Working Directory #fc.cwd => c;
"<1>--------"$;
'website' #fc => ws $;
"<2>--------"$;
'c:\glee' #fc => glee $;
"<3>--------"$;
'c:\glee' => #fc; ws.fpath $;
"<4>--------"$; 'c:\glee'=> #fc;
ws.fpath $;
glee.fpath $;
glee,ws .fpath $;
c => #fc;
<1>--------
website\
<2>--------
glee\
<3>--------
c:\glee\website\
<4>--------
c:\website\
c:\glee\
c:\glee\website\
Commentary D =>[] Assign FC '<1>---' $;
'fc\was' #fc => fc; fc $;
'<2>---' $;
'fc\now'=>[.fc]fc; fc $;
<1>---
fc\was\
<2>---
fc\now\
Commentary M [] Indexing #fc.cwd => c;
'c:\glee' #fc => fc;
fc[] %** $;
c => #fc;
Seq[I768R1C3T:K]:
[1]File[I770R1C1:P]
  N:Glee.exe;FC:c:\glee\
[2]FCtxt[I774R1C1:P]website\
[3]FCtxt[I777R1C1:P]GLEEScripts\
Commentary D , Catenate #fc.cwd => c;
'c:\glee'=> #fc;
"<1>-----"$; 'dir1'#fc => fc1 $;
"<2>-----"$; 'dir2'#fc => fc2 $;
"<3>-----"$; fc1,fc2 %** $;
"<4>-----"$;
(#fc.path #fc),fc2 => fc3 $;
"<5>-----"$;
('p1'#fc),('d:'#fc) => fc4 $;
c => #fc;
<1>-----
dir1\
<2>-----
dir2\
<3>-----
FCtxt[I434R1C1:P]dir1\dir2\
<4>-----
c:\glee\dir2\
<5>-----
('p1'#fc),('d:'#fc)
           ^Value error
  RT Absolute:
Commentary M -> Relative Name Part 'd1\d2\d3'#fc =>fc;
'<1> ' ( fc )$;
'<2> ' ( fc -> )$;
<1> c:\d1\d2\d3\
<2> d3\
Commentary D -> n Relative Name and Path 'd1\d2\d3'#fc =>fc;
'<1> ' ( fc -> 2 ) $;
'<2> ' ( fc ->99 ) $;
'<3> ' ( fc -> _2 %** )$;
<1> d2\d3\
<2> d1\d2\d3\
<3> FCtxt[I363R1C1:P]d3\
Commentary M <- Relative Path Part 'd1\d2\d3\d4'#fc =>fc;
'<1> ' ( fc <- )$;
<1> d3\
Commentary D <- n Relative Path Part 'd1\d2\d3\d4'#fc =>fc;
'<1> ' ( fc <- 2 )$;
'<2> ' ( fc <-99 )$;
'<3> ' ( fc <- _2 %** )$;
<1> d2\d3\
<2> d1\d2\d3\
<3> FCtxt[I539R1C1:P]d3\
Commentary M ->> Absolute Name Part #fc.cwd => c;
'c:\glee'=> #fc;
'd1\d2\d3'#fc =>fc;
'<1> ' ( fc )$;
'<2> ' ( fc ->> )$;
c => #fc;
<1> c:\d1\d2\d3\
<2> d3\
Commentary D ->> n Absolute Name and Path #fc.cwd => c;
'c:\glee'=> #fc;
'd1\d2\d3'#fc =>fc;
'<1> ' ( fc ->> 99 ) $;
'<2> ' ( fc ->> 2 ) $;
'<3> ' ( fc ->> _1 %** )$;
c => #fc;
<1> c:\glee\d1\d2\d3\
<2> d2\d3\
<3> FCtxt[I724R1C1:P]
  glee\d1\d2\d3\
Commentary M <<- Absolute Path Part #fc.cwd => c;
'c:\glee'=> #fc;
'd1\d2\d3\d4'#fc =>fc;
'<1> ' ( fc <<- )$;
c => #fc;
<1> d3\
Commentary D <<- n Absolute Path Part #fc.cwd => c;
'c:\glee'=> #fc;
'd1\d2\d3\d4'#fc =>fc;
'<1> ' ( fc <<- 99 )$;
'<2> ' ( fc <<- 2 )$;
'<3> ' ( fc <<- _1 %** )$;
c => #fc;
<1> c:\glee\d1\d2\d3\
<2> d2\d3\
<3> FCtxt[I909R1C1:P]
  glee\d1\d2\d3\
  M ~ Delete In Developement  
  M ~** Delete Deep In Developement  
  M * Touch In Developement  
  M ** Touch Deep In Developement  
Methods and Properties
Commentary  Prop Code Result
  .all 'c:\glee'#fc .all %**$; [1]File[I713R1C1:P]N:Glee.exe;FC:c:\glee\
[2]File[I715R1C1:P]N:GLEEDll.dll;FC:c:\glee\
[3]FCtxt[I716R1C1:P]Website\
  .create
.destroy
'c:\glee\user\testfile.txt'#file =>f;
'<1> '(f.create) $;
'<2> '(f.props) $;
'<3> '(f.destroy) $;
'<4> '(f.props) $;
<1> Bit[I901R2C1:B]1
<2> String[I954R2C40:C] D[X]; PPos[0]; B[Y]; E[Y]; Pos[0]; NE[0]
<3> Bit[I7R2C1:B]1
<4> No data
  .cwd 'c:\glee'=> #fc;
#fc .cwd %**$;
String[I536R2C8:C]c:\glee\
  .exists 'c:\glee\Website'#fc .exists $;
'c:\glee\Web'#fc .exists $;
1
0
Commentary .fc "<1>---------"$;
'c:\glee\website\bases'#fc =>fc;
'gbfld.htm' #file fc =>f; f.fc $;
f[0..18+ (f `->>&'field')] $;
"<2>---------"$;
'c:\glee\website\comments'=>[.fc]f;
'GCFLD.htm'=>[.name]f; f.name $;
f[0..23+(f `->>&'field')] $;
<1>---------
c:\glee\website\bases\
Field Base</TITLE>
<2>---------
GCFLD.htm
Field: Comments</TITLE>
  .fcs 'c:\glee'#fc .fcs %**$; Seq[I880R1C2T:K]:
[1]FCtxt[I881R1C1:P]Website\
  .files 'c:\glee'#fc .files %**$; Seq[I60R1C2T:K]:
[1]File[I62R1C1:P]N:Glee.exe;FC:c:\glee\
[2]File[I64R1C1:P]N:GLEEDll.dll;FC:c:\glee\
  .fname 'c:\glee.old'#fc .fname %** $; String[I120R1C8:C]glee.old
  .fpath 'c:\glee.old'#fc .fpath %** $; String[I168R1C12:C]c:\glee.old\
  .isabs 'c:\glee.old'#fc .isabs %** $;
'\glee.old'#fc .isabs %** $;
Bit[I267R1C1:B]1
Bit[I299R1C1:B]0
  .isempty 'c:\glee'#fc .isempty %** $;
'c:\glee\downloads'#fc .isempty %**$;
'bogus'#fc .isempty %**$;
Bit[I347R1C1:B]0
Bit[I380R1C1:B]1
Bit[I413R1C1:B]1
Commentary .name 'c:\glee\website\comments'#fc =>fc;
"<1>---------"$;
'GCActivity.htm'#file fc =>f;
f.name $; (f[1..25+141]) $;
"<2>---------"$;
'GCFLD.htm'=>[.name]f;
f.name $; (f[1..25+141]) $;
<1>---------
GCActivity.htm
<TITLE>Activity Comments
<2>---------
GCFLD.htm
<TITLE>Field: Comments</
  .path 'c:\glee\website'#fc .path %** $; String[I463R1C8:C]c:\glee\
Commentary .props 'c:\glee\website\bases'#fc =>fc;
'gbfld.htm' #file fc =>f;
f.props$;f @->> 2000; f.props $;
<1>------
D[X]; PPos[0]; B[Y]; E[N]; Pos[0]; NE[8249]
<2>------
D[X]; PPos[0]; B[N]; E[N]; Pos[2000]; NE[8249]
  .purge 'c:\glee\user\a\b'#fc =>fc;
'<1> '$;fc .create %**$;
'<2> '$;fc .tree %** $;
'<3> '$;fc .purge %** $;
'<4> '$;fc .tree %** $;
<1>
String[I857R2C17:C]c:\glee\user\a\b\
<2>
Seq[I919R2C2T:K]:
[1]String[I920R1C2:C]b\
[2]Seq[I918R1C0T:K]:
<3>
Seq[I974R2C0T:K]:
<4>
Seq[I39R2C2T:K]:
[1]String[I40R1C2:C]b\
[2]Seq[I38R1C0T:K]:
  .tree 'c:\glee\user\test'#fc =>fcb;
fcb.purge;
fcb #fc '\a\a1' .create;
fcb #fc '\b\b1' .create;
fcb #fc '\b\b2' .create;
fcb .tree %** $;
Seq[I289R2C2T:K]:
[1]String[I290R1C5:C]test\
[2]Seq[I288R1C2T:K]:
*[1]Seq[I294R1C2T:K]:
**[1]String[I295R1C2:C]a\
**[2]Seq[I293R1C1T:K]:
***[1]Seq[I299R1C2T:K]:
****[1]String[I300R1C3:C]a1\
****[2]Seq[I298R1C0T:K]:
*[2]Seq[I304R1C2T:K]:
**[1]String[I305R1C2:C]b\
**[2]Seq[I303R1C2T:K]:
***[1]Seq[I309R1C2T:K]:
****[1]String[I310R1C3:C]b1\
****[2]Seq[I308R1C0T:K]:
***[2]Seq[I314R1C2T:K]:
****[1]String[I315R1C3:C]b2\
****[2]Seq[I313R1C0T:K]:
  .treefull 'c:\glee'#fc .treefull %** $: Seq[I429R1C2T:K]:
[1]String[I430R1C6:C]glee\
[2]Seq[I428R1C4T:K]:
*[1]String[I431R1C8:C]Glee.exe
*[2]String[I432R1C11:C]GLEEDll.dll
*[3]Seq[I436R1C2T:K]:
**[1]String[I437R1C8:C]Website\
**[2]Seq[I435R1C13T:K]:
***[1]Seq[I441R1C2T:K]:
****[1]String[I442R1C6:C]Bases\
****[2]Seq[I440R1C65T:K]:
*****[1]String[I443R1C14:C]GBActivity.htm
*****[2]String[I444R1C9:C]GBBLK.htm
    ....