home *** CD-ROM | disk | FTP | other *** search
/ ftp.ee.pdx.edu / 2014.02.ftp.ee.pdx.edu.tar / ftp.ee.pdx.edu / pub / lpf / patent.4916610 < prev    next >
Text File  |  1992-11-03  |  6KB  |  134 lines

  1.                                   US Patent #
  2.                                    4,916,610
  3.                                  10 April 1990
  4.  
  5.           "Multilanguage software integration through preprocessing"
  6.  
  7. ASSIGNEE: Racal Data Communications Inc., Sunrise, Florida
  8.  
  9. ABSTRACT:
  10.    A method of assuring consistency of constants in a multilanguage
  11. software system, includes generating a first set of code written in a
  12. first language using a plurality of symbolic constants to represent a
  13. corresponding plurality of actual constants. A second set of code is
  14. written in a second language using the plurality of symbolic
  15. constants to represent the corresponding plurality of actual
  16. constants. A common header file is generated which contains
  17. information which relates the plurality of symbolic constants to the
  18. corresponding plurality of actual constants. The header is included
  19. within the first and second sets of code. The symbolic constants in
  20. the first and second sets of code are replaced with their
  21. corresponding actual constants during a preprocessing step. Any
  22. constructs which are not a part of the first language are stripped
  23. from the second set of code including the header file. Any constructs
  24. which are not a part of the second language are stripped from the
  25. first set of code including the header. The resulting files have
  26. their symbolic constants consistently replaced by constants which are
  27. defined in the header so that changes need only be made in the header
  28. file to assure consistency in the several languages.
  29.  
  30.  CLAIMS:
  31.    1. A method of assuring consistency of constants in a
  32. multilanguage software system, comprising the steps performed by a
  33. computer of:
  34.  
  35.    providing a first set of code written in a first language using a
  36. plurality of symbolic constants to represent a corresponding
  37. plurality of actual constants;
  38.  
  39.    providing a second set of code written in a second language using
  40. said plurality of symbolic constants to represent said corresponding
  41. plurality of actual constants;
  42.  
  43.    providing a header which contains information which relates said
  44. plurality of symbolic constants to said corresponding plurality of
  45. actual constants;
  46.  
  47.    including said header within said first and second sets of code;
  48.  
  49.    preprocessing said first and second sets of cody by:
  50.  
  51.    replacing said symbolic constants in said first and second sets of
  52. code with their corresponding actual constants; and
  53.  
  54.    stripping any constructs which are not a part of said first
  55. language from said second set of code including said header.
  56.  
  57.    2. The method of claim 1, further comprising the step of stripping
  58. any constructs which are not a part of said second language from said
  59. first set of code including said header.
  60.  
  61.    3. The method of claim 1, further comprising the step of compiling
  62. or interpreting said first code with a compiler or interpreter
  63. specific to said first language.
  64.  
  65.    4. The method of claim 1, further comprising the step of compiling
  66. or interpreting said second code with a compiler or interpreter
  67. specific to said second language.
  68.  
  69.    5. The method of claim 1, wherein said including step comprises:
  70.  
  71.    including said header within said first and second sets of code by
  72. referencing said header in a statement; and
  73.  
  74.    substituting said header for said statement.
  75.  
  76.    6. The method of claim 2, further comprising the step of compiling
  77. said first code with a compiler specific to said first language and
  78. interpreting said second code with an interpreter specific to said
  79. second language.
  80.  
  81.    7. The method of claim 6, wherein said first language is C
  82. programming language and wherein said second language is Structured
  83. Queiry Language (SQL).
  84.  
  85.    8. The method of claim 6, wherein said header is written in C
  86. programming language.
  87.  
  88.    9. The method of claim 1, wherein said replacing step is carried
  89. out by use of a C language preprocessor.
  90.  
  91.    10. The method of claim 1 further comprising the steps of
  92. providing symbolic macros within said header and expanding said
  93. symbolic macros into language 1 specific statements in code 1 and
  94. language 2 specific statements in code 2.
  95.  
  96.    11. A method of assuring consistency of constants in a
  97. multilanguage software system, comprising the steps performed by a
  98. computer of:
  99.  
  100.    providing a first set of code written in a first language using a
  101. plurality of symbolic constants to represent a corresponding
  102. plurality of actual constants;
  103.  
  104.    providing a second set of code written in a second language using
  105. said plurality of symbolic constants to represent said corresponding
  106. plurality of actual constants;
  107.  
  108.    providing a header which contains information which relates said
  109. plurality of symbolic constants to said corresponding plurality of
  110. actual constants;
  111.  
  112.    including said header within said first and second sets of code by
  113. referencing said header in a statement;
  114.  
  115.    substituting said header for said statement;
  116.  
  117.    preprocessing said first and second sets of code by:
  118.  
  119.    replacing said symbolic constants in said first and second sets of
  120. code with their corresponding actual constants;
  121.  
  122.    stripping any constructs which are not a part of said first
  123. language from said second set of code including said header;
  124.  
  125.    stripping any constructs which are not a part of said second
  126. language from said first set of code including said header;
  127.  
  128.    compiling or interpreting said first code with compiler or
  129. interpreter specific to said first language; and,
  130.  
  131.    compiling or interpreting said second code with a compiler or
  132. interpreter specific to said second language.
  133.  
  134.