Ignore:
Timestamp:
Sep 26, 2012, 12:58:34 PM (12 years ago)
Author:
Sam Habiel
Message:

Proper KIDS build + Routines

File:
1 edited

Legend:

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

    r1365 r1539  
    1 C0XINIT ; GPL - Fileman Triples initialization routine ;10/13/11  17:05
    2  ;;0.1;C0X;nopatch;noreleasedate;Build 7
    3  ;Copyright 2011 George Lilly.  Licensed under the terms of the GNU
    4  ;General Public License See attached copy of the License.
    5  ;
    6  ;This program is free software; you can redistribute it and/or modify
    7  ;it under the terms of the GNU General Public License as published by
    8  ;the Free Software Foundation; either version 2 of the License, or
    9  ;(at your option) any later version.
    10  ;
    11  ;This program is distributed in the hope that it will be useful,
    12  ;but WITHOUT ANY WARRANTY; without even the implied warranty of
    13  ;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    14  ;GNU General Public License for more details.
    15  ;
    16  ;You should have received a copy of the GNU General Public License along
    17  ;with this program; if not, write to the Free Software Foundation, Inc.,
    18  ;51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
    19  ;
    20  Q
    21  ;
    22 CLEAR ; DELETE THE FILESTORE
    23  K ^C0X(101)
    24  K ^C0X(201)
    25  S ^C0X(101,0)="C0X TRIPLE^172.101I^^"
    26  S ^C0X(201,0)="C0X STRING^172.201I^^"
    27  Q
    28  ;
    29 INIT ; INITIALIZE THE TRIPLE STORE - THIS DELETES THE GLOBALS AND
    30  ; START ALL OVER... USE WITH CAUTION
    31  ;
    32  ; -- we should be more sophisticated here.. at least warn the user
    33  ; -- and give them a chance to cancel
    34  ;
    35  D CLEAR ; DELETE THE TRIPLESTORE
    36  ;
    37  ; -- we are assuming that FARY is set up properly in C0XF2N
    38  ; -- with repect to the default directory and the defaut fileman files
    39  ; -- here's what it is now: "/home/vista/gpl/fmts/trunk/samples/"
    40  ; -- that means that all the sample files will look like:
    41  ; --- qds/QDS_0001.rdf
    42  ; --- smart-rdf-in/small.rdf
    43  ;
    44  S FARY="C0XFARY"
    45  D INITFARY^C0XF2N(FARY)
    46  D USEFARY^C0XF2N(FARY)
    47  S C0XFARY("C0XDIR")="/home/vista/gpl/fmts/trunk/samples/smart-rdf-in/" ;
    48  D USEFARY^C0XF2N(FARY)
    49  S SMART(1)="cole-susan.rdf"
    50  S SMART(2)="jones-cynthia.rdf"
    51  S SMART(3)="small.rdf"
    52  S SMART(4)="collins-frank.rdf"
    53  S SMART(5)="kelly-david.rdf"
    54  S SMART(6)="smith-maria.rdf"
    55  S SMART(7)="ford-shirley.rdf"
    56  S SMART(8)="morgan-jason.rdf"
    57  S SMART(9)="west-lisa.rdf"
    58  S SMART(10)="gracia-paul.rdf"
    59  S SMART(11)="reed-richard.rdf"
    60  S SMART(12)="west-sandra.rdf"
    61  S SMART(13)="jackson-jessica.rdf"
    62  S SMART(14)="small-allergies.rdf"
    63  S SMART(15)="white-patricia.rdf"
    64  N ZI S ZI=""
    65  F  S ZI=$O(SMART(ZI)) Q:ZI=""  D  ; for each smart file
    66  . D IMPORT^C0XF2N(SMART(ZI),C0XDIR,,FARY) ; import to the triplestore
    67  S FARY="C0XFARY"
    68  S C0XFARY("C0XDIR")="/home/vista/gpl/fmts/trunk/samples/qds/"
    69  D USEFARY^C0XF2N(FARY)
    70  D IMPORT^C0XF2N("QDS_0001.rdf",C0XDIR,,FARY)
    71  D IMPORT^C0XF2N("QDS_0028b.rdf",C0XDIR,,FARY)
    72  D IMPORT^C0XF2N("QDS_0052.rdf",C0XDIR,,FARY)
    73  D IMPORT^C0XF2N("QDS_0073.rdf",C0XDIR,,FARY)
    74  D IMPORT^C0XF2N("QDS_0385.rdf",C0XDIR,,FARY)
    75  D IMPORT^C0XF2N("QDS_0002.rdf",C0XDIR,,FARY)
    76  D IMPORT^C0XF2N("QDS_0031.rdf",C0XDIR,,FARY)
    77  D IMPORT^C0XF2N("QDS_0055.rdf",C0XDIR,,FARY)
    78  D IMPORT^C0XF2N("QDS_0074.rdf",C0XDIR,,FARY)
    79  D IMPORT^C0XF2N("QDS_0387.rdf",C0XDIR,,FARY)
    80  D IMPORT^C0XF2N("QDS_0004.rdf",C0XDIR,,FARY)
    81  D IMPORT^C0XF2N("QDS_0032.rdf",C0XDIR,,FARY)
    82  D IMPORT^C0XF2N("QDS_0056.rdf",C0XDIR,,FARY)
    83  D IMPORT^C0XF2N("QDS_0075.rdf",C0XDIR,,FARY)
    84  D IMPORT^C0XF2N("QDS_0389.rdf",C0XDIR,,FARY)
    85  D IMPORT^C0XF2N("QDS_0012.rdf",C0XDIR,,FARY)
    86  D IMPORT^C0XF2N("QDS_0033.rdf",C0XDIR,,FARY)
    87  D IMPORT^C0XF2N("QDS_0059.rdf",C0XDIR,,FARY)
    88  D IMPORT^C0XF2N("QDS_0081.rdf",C0XDIR,,FARY)
    89  D IMPORT^C0XF2N("QDS_0421.rdf",C0XDIR,,FARY)
    90  D IMPORT^C0XF2N("QDS_0013.rdf",C0XDIR,,FARY)
    91  D IMPORT^C0XF2N("QDS_0034.rdf",C0XDIR,,FARY)
    92  D IMPORT^C0XF2N("QDS_0061.rdf",C0XDIR,,FARY)
    93  D IMPORT^C0XF2N("QDS_0083.rdf",C0XDIR,,FARY)
    94  D IMPORT^C0XF2N("QDS_0575.rdf",C0XDIR,,FARY)
    95  D IMPORT^C0XF2N("QDS_0014.rdf",C0XDIR,,FARY)
    96  D IMPORT^C0XF2N("QDS_0036.rdf",C0XDIR,,FARY)
    97  D IMPORT^C0XF2N("QDS_0062.rdf",C0XDIR,,FARY)
    98  D IMPORT^C0XF2N("QDS_0084.rdf",C0XDIR,,FARY)
    99  D IMPORT^C0XF2N("QDS_0018.rdf",C0XDIR,,FARY)
    100  D IMPORT^C0XF2N("QDS_0038.rdf",C0XDIR,,FARY)
    101  D IMPORT^C0XF2N("QDS_0064.rdf",C0XDIR,,FARY)
    102  D IMPORT^C0XF2N("QDS_0086.rdf",C0XDIR,,FARY)
    103  D IMPORT^C0XF2N("QDS_0024.rdf",C0XDIR,,FARY)
    104  D IMPORT^C0XF2N("QDS_0041.rdf",C0XDIR,,FARY)
    105  D IMPORT^C0XF2N("QDS_0067.rdf",C0XDIR,,FARY)
    106  D IMPORT^C0XF2N("QDS_0088.rdf",C0XDIR,,FARY)
    107  D IMPORT^C0XF2N("QDS_0027.rdf",C0XDIR,,FARY)
    108  D IMPORT^C0XF2N("QDS_0043.rdf",C0XDIR,,FARY)
    109  D IMPORT^C0XF2N("QDS_0068.rdf",C0XDIR,,FARY)
    110  D IMPORT^C0XF2N("QDS_0089.rdf",C0XDIR,,FARY)
    111  D IMPORT^C0XF2N("QDS_0028a.rdf",C0XDIR,,FARY)
    112  D IMPORT^C0XF2N("QDS_0047.rdf",C0XDIR,,FARY)
    113  D IMPORT^C0XF2N("QDS_0070.rdf",C0XDIR,,FARY)
    114  D IMPORT^C0XF2N("QDS_0105.rdf",C0XDIR,,FARY)
    115  ;D IMPORT^C0XF2N("qds.rdf",C0XDIR,,FARY)
    116  Q
    117  ;
     1C0XINIT ; GPL - Fileman Triples initialization routine ;10/13/11  17:05
     2        ;;1.0;FILEMAN TRIPLE STORE;;Sep 26, 2012;Build 10
     3        ;Copyright 2011 George Lilly.  Licensed under the terms of the GNU
     4        ;General Public License See attached copy of the License.
     5        ;
     6        ;This program is free software; you can redistribute it and/or modify
     7        ;it under the terms of the GNU General Public License as published by
     8        ;the Free Software Foundation; either version 2 of the License, or
     9        ;(at your option) any later version.
     10        ;
     11        ;This program is distributed in the hope that it will be useful,
     12        ;but WITHOUT ANY WARRANTY; without even the implied warranty of
     13        ;MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
     14        ;GNU General Public License for more details.
     15        ;
     16        ;You should have received a copy of the GNU General Public License along
     17        ;with this program; if not, write to the Free Software Foundation, Inc.,
     18        ;51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
     19        ;
     20        Q
     21        ;
     22CLEAR   ; DELETE THE FILESTORE
     23        K ^C0X(101)
     24        K ^C0X(201)
     25        S ^C0X(101,0)="C0X TRIPLE^172.101I^^"
     26        S ^C0X(201,0)="C0X STRING^172.201I^^"
     27        Q
     28        ;
     29INIT    ; INITIALIZE THE TRIPLE STORE - THIS DELETES THE GLOBALS AND
     30        ; START ALL OVER... USE WITH CAUTION
     31        ;
     32        ; -- we should be more sophisticated here.. at least warn the user
     33        ; -- and give them a chance to cancel
     34        ;
     35        D CLEAR ; DELETE THE TRIPLESTORE
     36        ;
     37        ; -- we are assuming that FARY is set up properly in C0XF2N
     38        ; -- with repect to the default directory and the defaut fileman files
     39        ; -- here's what it is now: "/home/vista/gpl/fmts/trunk/samples/"
     40        ; -- that means that all the sample files will look like:
     41        ; --- qds/QDS_0001.rdf
     42        ; --- smart-rdf-in/small.rdf
     43        ;
     44        S FARY="C0XFARY"
     45        D INITFARY^C0XF2N(FARY)
     46        D USEFARY^C0XF2N(FARY)
     47        S C0XFARY("C0XDIR")="/home/vista/gpl/fmts/trunk/samples/smart-rdf-in/" ;
     48        D USEFARY^C0XF2N(FARY)
     49        S SMART(1)="cole-susan.rdf"
     50        S SMART(2)="jones-cynthia.rdf"
     51        S SMART(3)="small.rdf"
     52        S SMART(4)="collins-frank.rdf"
     53        S SMART(5)="kelly-david.rdf"
     54        S SMART(6)="smith-maria.rdf"
     55        S SMART(7)="ford-shirley.rdf"
     56        S SMART(8)="morgan-jason.rdf"
     57        S SMART(9)="west-lisa.rdf"
     58        S SMART(10)="gracia-paul.rdf"
     59        S SMART(11)="reed-richard.rdf"
     60        S SMART(12)="west-sandra.rdf"
     61        S SMART(13)="jackson-jessica.rdf"
     62        S SMART(14)="small-allergies.rdf"
     63        S SMART(15)="white-patricia.rdf"
     64        N ZI S ZI=""
     65        F  S ZI=$O(SMART(ZI)) Q:ZI=""  D  ; for each smart file
     66        . D IMPORT^C0XF2N(SMART(ZI),C0XDIR,,FARY) ; import to the triplestore
     67        S FARY="C0XFARY"
     68        S C0XFARY("C0XDIR")="/home/vista/gpl/fmts/trunk/samples/qds/"
     69        D USEFARY^C0XF2N(FARY)
     70        D IMPORT^C0XF2N("QDS_0001.rdf",C0XDIR,,FARY)
     71        D IMPORT^C0XF2N("QDS_0028b.rdf",C0XDIR,,FARY)
     72        D IMPORT^C0XF2N("QDS_0052.rdf",C0XDIR,,FARY)
     73        D IMPORT^C0XF2N("QDS_0073.rdf",C0XDIR,,FARY)
     74        D IMPORT^C0XF2N("QDS_0385.rdf",C0XDIR,,FARY)
     75        D IMPORT^C0XF2N("QDS_0002.rdf",C0XDIR,,FARY)
     76        D IMPORT^C0XF2N("QDS_0031.rdf",C0XDIR,,FARY)
     77        D IMPORT^C0XF2N("QDS_0055.rdf",C0XDIR,,FARY)
     78        D IMPORT^C0XF2N("QDS_0074.rdf",C0XDIR,,FARY)
     79        D IMPORT^C0XF2N("QDS_0387.rdf",C0XDIR,,FARY)
     80        D IMPORT^C0XF2N("QDS_0004.rdf",C0XDIR,,FARY)
     81        D IMPORT^C0XF2N("QDS_0032.rdf",C0XDIR,,FARY)
     82        D IMPORT^C0XF2N("QDS_0056.rdf",C0XDIR,,FARY)
     83        D IMPORT^C0XF2N("QDS_0075.rdf",C0XDIR,,FARY)
     84        D IMPORT^C0XF2N("QDS_0389.rdf",C0XDIR,,FARY)
     85        D IMPORT^C0XF2N("QDS_0012.rdf",C0XDIR,,FARY)
     86        D IMPORT^C0XF2N("QDS_0033.rdf",C0XDIR,,FARY)
     87        D IMPORT^C0XF2N("QDS_0059.rdf",C0XDIR,,FARY)
     88        D IMPORT^C0XF2N("QDS_0081.rdf",C0XDIR,,FARY)
     89        D IMPORT^C0XF2N("QDS_0421.rdf",C0XDIR,,FARY)
     90        D IMPORT^C0XF2N("QDS_0013.rdf",C0XDIR,,FARY)
     91        D IMPORT^C0XF2N("QDS_0034.rdf",C0XDIR,,FARY)
     92        D IMPORT^C0XF2N("QDS_0061.rdf",C0XDIR,,FARY)
     93        D IMPORT^C0XF2N("QDS_0083.rdf",C0XDIR,,FARY)
     94        D IMPORT^C0XF2N("QDS_0575.rdf",C0XDIR,,FARY)
     95        D IMPORT^C0XF2N("QDS_0014.rdf",C0XDIR,,FARY)
     96        D IMPORT^C0XF2N("QDS_0036.rdf",C0XDIR,,FARY)
     97        D IMPORT^C0XF2N("QDS_0062.rdf",C0XDIR,,FARY)
     98        D IMPORT^C0XF2N("QDS_0084.rdf",C0XDIR,,FARY)
     99        D IMPORT^C0XF2N("QDS_0018.rdf",C0XDIR,,FARY)
     100        D IMPORT^C0XF2N("QDS_0038.rdf",C0XDIR,,FARY)
     101        D IMPORT^C0XF2N("QDS_0064.rdf",C0XDIR,,FARY)
     102        D IMPORT^C0XF2N("QDS_0086.rdf",C0XDIR,,FARY)
     103        D IMPORT^C0XF2N("QDS_0024.rdf",C0XDIR,,FARY)
     104        D IMPORT^C0XF2N("QDS_0041.rdf",C0XDIR,,FARY)
     105        D IMPORT^C0XF2N("QDS_0067.rdf",C0XDIR,,FARY)
     106        D IMPORT^C0XF2N("QDS_0088.rdf",C0XDIR,,FARY)
     107        D IMPORT^C0XF2N("QDS_0027.rdf",C0XDIR,,FARY)
     108        D IMPORT^C0XF2N("QDS_0043.rdf",C0XDIR,,FARY)
     109        D IMPORT^C0XF2N("QDS_0068.rdf",C0XDIR,,FARY)
     110        D IMPORT^C0XF2N("QDS_0089.rdf",C0XDIR,,FARY)
     111        D IMPORT^C0XF2N("QDS_0028a.rdf",C0XDIR,,FARY)
     112        D IMPORT^C0XF2N("QDS_0047.rdf",C0XDIR,,FARY)
     113        D IMPORT^C0XF2N("QDS_0070.rdf",C0XDIR,,FARY)
     114        D IMPORT^C0XF2N("QDS_0105.rdf",C0XDIR,,FARY)
     115        ;D IMPORT^C0XF2N("qds.rdf",C0XDIR,,FARY)
     116        Q
     117        ;
Note: See TracChangeset for help on using the changeset viewer.