--- parser3/src/main/pa_request.C 2001/04/28 10:58:33 1.124 +++ parser3/src/main/pa_request.C 2001/05/15 10:01:25 1.130 @@ -5,7 +5,7 @@ Author: Alexander Petrosyan (http://design.ru/paf) - $Id: pa_request.C,v 1.124 2001/04/28 10:58:33 paf Exp $ + $Id: pa_request.C,v 1.130 2001/05/15 10:01:25 parser Exp $ */ #include "pa_config_includes.h" @@ -52,15 +52,15 @@ Request::Request(Pool& apool, default_content_type(0), mime_types(0), main_class(0), - connection(0), protocol2library(0), - mail(0), - pcre_tables(0) + connection(0), + pcre_tables(0), + classes_conf(apool) { /// directly used // operators OP.register_directly_used(*this); // classes: - // table, file, random, mail, image + // table, file, random, mail, image, ... methoded_array->register_directly_used(*this); /// methodless @@ -146,8 +146,6 @@ static void element2case(unsigned char * the file user requested us to process all located classes become children of one another, composing class we name 'MAIN' - - @test move configure to M-class */ void Request::core(const char *root_auto_path, bool root_auto_fail, const char *site_auto_path, bool site_auto_fail, @@ -169,6 +167,7 @@ void Request::core(const char *root_auto // configure root options // until someone with less privileges have overriden them + OP.configure_admin(*this); methoded_array->configure_admin(*this); // loading site auto.p @@ -212,13 +211,14 @@ void Request::core(const char *root_auto } } - // compiling requested file + // compile requested file String& spath_translated=*NEW String(pool()); spath_translated.APPEND_CLEAN(info.path_translated, 0, "user-request", 0); main_class=use_file(spath_translated, true/*don't ignore read problem*/, main_class_name, main_class); // configure not-root=user options + OP.configure_user(*this); methoded_array->configure_user(*this); // $MAIN:DEFAULTS @@ -230,11 +230,6 @@ void Request::core(const char *root_auto if(Table *table=element->get_table()) pool().set_tag(table); - // $MAIN:SQL.drivers - if(Value *sql=main_class->get_element(*main_sql_name)) - if(Value *element=sql->get_element(*main_sql_drivers_name)) - protocol2library=element->get_table(); - // $MAIN:MIME-TYPES if(Value *element=main_class->get_element(*mime_types_name)) if(Table *table=element->get_table()) @@ -252,8 +247,6 @@ void Request::core(const char *root_auto ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz] $word[ 0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZ_abcdefghijklmnopqrstuvwxyz] - $meta[ - ^#00$()*+.?[^{|] $lowercase[ AaBbCcDdEeFfGgHhIiJjKkLlMmNnOoPpQqRrSsTtUuVvWwXxYyZz] @@ -296,7 +289,7 @@ void Request::core(const char *root_auto if(const Method *method=junction->method) { // preparing to pass parameters to // @postprocess[data] - VMethodFrame frame(pool(), *junction, false); + VMethodFrame frame(pool(), value->name(), *junction, false); frame.set_self(*main_class); frame.store_param(method->name, @@ -361,7 +354,7 @@ void Request::core(const char *root_auto if(const Method *method=junction->method) { // preparing to pass parameters to // @exception[origin;source;comment;type;code] - VMethodFrame frame(pool(), *junction, false); + VMethodFrame frame(pool(), value->name(), *junction, false); frame.set_self(*main_class); const String *problem_source=e.problem_source();