MAINEDIT User's Guide, Appendix A

previous   next   top   contents   index   framed top   this page unframed


A. The DATMGR Back End

The DATMGR back end can be used to edit data files. It translates the data in a data file into readable text.

Example A–1 shows a few lines of a data file edited with back end DATMGR. The number in the leftmost column is the position of the data in the file. The next three columns are the data shown in hexadecimal, octal, and characters, respectively. Non-printable characters are displayed as a character code surrounded by angle brackets.

Example A–1. Sample Buffer Using Back End DATMGR
   0:   'H0000013C   '00000000474   <0><0><1><
   4:   '
H267C0000   '04637000000   &<124><0><0>
   8:   '
H00884EFB   '00042047373   <0><136>N<251>
  12:   '
HB800286E   '27000024156   <184><0>(n
  16:   '
HFFFC4E75   '37777047165   <255><252>Nu
  20:   '
H4E714E71   '11634247161   NqNq
  24:   '
H4E56FFF2   '11625577762   NV<255><242>
  28:   '
H2D4CFFFC   '05523177774   -L<255><252>
  32:   '
H2D7C0041   '05537000100   -<124><0>A
  36:   '
H0003FFF8   '00000777770   <0><3><255><248>

Data are modified by changing the hexadecimal values. The octal and character values do not have to be modified (only the first LONG BITS on the line affects the value in the file). When DATMGR writes the data to the file, it scans each line for a single quote ('). If it finds one, then it looks for a valid LONG BITS constant (without the trailing L). A valid LONG bits constant is a sequence of characters preceded by a single quote and a letter that indicates the base: B (or b) for binary, O (or o) for octal, or H (or h) for hexadecimal. The base letter may be omitted for octal; i.e., octal is the default.

Lines may be inserted or deleted. A line is legal as long as it contains at least one valid LONG BITS constant. If lines are inserted or deleted, the reported positions will no longer be correct; they are displayed for informational purposes only and are not checked when the buffer is saved.

When DATMGR saves the buffer, it writes one LONG BITS value for each line in the buffer. An error message is displayed and the user is prompted for a new value for each invalid line in the buffer.

DATMGR is not appropriate for very large data files, since it builds up in memory the text representation that it displays.


previous   next   top   contents   index   framed top   this page unframed

MAINEDIT User's Guide, Appendix A