--- parser3/src/classes/xdoc.C 2001/10/26 12:21:35 1.35 +++ parser3/src/classes/xdoc.C 2001/10/30 14:47:35 1.39 @@ -4,7 +4,7 @@ Copyright (c) 2001 ArtLebedev Group (http://www.artlebedev.com) Author: Alexander Petrosyan (http://design.ru/paf) - $Id: xdoc.C,v 1.35 2001/10/26 12:21:35 paf Exp $ + $Id: xdoc.C,v 1.39 2001/10/30 14:47:35 paf Exp $ */ #include "pa_types.h" #include "classes.h" @@ -109,7 +109,9 @@ static void _createTextNode(Request& r, Pool& pool=r.pool(); VXdoc& vdoc=*static_cast(r.self); - const String& data=params->as_string(0, "data must be string"); + Temp_lang temp_lang(r, String::UL_XML); + Value& data_code=params->as_junction(0, "data must be string"); + const String& data=r.process(data_code).as_string(); XalanNode *node= vdoc.get_document(pool, &method_name). @@ -611,11 +613,12 @@ static void _load(Request& r, const Stri vdoc.set_parsed_source(*parsedSource); } +/// @test lang=String::UL_UNSPECIFIED? static void add_xslt_param(const Hash::Key& aattribute, Hash::Val *ameaning, void *info) { XalanTransformer2& transformer=*static_cast(info); - const char *attribute_cstr=aattribute.cstr(); - const char *meaning_cstr=static_cast(ameaning)->as_string().cstr(); + const char *attribute_cstr=aattribute.cstr(String::UL_UNSPECIFIED); + const char *meaning_cstr=static_cast(ameaning)->as_string().cstr(String::UL_UNSPECIFIED); transformer.setStylesheetParam( XalanDOMString(attribute_cstr), @@ -649,6 +652,11 @@ static void _transform(Request& r, const // transform try { + // note: + // actually, never found any difference between the two + // but still there some extra "xerces" words at start of transform body + // wich were originally "xalan" + // not daring to change that if(vdoc.has_parsed_source()) { // set|load, not create? vdoc.transformer().transform2( vdoc.get_parsed_source(pool, &method_name),