Exemple #1
0
/*--------------------------------------------------------*/
int AzTools::writeList(const char *fn, 
                        const AzStrArray *sp_list)
{
  int max_len = 0; 
  AzFile file(fn); 
  file.open("wb"); 
  int num = sp_list->size(); 
  int ix; 
  for (ix = 0; ix < num; ++ix) {
    AzBytArr s; 
    sp_list->get(ix, &s); 
    s.concat("\n");
    max_len = MAX(max_len, s.getLen());  
    s.writeText(&file);  
  }
  file.close(true); 
  return max_len; 
}
 inline void finalize() {
   if (ba.getLen() == 0) {
     ba.concat('_'); /* root node (CONST) */
   }
 }