docs: public void writeKeyOffsets(CodeType codeType)
      { // Now, write all the key offsets out
          Record recClassInfo = this.getMainRecord();
          try   {
              //String previousKey;
              String strKeyName = "";
              String strRecordClass;
              String uniqueKeyFields[] = new String[10];
              String uniqueKeySeq[] = new String[10];
              int uniqueKeyCount = 0;
              strRecordClass = recClassInfo.getField(ClassInfo.CLASS_NAME).getString();
              
              Record recKeyInfo = this.getRecord(KeyInfo.KEY_INFO_FILE);
              recKeyInfo.close();
              int count = 0;
              while (recKeyInfo.hasNext())
              {
                  recKeyInfo.next();
                  count++;
                  strKeyName = recKeyInfo.getField(KeyInfo.KEY_NAME).getString();
                  if (strKeyName.length() == 0)
                      strKeyName = recKeyInfo.getField(KeyInfo.KEY_FIELD_1).getString();
                  if (strKeyName.equalsIgnoreCase(DBConstants.PRIMARY_KEY))
                      strKeyName = strRecordClass + "Primary";    // To avoid re-defining kPrimaryKey
  
                  if (!((IncludeScopeField)recKeyInfo.getField(KeyInfo.INCLUDE_SCOPE)).includeThis(codeType, true))
                      continue;
                  if (keyInBase(recClassInfo, recKeyInfo))
                      continue;
                  if (!strKeyName.equalsIgnoreCase(DBConstants.PRIMARY_KEY))
                      if (count == 1)
                          if (recKeyInfo.getField(KeyInfo.KEY_NUMBER).isNull())
                              count++;   // Special case, no sequence, first key is not the primary key... first key must be primary key
                  if (count > 1)
                      m_StreamOut.writeit("\npublic static final String " + this.convertNameToConstant(strKeyName + "Key") + " = \"" + strKeyName +"\";\n");
  
                      // This logic here checks to see if this is a unique key with one field, if yes adds field to array
                  String keyTypeStr, strKeyFieldName;
                  keyTypeStr = recKeyInfo.getField(KeyInfo.KEY_TYPE).getString();
                  if (keyTypeStr.length() == 0)
                      keyTypeStr = KeyTypeField.UNIQUE; // Unique key if no selection
                  strKeyFieldName = recKeyInfo.getField(KeyInfo.KEY_FIELD_2).getString();
                  if (((keyTypeStr.charAt(0) == KeyTypeField.UNIQUE.charAt(0)) || (keyTypeStr.charAt(0) == 'Y')) && (strKeyFieldName.length() == 0))
                      { // Unique key with one field, default logic... always try to read
                      strKeyFieldName = recKeyInfo.getField(KeyInfo.KEY_FIELD_1).getString();
                      uniqueKeyFields[uniqueKeyCount] = strKeyFieldName;
                      uniqueKeySeq[uniqueKeyCount] = strKeyName;
                      uniqueKeyCount++;
                  }
              }
              recKeyInfo.close();
          } catch (DBException ex)   {
              ex.printStackTrace();
          }
      }