Diff for /parser3/src/classes/table.C between versions 1.112 and 1.116

version 1.112, 2001/09/18 16:05:42 version 1.116, 2001/09/27 14:37:38
Line 2 Line 2
         Parser: @b table parser class.          Parser: @b table parser class.
   
         Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com)          Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com)
   
         Author: Alexander Petrosyan <paf@design.ru> (http://design.ru/paf)          Author: Alexander Petrosyan <paf@design.ru> (http://design.ru/paf)
   
           $Id$
 */  */
 static const char *RCSId="$Id$";   
   
 #include "classes.h"  #include "classes.h"
 #include "pa_config_includes.h"  #include "pa_config_includes.h"
Line 80  static void _set(Request& r, const Strin Line 80  static void _set(Request& r, const Strin
 static void _load(Request& r, const String& method_name, MethodParams *params) {  static void _load(Request& r, const String& method_name, MethodParams *params) {
         Pool& pool=r.pool();          Pool& pool=r.pool();
         // filename is last parameter          // filename is last parameter
         const String& filename=params->as_string(params->size()-1,           Value& vfilename=params->as_no_junction(params->size()-1, 
                 "file name must not be code");                  "file name must not be code");
   
         // loading text          // loading text
         char *data=file_read_text(pool, r.absolute(filename));          char *data=file_read_text(pool, r.absolute(vfilename.as_string()));
   
         // parse columns          // parse columns
         Array *columns;          Array *columns;
Line 470  static void _sort(Request& r, const Stri Line 470  static void _sort(Request& r, const Stri
         for(i=0; i<old_table.size(); i++)          for(i=0; i<old_table.size(); i++)
                 new_table+=seq[reverse?old_table.size()-1-i:i].row;                  new_table+=seq[reverse?old_table.size()-1-i:i].row;
   
         r.write_no_lang(*new(pool) VTable(pool, &new_table));          // replace any previous table value
           static_cast<VTable *>(r.self)->set_table(new_table);
 }  }
   
 static void _locate(Request& r, const String& method_name, MethodParams *params) {  static void _locate(Request& r, const String& method_name, MethodParams *params) {

Removed from v.1.112  
changed lines
  Added in v.1.116


E-mail: